Protect Privacy 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. #Disables Windows Feedback Experience
  2. Write-Output "Disabling Windows Feedback Experience program"
  3. $Advertising = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo"
  4. If (Test-Path $Advertising) {
  5. Set-ItemProperty $Advertising Enabled -Value 0
  6. }
  7. #Stops Cortana from being used as part of your Windows Search Function
  8. Write-Output "Stopping Cortana from being used as part of your Windows Search Function"
  9. $Search = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search"
  10. If (Test-Path $Search) {
  11. Set-ItemProperty $Search AllowCortana -Value 0
  12. }
  13. #Disables Web Search in Start Menu
  14. Write-Output "Disabling Bing Search in Start Menu"
  15. $WebSearch = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search"
  16. Set-ItemProperty "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" BingSearchEnabled -Value 0
  17. If (!(Test-Path $WebSearch)) {
  18. New-Item $WebSearch
  19. }
  20. Set-ItemProperty $WebSearch DisableWebSearch -Value 1
  21. #Stops the Windows Feedback Experience from sending anonymous data
  22. Write-Output "Stopping the Windows Feedback Experience program"
  23. $Period = "HKCU:\Software\Microsoft\Siuf\Rules"
  24. If (!(Test-Path $Period)) {
  25. New-Item $Period
  26. }
  27. Set-ItemProperty $Period PeriodInNanoSeconds -Value 0
  28. #Prevents bloatware applications from returning and removes Start Menu suggestions
  29. Write-Output "Adding Registry key to prevent bloatware apps from returning"
  30. $registryPath = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent"
  31. $registryOEM = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager"
  32. If (!(Test-Path $registryPath)) {
  33. New-Item $registryPath
  34. }
  35. Set-ItemProperty $registryPath DisableWindowsConsumerFeatures -Value 1
  36. If (!(Test-Path $registryOEM)) {
  37. New-Item $registryOEM
  38. }
  39. Set-ItemProperty $registryOEM ContentDeliveryAllowed -Value 0
  40. Set-ItemProperty $registryOEM OemPreInstalledAppsEnabled -Value 0
  41. Set-ItemProperty $registryOEM PreInstalledAppsEnabled -Value 0
  42. Set-ItemProperty $registryOEM PreInstalledAppsEverEnabled -Value 0
  43. Set-ItemProperty $registryOEM SilentInstalledAppsEnabled -Value 0
  44. Set-ItemProperty $registryOEM SystemPaneSuggestionsEnabled -Value 0
  45. #Preping mixed Reality Portal for removal
  46. Write-Output "Setting Mixed Reality Portal value to 0 so that you can uninstall it in Settings"
  47. $Holo = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Holographic"
  48. If (Test-Path $Holo) {
  49. Set-ItemProperty $Holo FirstRunSucceeded -Value 0
  50. }
  51. #Disables Wi-fi Sense
  52. Write-Output "Disabling Wi-Fi Sense"
  53. $WifiSense1 = "HKLM:\SOFTWARE\Microsoft\PolicyManager\default\WiFi\AllowWiFiHotSpotReporting"
  54. $WifiSense2 = "HKLM:\SOFTWARE\Microsoft\PolicyManager\default\WiFi\AllowAutoConnectToWiFiSenseHotspots"
  55. $WifiSense3 = "HKLM:\SOFTWARE\Microsoft\WcmSvc\wifinetworkmanager\config"
  56. If (!(Test-Path $WifiSense1)) {
  57. New-Item $WifiSense1
  58. }
  59. Set-ItemProperty $WifiSense1 Value -Value 0
  60. If (!(Test-Path $WifiSense2)) {
  61. New-Item $WifiSense2
  62. }
  63. Set-ItemProperty $WifiSense2 Value -Value 0
  64. Set-ItemProperty $WifiSense3 AutoConnectAllowedOEM -Value 0
  65. #Disables live tiles
  66. Write-Output "Disabling live tiles"
  67. $Live = "HKCU:\SOFTWARE\Policies\Microsoft\Windows\CurrentVersion\PushNotifications"
  68. If (!(Test-Path $Live)) {
  69. New-Item $Live
  70. }
  71. Set-ItemProperty $Live NoTileApplicationNotification -Value 1
  72. #Turns off Data Collection via the AllowTelemtry key by changing it to 0
  73. Write-Output "Turning off Data Collection"
  74. $DataCollection1 = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\DataCollection"
  75. $DataCollection2 = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection"
  76. $DataCollection3 = "HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Policies\DataCollection"
  77. If (Test-Path $DataCollection1) {
  78. Set-ItemProperty $DataCollection1 AllowTelemetry -Value 0
  79. }
  80. If (Test-Path $DataCollection2) {
  81. Set-ItemProperty $DataCollection2 AllowTelemetry -Value 0
  82. }
  83. If (Test-Path $DataCollection3) {
  84. Set-ItemProperty $DataCollection3 AllowTelemetry -Value 0
  85. }
  86. #Disabling Location Tracking
  87. Write-Output "Disabling Location Tracking"
  88. $SensorState = "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Sensor\Overrides\{BFA794E4-F964-4FDB-90F6-51056BFE4B44}"
  89. $LocationConfig = "HKLM:\SYSTEM\CurrentControlSet\Services\lfsvc\Service\Configuration"
  90. If (!(Test-Path $SensorState)) {
  91. New-Item $SensorState
  92. }
  93. Set-ItemProperty $SensorState SensorPermissionState -Value 0
  94. If (!(Test-Path $LocationConfig)) {
  95. New-Item $LocationConfig
  96. }
  97. Set-ItemProperty $LocationConfig Status -Value 0
  98. #Disables People icon on Taskbar
  99. Write-Output "Disabling People icon on Taskbar"
  100. $People = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People"
  101. If (!(Test-Path $People)) {
  102. New-Item $People
  103. }
  104. Set-ItemProperty $People PeopleBand -Value 0
  105. #Disables scheduled tasks that are considered unnecessary
  106. Write-Output "Disabling scheduled tasks"
  107. Get-ScheduledTask XblGameSaveTaskLogon | Disable-ScheduledTask
  108. Get-ScheduledTask XblGameSaveTask | Disable-ScheduledTask
  109. Get-ScheduledTask Consolidator | Disable-ScheduledTask
  110. Get-ScheduledTask UsbCeip | Disable-ScheduledTask
  111. Get-ScheduledTask DmClient | Disable-ScheduledTask
  112. Get-ScheduledTask DmClientOnScenarioDownload | Disable-ScheduledTask
  113. Write-Output "Stopping and disabling WAP Push Service"
  114. #Stop and disable WAP Push Service
  115. Stop-Service "dmwappushservice"
  116. Set-Service "dmwappushservice" -StartupType Disabled
  117. Write-Output "Stopping and disabling Diagnostics Tracking Service"
  118. #Disabling the Diagnostics Tracking Service
  119. Stop-Service "DiagTrack"
  120. Set-Service "DiagTrack" -StartupType Disabled