Last active
September 13, 2015 11:34
-
-
Save rlbisbe/83d743d465210db73720 to your computer and use it in GitHub Desktop.
Configure SQL Server
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# set-executionpolicy unrestricted | |
function Disable-InternetExplorerESC { | |
$AdminKey = "HKLM:\SOFTWARE\Microsoft\Active Setup\Installed Components\{A509B1A7-37EF-4b3f-8CFC-4F3A74704073}" | |
$UserKey = "HKLM:\SOFTWARE\Microsoft\Active Setup\Installed Components\{A509B1A8-37EF-4b3f-8CFC-4F3A74704073}" | |
Set-ItemProperty -Path $AdminKey -Name "IsInstalled" -Value 0 -Force | |
Set-ItemProperty -Path $UserKey -Name "IsInstalled" -Value 0 -Force | |
Stop-Process -Name Explorer -Force | |
Write-Host "IE Enhanced Security Configuration (ESC) has been disabled." -ForegroundColor Green | |
} | |
function Enable-InternetExplorerESC { | |
$AdminKey = "HKLM:\SOFTWARE\Microsoft\Active Setup\Installed Components\{A509B1A7-37EF-4b3f-8CFC-4F3A74704073}" | |
$UserKey = "HKLM:\SOFTWARE\Microsoft\Active Setup\Installed Components\{A509B1A8-37EF-4b3f-8CFC-4F3A74704073}" | |
Set-ItemProperty -Path $AdminKey -Name "IsInstalled" -Value 1 -Force | |
Set-ItemProperty -Path $UserKey -Name "IsInstalled" -Value 1 -Force | |
Stop-Process -Name Explorer | |
Write-Host "IE Enhanced Security Configuration (ESC) has been enabled." -ForegroundColor Green | |
} | |
function Disable-UserAccessControl { | |
Set-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System" -Name "ConsentPromptBehaviorAdmin" -Value 00000000 -Force | |
Write-Host "User Access Control (UAC) has been disabled." -ForegroundColor Green | |
} | |
Disable-UserAccessControl | |
Disable-InternetExplorerESC | |
Invoke-WebRequest http://download.microsoft.com/download/0/A/F/0AFB5316-3062-494A-AB78-7FB0D4461357/windows6.1-KB976932-X64.exe |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment