mrjayviper
Weaksauce
- Joined
- Jul 17, 2012
- Messages
- 91
I have the following powershell script
Basically, it turns off Windows Defender and stops Microsoft from auto-updating my computer. I restarted by computer and when I checked the Windows Defender/Update settings via gpedit, the changes I made via registry are not reflected.
As a test, I tried:
Code:
Set-ItemProperty "Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender" -Name DisableAntiSpyware -Value 0x00000001
New-Item -Path "Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows" -name WindowsUpdate
New-Item -Path "Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate"-Name AU
Set-ItemProperty "Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" -Name NoAutoUpdate -Value 0x00000000
Set-ItemProperty "Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" -Name AUOptions -Value 0x00000002
As a test, I tried:
- Deleting the entries I made.
- Configure Windows Defender/Update via gpedit.
- Export Windows Defender/Update registry setting.
- Change Windows Defender/Update to an unconfigured state.
- Close gpedit.
- Import registry setting from step3.
- Open gpedit again and check Windows Defender/Update. Both components are still in unconfigured state.
- Configuring Windows Defender/Update via gpedit.
- Delete Windows Defender/Update registry setting.
- Open gpedit again and check Windows Defender. Both components are still configured.