Add files via upload
This commit is contained in:
parent
b01e506be5
commit
c8315da21d
13 changed files with 2047 additions and 0 deletions
921
scripts/Windows10Debloater.ps1
vendored
Normal file
921
scripts/Windows10Debloater.ps1
vendored
Normal file
|
@ -0,0 +1,921 @@
|
|||
### This is a script with interactive prompts which will remove unnecessary and sponsered Windows 10 apps including their background tasks in Registry. ###
|
||||
###- This does NOT remove essential system services/software/etc such as Cortana etc. ###
|
||||
###- Next to this it will protect your privacy and turn off Data collection via AllowTelemetry registry keys. ###
|
||||
###- It will unpin live tiles, disable Cortana, Windows Feedback experience, Web search in start menu, Wi-fi Sense, location tracking and other unnecessery scheduled tasks. Note: The most changes can also be reverted.###
|
||||
### Author of this script: https://github.com/Sycnex/Windows10Debloater
|
||||
|
||||
#This function finds any AppX/AppXProvisioned package and uninstalls it, except for Freshpaint, Windows Calculator, Windows Store, and Windows Photos.
|
||||
#Also, to note - This does NOT remove essential system services/software/etc such as .NET framework installations, Cortana, Edge, etc.
|
||||
|
||||
#This will self elevate the script so with a UAC prompt since this script needs to be run as an Administrator in order to function properly.
|
||||
If (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]'Administrator')) {
|
||||
Write-Host "You didn't run this script as an Administrator. This script will self elevate to run as an Administrator and continue."
|
||||
Start-Sleep 1
|
||||
Write-Host " 3"
|
||||
Start-Sleep 1
|
||||
Write-Host " 2"
|
||||
Start-Sleep 1
|
||||
Write-Host " 1"
|
||||
Start-Sleep 1
|
||||
Start-Process powershell.exe -ArgumentList ("-NoProfile -ExecutionPolicy Bypass -File `"{0}`"" -f $PSCommandPath) -Verb RunAs
|
||||
Exit
|
||||
}
|
||||
|
||||
#no errors throughout
|
||||
$ErrorActionPreference = 'silentlycontinue'
|
||||
|
||||
$DebloatFolder = "C:\Temp\Windows10Debloater"
|
||||
If (Test-Path $DebloatFolder) {
|
||||
Write-Output "$DebloatFolder exists. Skipping."
|
||||
}
|
||||
Else {
|
||||
Write-Output "The folder '$DebloatFolder' doesn't exist. This folder will be used for storing logs created after the script runs. Creating now."
|
||||
Start-Sleep 1
|
||||
New-Item -Path "$DebloatFolder" -ItemType Directory
|
||||
Write-Output "The folder $DebloatFolder was successfully created."
|
||||
}
|
||||
|
||||
Start-Transcript -OutputDirectory "$DebloatFolder"
|
||||
|
||||
Add-Type -AssemblyName PresentationCore, PresentationFramework
|
||||
|
||||
Function DebloatAll {
|
||||
#Removes AppxPackages
|
||||
#Credit to /u/GavinEke for a modified version of my whitelist code
|
||||
$WhitelistedApps = 'Microsoft.ScreenSketch|Microsoft.Paint3D|Microsoft.WindowsCalculator|Microsoft.WindowsStore|Microsoft.Windows.Photos|CanonicalGroupLimited.UbuntuonWindows|`
|
||||
Microsoft.XboxGameCallableUI|Microsoft.XboxGamingOverlay|Microsoft.Xbox.TCUI|Microsoft.XboxGamingOverlay|Microsoft.XboxIdentityProvider|Microsoft.MicrosoftStickyNotes|Microsoft.MSPaint|Microsoft.WindowsCamera|.NET|Framework|`
|
||||
Microsoft.HEIFImageExtension|Microsoft.ScreenSketch|Microsoft.StorePurchaseApp|Microsoft.VP9VideoExtensions|Microsoft.WebMediaExtensions|Microsoft.WebpImageExtension|Microsoft.DesktopAppInstaller|WindSynthBerry|MIDIBerry|Slack'
|
||||
#NonRemovable Apps that where getting attempted and the system would reject the uninstall, speeds up debloat and prevents 'initalizing' overlay when removing apps
|
||||
$NonRemovable = '1527c705-839a-4832-9118-54d4Bd6a0c89|c5e2524a-ea46-4f67-841f-6a9465d9d515|E2A4F912-2574-4A75-9BB0-0D023378592B|F46D4000-FD22-4DB4-AC8E-4E1DDDE828FE|InputApp|Microsoft.AAD.BrokerPlugin|Microsoft.AccountsControl|`
|
||||
Microsoft.BioEnrollment|Microsoft.CredDialogHost|Microsoft.ECApp|Microsoft.LockApp|Microsoft.MicrosoftEdgeDevToolsClient|Microsoft.MicrosoftEdge|Microsoft.PPIProjection|Microsoft.Win32WebViewHost|Microsoft.Windows.Apprep.ChxApp|`
|
||||
Microsoft.Windows.AssignedAccessLockApp|Microsoft.Windows.CapturePicker|Microsoft.Windows.CloudExperienceHost|Microsoft.Windows.ContentDeliveryManager|Microsoft.Windows.Cortana|Microsoft.Windows.NarratorQuickStart|`
|
||||
Microsoft.Windows.ParentalControls|Microsoft.Windows.PeopleExperienceHost|Microsoft.Windows.PinningConfirmationDialog|Microsoft.Windows.SecHealthUI|Microsoft.Windows.SecureAssessmentBrowser|Microsoft.Windows.ShellExperienceHost|`
|
||||
Microsoft.Windows.XGpuEjectDialog|Microsoft.XboxGameCallableUI|Windows.CBSPreview|windows.immersivecontrolpanel|Windows.PrintDialog|Microsoft.VCLibs.140.00|Microsoft.Services.Store.Engagement|Microsoft.UI.Xaml.2.0|*Nvidia*'
|
||||
Get-AppxPackage -AllUsers | Where-Object {$_.Name -NotMatch $WhitelistedApps -and $_.Name -NotMatch $NonRemovable} | Remove-AppxPackage
|
||||
Get-AppxPackage | Where-Object {$_.Name -NotMatch $WhitelistedApps -and $_.Name -NotMatch $NonRemovable} | Remove-AppxPackage
|
||||
Get-AppxProvisionedPackage -Online | Where-Object {$_.PackageName -NotMatch $WhitelistedApps -and $_.PackageName -NotMatch $NonRemovable} | Remove-AppxProvisionedPackage -Online
|
||||
}
|
||||
|
||||
Function DebloatBlacklist {
|
||||
|
||||
$Bloatware = @(
|
||||
|
||||
#Unnecessary Windows 10 AppX Apps
|
||||
"Microsoft.BingNews"
|
||||
"Microsoft.GetHelp"
|
||||
"Microsoft.Getstarted"
|
||||
"Microsoft.Messaging"
|
||||
"Microsoft.Microsoft3DViewer"
|
||||
"Microsoft.MicrosoftOfficeHub"
|
||||
"Microsoft.MicrosoftSolitaireCollection"
|
||||
"Microsoft.NetworkSpeedTest"
|
||||
"Microsoft.News"
|
||||
"Microsoft.Office.Lens"
|
||||
"Microsoft.Office.OneNote"
|
||||
"Microsoft.Office.Sway"
|
||||
"Microsoft.OneConnect"
|
||||
"Microsoft.People"
|
||||
"Microsoft.Print3D"
|
||||
"Microsoft.RemoteDesktop"
|
||||
"Microsoft.SkypeApp"
|
||||
"Microsoft.StorePurchaseApp"
|
||||
"Microsoft.Office.Todo.List"
|
||||
"Microsoft.Whiteboard"
|
||||
"Microsoft.WindowsAlarms"
|
||||
#"Microsoft.WindowsCamera"
|
||||
"microsoft.windowscommunicationsapps"
|
||||
"Microsoft.WindowsFeedbackHub"
|
||||
"Microsoft.WindowsMaps"
|
||||
"Microsoft.WindowsSoundRecorder"
|
||||
"Microsoft.Xbox.TCUI"
|
||||
"Microsoft.XboxApp"
|
||||
"Microsoft.XboxGameOverlay"
|
||||
"Microsoft.XboxIdentityProvider"
|
||||
"Microsoft.XboxSpeechToTextOverlay"
|
||||
"Microsoft.ZuneMusic"
|
||||
"Microsoft.ZuneVideo"
|
||||
|
||||
#Sponsored Windows 10 AppX Apps
|
||||
#Add sponsored/featured apps to remove in the "*AppName*" format
|
||||
"*EclipseManager*"
|
||||
"*ActiproSoftwareLLC*"
|
||||
"*AdobeSystemsIncorporated.AdobePhotoshopExpress*"
|
||||
"*Duolingo-LearnLanguagesforFree*"
|
||||
"*PandoraMediaInc*"
|
||||
"*CandyCrush*"
|
||||
"*BubbleWitch3Saga*"
|
||||
"*Wunderlist*"
|
||||
"*Flipboard*"
|
||||
"*Twitter*"
|
||||
"*Facebook*"
|
||||
"*Spotify*"
|
||||
"*Minecraft*"
|
||||
"*Royal Revolt*"
|
||||
"*Sway*"
|
||||
"*Speed Test*"
|
||||
"*Dolby*"
|
||||
|
||||
#Optional: Typically not removed but you can if you need to for some reason
|
||||
#"*Microsoft.Advertising.Xaml_10.1712.5.0_x64__8wekyb3d8bbwe*"
|
||||
#"*Microsoft.Advertising.Xaml_10.1712.5.0_x86__8wekyb3d8bbwe*"
|
||||
#"*Microsoft.BingWeather*"
|
||||
#"*Microsoft.MSPaint*"
|
||||
#"*Microsoft.MicrosoftStickyNotes*"
|
||||
#"*Microsoft.Windows.Photos*"
|
||||
#"*Microsoft.WindowsCalculator*"
|
||||
#"*Microsoft.WindowsStore*"
|
||||
)
|
||||
foreach ($Bloat in $Bloatware) {
|
||||
Get-AppxPackage -Name $Bloat| Remove-AppxPackage
|
||||
Get-AppxProvisionedPackage -Online | Where-Object DisplayName -like $Bloat | Remove-AppxProvisionedPackage -Online
|
||||
Write-Output "Trying to remove $Bloat."
|
||||
}
|
||||
}
|
||||
|
||||
Function Remove-Keys {
|
||||
|
||||
#These are the registry keys that it will delete.
|
||||
|
||||
$Keys = @(
|
||||
|
||||
#Remove Background Tasks
|
||||
"HKCR:\Extensions\ContractId\Windows.BackgroundTasks\PackageId\46928bounde.EclipseManager_2.2.4.51_neutral__a5h4egax66k6y"
|
||||
"HKCR:\Extensions\ContractId\Windows.BackgroundTasks\PackageId\ActiproSoftwareLLC.562882FEEB491_2.6.18.18_neutral__24pqs290vpjk0"
|
||||
"HKCR:\Extensions\ContractId\Windows.BackgroundTasks\PackageId\Microsoft.MicrosoftOfficeHub_17.7909.7600.0_x64__8wekyb3d8bbwe"
|
||||
"HKCR:\Extensions\ContractId\Windows.BackgroundTasks\PackageId\Microsoft.PPIProjection_10.0.15063.0_neutral_neutral_cw5n1h2txyewy"
|
||||
"HKCR:\Extensions\ContractId\Windows.BackgroundTasks\PackageId\Microsoft.XboxGameCallableUI_1000.15063.0.0_neutral_neutral_cw5n1h2txyewy"
|
||||
"HKCR:\Extensions\ContractId\Windows.BackgroundTasks\PackageId\Microsoft.XboxGameCallableUI_1000.16299.15.0_neutral_neutral_cw5n1h2txyewy"
|
||||
|
||||
#Windows File
|
||||
"HKCR:\Extensions\ContractId\Windows.File\PackageId\ActiproSoftwareLLC.562882FEEB491_2.6.18.18_neutral__24pqs290vpjk0"
|
||||
|
||||
#Registry keys to delete if they aren't uninstalled by RemoveAppXPackage/RemoveAppXProvisionedPackage
|
||||
"HKCR:\Extensions\ContractId\Windows.Launch\PackageId\46928bounde.EclipseManager_2.2.4.51_neutral__a5h4egax66k6y"
|
||||
"HKCR:\Extensions\ContractId\Windows.Launch\PackageId\ActiproSoftwareLLC.562882FEEB491_2.6.18.18_neutral__24pqs290vpjk0"
|
||||
"HKCR:\Extensions\ContractId\Windows.Launch\PackageId\Microsoft.PPIProjection_10.0.15063.0_neutral_neutral_cw5n1h2txyewy"
|
||||
"HKCR:\Extensions\ContractId\Windows.Launch\PackageId\Microsoft.XboxGameCallableUI_1000.15063.0.0_neutral_neutral_cw5n1h2txyewy"
|
||||
"HKCR:\Extensions\ContractId\Windows.Launch\PackageId\Microsoft.XboxGameCallableUI_1000.16299.15.0_neutral_neutral_cw5n1h2txyewy"
|
||||
|
||||
#Scheduled Tasks to delete
|
||||
"HKCR:\Extensions\ContractId\Windows.PreInstalledConfigTask\PackageId\Microsoft.MicrosoftOfficeHub_17.7909.7600.0_x64__8wekyb3d8bbwe"
|
||||
|
||||
#Windows Protocol Keys
|
||||
"HKCR:\Extensions\ContractId\Windows.Protocol\PackageId\ActiproSoftwareLLC.562882FEEB491_2.6.18.18_neutral__24pqs290vpjk0"
|
||||
"HKCR:\Extensions\ContractId\Windows.Protocol\PackageId\Microsoft.PPIProjection_10.0.15063.0_neutral_neutral_cw5n1h2txyewy"
|
||||
"HKCR:\Extensions\ContractId\Windows.Protocol\PackageId\Microsoft.XboxGameCallableUI_1000.15063.0.0_neutral_neutral_cw5n1h2txyewy"
|
||||
"HKCR:\Extensions\ContractId\Windows.Protocol\PackageId\Microsoft.XboxGameCallableUI_1000.16299.15.0_neutral_neutral_cw5n1h2txyewy"
|
||||
|
||||
#Windows Share Target
|
||||
"HKCR:\Extensions\ContractId\Windows.ShareTarget\PackageId\ActiproSoftwareLLC.562882FEEB491_2.6.18.18_neutral__24pqs290vpjk0"
|
||||
)
|
||||
|
||||
#This writes the output of each key it is removing and also removes the keys listed above.
|
||||
ForEach ($Key in $Keys) {
|
||||
Write-Output "Removing $Key from registry"
|
||||
Remove-Item $Key -Recurse
|
||||
}
|
||||
}
|
||||
|
||||
Function Protect-Privacy {
|
||||
|
||||
#Disables Windows Feedback Experience
|
||||
Write-Output "Disabling Windows Feedback Experience program"
|
||||
$Advertising = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo"
|
||||
If (Test-Path $Advertising) {
|
||||
Set-ItemProperty $Advertising Enabled -Value 0
|
||||
}
|
||||
|
||||
#Stops Cortana from being used as part of your Windows Search Function
|
||||
Write-Output "Stopping Cortana from being used as part of your Windows Search Function"
|
||||
$Search = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search"
|
||||
If (Test-Path $Search) {
|
||||
Set-ItemProperty $Search AllowCortana -Value 0
|
||||
}
|
||||
|
||||
#Disables Web Search in Start Menu
|
||||
Write-Output "Disabling Bing Search in Start Menu"
|
||||
$WebSearch = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search"
|
||||
Set-ItemProperty "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" BingSearchEnabled -Value 0
|
||||
If (!(Test-Path $WebSearch)) {
|
||||
New-Item $WebSearch
|
||||
}
|
||||
Set-ItemProperty $WebSearch DisableWebSearch -Value 1
|
||||
|
||||
#Stops the Windows Feedback Experience from sending anonymous data
|
||||
Write-Output "Stopping the Windows Feedback Experience program"
|
||||
$Period = "HKCU:\Software\Microsoft\Siuf\Rules"
|
||||
If (!(Test-Path $Period)) {
|
||||
New-Item $Period
|
||||
}
|
||||
Set-ItemProperty $Period PeriodInNanoSeconds -Value 0
|
||||
|
||||
#Prevents bloatware applications from returning and removes Start Menu suggestions
|
||||
Write-Output "Adding Registry key to prevent bloatware apps from returning"
|
||||
$registryPath = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent"
|
||||
$registryOEM = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager"
|
||||
If (!(Test-Path $registryPath)) {
|
||||
New-Item $registryPath
|
||||
}
|
||||
Set-ItemProperty $registryPath DisableWindowsConsumerFeatures -Value 1
|
||||
|
||||
If (!(Test-Path $registryOEM)) {
|
||||
New-Item $registryOEM
|
||||
}
|
||||
Set-ItemProperty $registryOEM ContentDeliveryAllowed -Value 0
|
||||
Set-ItemProperty $registryOEM OemPreInstalledAppsEnabled -Value 0
|
||||
Set-ItemProperty $registryOEM PreInstalledAppsEnabled -Value 0
|
||||
Set-ItemProperty $registryOEM PreInstalledAppsEverEnabled -Value 0
|
||||
Set-ItemProperty $registryOEM SilentInstalledAppsEnabled -Value 0
|
||||
Set-ItemProperty $registryOEM SystemPaneSuggestionsEnabled -Value 0
|
||||
|
||||
#Preping mixed Reality Portal for removal
|
||||
Write-Output "Setting Mixed Reality Portal value to 0 so that you can uninstall it in Settings"
|
||||
$Holo = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Holographic"
|
||||
If (Test-Path $Holo) {
|
||||
Set-ItemProperty $Holo FirstRunSucceeded -Value 0
|
||||
}
|
||||
|
||||
#Disables Wi-fi Sense
|
||||
Write-Output "Disabling Wi-Fi Sense"
|
||||
$WifiSense1 = "HKLM:\SOFTWARE\Microsoft\PolicyManager\default\WiFi\AllowWiFiHotSpotReporting"
|
||||
$WifiSense2 = "HKLM:\SOFTWARE\Microsoft\PolicyManager\default\WiFi\AllowAutoConnectToWiFiSenseHotspots"
|
||||
$WifiSense3 = "HKLM:\SOFTWARE\Microsoft\WcmSvc\wifinetworkmanager\config"
|
||||
If (!(Test-Path $WifiSense1)) {
|
||||
New-Item $WifiSense1
|
||||
}
|
||||
Set-ItemProperty $WifiSense1 Value -Value 0
|
||||
If (!(Test-Path $WifiSense2)) {
|
||||
New-Item $WifiSense2
|
||||
}
|
||||
Set-ItemProperty $WifiSense2 Value -Value 0
|
||||
Set-ItemProperty $WifiSense3 AutoConnectAllowedOEM -Value 0
|
||||
|
||||
#Disables live tiles
|
||||
Write-Output "Disabling live tiles"
|
||||
$Live = "HKCU:\SOFTWARE\Policies\Microsoft\Windows\CurrentVersion\PushNotifications"
|
||||
If (!(Test-Path $Live)) {
|
||||
New-Item $Live
|
||||
}
|
||||
Set-ItemProperty $Live NoTileApplicationNotification -Value 1
|
||||
|
||||
#Turns off Data Collection via the AllowTelemtry key by changing it to 0
|
||||
Write-Output "Turning off Data Collection"
|
||||
$DataCollection1 = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\DataCollection"
|
||||
$DataCollection2 = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection"
|
||||
$DataCollection3 = "HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Policies\DataCollection"
|
||||
If (Test-Path $DataCollection1) {
|
||||
Set-ItemProperty $DataCollection1 AllowTelemetry -Value 0
|
||||
}
|
||||
If (Test-Path $DataCollection2) {
|
||||
Set-ItemProperty $DataCollection2 AllowTelemetry -Value 0
|
||||
}
|
||||
If (Test-Path $DataCollection3) {
|
||||
Set-ItemProperty $DataCollection3 AllowTelemetry -Value 0
|
||||
}
|
||||
|
||||
#Disabling Location Tracking
|
||||
Write-Output "Disabling Location Tracking"
|
||||
$SensorState = "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Sensor\Overrides\{BFA794E4-F964-4FDB-90F6-51056BFE4B44}"
|
||||
$LocationConfig = "HKLM:\SYSTEM\CurrentControlSet\Services\lfsvc\Service\Configuration"
|
||||
If (!(Test-Path $SensorState)) {
|
||||
New-Item $SensorState
|
||||
}
|
||||
Set-ItemProperty $SensorState SensorPermissionState -Value 0
|
||||
If (!(Test-Path $LocationConfig)) {
|
||||
New-Item $LocationConfig
|
||||
}
|
||||
Set-ItemProperty $LocationConfig Status -Value 0
|
||||
|
||||
#Disables People icon on Taskbar
|
||||
Write-Output "Disabling People icon on Taskbar"
|
||||
$People = 'HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People'
|
||||
If (Test-Path $People) {
|
||||
Set-ItemProperty $People -Name PeopleBand -Value 0
|
||||
}
|
||||
|
||||
#Disables scheduled tasks that are considered unnecessary
|
||||
Write-Output "Disabling scheduled tasks"
|
||||
Get-ScheduledTask XblGameSaveTaskLogon | Disable-ScheduledTask
|
||||
Get-ScheduledTask XblGameSaveTask | Disable-ScheduledTask
|
||||
Get-ScheduledTask Consolidator | Disable-ScheduledTask
|
||||
Get-ScheduledTask UsbCeip | Disable-ScheduledTask
|
||||
Get-ScheduledTask DmClient | Disable-ScheduledTask
|
||||
Get-ScheduledTask DmClientOnScenarioDownload | Disable-ScheduledTask
|
||||
|
||||
Write-Output "Stopping and disabling Diagnostics Tracking Service"
|
||||
#Disabling the Diagnostics Tracking Service
|
||||
Stop-Service "DiagTrack"
|
||||
Set-Service "DiagTrack" -StartupType Disabled
|
||||
|
||||
|
||||
Write-Output "Removing CloudStore from registry if it exists"
|
||||
$CloudStore = 'HKCU:\Software\Microsoft\Windows\CurrentVersion\CloudStore'
|
||||
If (Test-Path $CloudStore) {
|
||||
Stop-Process Explorer.exe -Force
|
||||
Remove-Item $CloudStore -Recurse -Force
|
||||
Start-Process Explorer.exe -Wait
|
||||
}
|
||||
}
|
||||
|
||||
Function DisableCortana {
|
||||
Write-Host "Disabling Cortana"
|
||||
$Cortana1 = "HKCU:\SOFTWARE\Microsoft\Personalization\Settings"
|
||||
$Cortana2 = "HKCU:\SOFTWARE\Microsoft\InputPersonalization"
|
||||
$Cortana3 = "HKCU:\SOFTWARE\Microsoft\InputPersonalization\TrainedDataStore"
|
||||
If (!(Test-Path $Cortana1)) {
|
||||
New-Item $Cortana1
|
||||
}
|
||||
Set-ItemProperty $Cortana1 AcceptedPrivacyPolicy -Value 0
|
||||
If (!(Test-Path $Cortana2)) {
|
||||
New-Item $Cortana2
|
||||
}
|
||||
Set-ItemProperty $Cortana2 RestrictImplicitTextCollection -Value 1
|
||||
Set-ItemProperty $Cortana2 RestrictImplicitInkCollection -Value 1
|
||||
If (!(Test-Path $Cortana3)) {
|
||||
New-Item $Cortana3
|
||||
}
|
||||
Set-ItemProperty $Cortana3 HarvestContacts -Value 0
|
||||
|
||||
}
|
||||
|
||||
Function EnableCortana {
|
||||
Write-Host "Re-enabling Cortana"
|
||||
$Cortana1 = "HKCU:\SOFTWARE\Microsoft\Personalization\Settings"
|
||||
$Cortana2 = "HKCU:\SOFTWARE\Microsoft\InputPersonalization"
|
||||
$Cortana3 = "HKCU:\SOFTWARE\Microsoft\InputPersonalization\TrainedDataStore"
|
||||
If (!(Test-Path $Cortana1)) {
|
||||
New-Item $Cortana1
|
||||
}
|
||||
Set-ItemProperty $Cortana1 AcceptedPrivacyPolicy -Value 1
|
||||
If (!(Test-Path $Cortana2)) {
|
||||
New-Item $Cortana2
|
||||
}
|
||||
Set-ItemProperty $Cortana2 RestrictImplicitTextCollection -Value 0
|
||||
Set-ItemProperty $Cortana2 RestrictImplicitInkCollection -Value 0
|
||||
If (!(Test-Path $Cortana3)) {
|
||||
New-Item $Cortana3
|
||||
}
|
||||
Set-ItemProperty $Cortana3 HarvestContacts -Value 1
|
||||
}
|
||||
|
||||
Function Stop-EdgePDF {
|
||||
|
||||
#Stops edge from taking over as the default .PDF viewer
|
||||
Write-Output "Stopping Edge from taking over as the default .PDF viewer"
|
||||
$NoPDF = "HKCR:\.pdf"
|
||||
$NoProgids = "HKCR:\.pdf\OpenWithProgids"
|
||||
$NoWithList = "HKCR:\.pdf\OpenWithList"
|
||||
If (!(Get-ItemProperty $NoPDF NoOpenWith)) {
|
||||
New-ItemProperty $NoPDF NoOpenWith
|
||||
}
|
||||
If (!(Get-ItemProperty $NoPDF NoStaticDefaultVerb)) {
|
||||
New-ItemProperty $NoPDF NoStaticDefaultVerb
|
||||
}
|
||||
If (!(Get-ItemProperty $NoProgids NoOpenWith)) {
|
||||
New-ItemProperty $NoProgids NoOpenWith
|
||||
}
|
||||
If (!(Get-ItemProperty $NoProgids NoStaticDefaultVerb)) {
|
||||
New-ItemProperty $NoProgids NoStaticDefaultVerb
|
||||
}
|
||||
If (!(Get-ItemProperty $NoWithList NoOpenWith)) {
|
||||
New-ItemProperty $NoWithList NoOpenWith
|
||||
}
|
||||
If (!(Get-ItemProperty $NoWithList NoStaticDefaultVerb)) {
|
||||
New-ItemProperty $NoWithList NoStaticDefaultVerb
|
||||
}
|
||||
|
||||
#Appends an underscore '_' to the Registry key for Edge
|
||||
$Edge = "HKCR:\AppXd4nrz8ff68srnhf9t5a8sbjyar1cr723_"
|
||||
If (Test-Path $Edge) {
|
||||
Set-Item $Edge AppXd4nrz8ff68srnhf9t5a8sbjyar1cr723_
|
||||
}
|
||||
}
|
||||
|
||||
Function Revert-Changes {
|
||||
|
||||
#This function will revert the changes you made when running the Start-Debloat function.
|
||||
|
||||
#This line reinstalls all of the bloatware that was removed
|
||||
Get-AppxPackage -AllUsers | ForEach {Add-AppxPackage -Verbose -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"}
|
||||
|
||||
#Tells Windows to enable your advertising information.
|
||||
Write-Output "Re-enabling key to show advertisement information"
|
||||
$Advertising = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo"
|
||||
If (Test-Path $Advertising) {
|
||||
Set-ItemProperty $Advertising Enabled -Value 1
|
||||
}
|
||||
|
||||
#Enables Cortana to be used as part of your Windows Search Function
|
||||
Write-Output "Re-enabling Cortana to be used in your Windows Search"
|
||||
$Search = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search"
|
||||
If (Test-Path $Search) {
|
||||
Set-ItemProperty $Search AllowCortana -Value 1
|
||||
}
|
||||
|
||||
#Re-enables the Windows Feedback Experience for sending anonymous data
|
||||
Write-Output "Re-enabling Windows Feedback Experience"
|
||||
$Period = "HKCU:\Software\Microsoft\Siuf\Rules"
|
||||
If (!(Test-Path $Period)) {
|
||||
New-Item $Period
|
||||
}
|
||||
Set-ItemProperty $Period PeriodInNanoSeconds -Value 1
|
||||
|
||||
#Enables bloatware applications
|
||||
Write-Output "Adding Registry key to allow bloatware apps to return"
|
||||
$registryPath = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent"
|
||||
If (!(Test-Path $registryPath)) {
|
||||
New-Item $registryPath
|
||||
}
|
||||
Set-ItemProperty $registryPath DisableWindowsConsumerFeatures -Value 0
|
||||
|
||||
#Changes Mixed Reality Portal Key 'FirstRunSucceeded' to 1
|
||||
Write-Output "Setting Mixed Reality Portal value to 1"
|
||||
$Holo = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Holographic"
|
||||
If (Test-Path $Holo) {
|
||||
Set-ItemProperty $Holo FirstRunSucceeded -Value 1
|
||||
}
|
||||
|
||||
#Re-enables live tiles
|
||||
Write-Output "Enabling live tiles"
|
||||
$Live = "HKCU:\SOFTWARE\Policies\Microsoft\Windows\CurrentVersion\PushNotifications"
|
||||
If (!(Test-Path $Live)) {
|
||||
New-Item $Live
|
||||
}
|
||||
Set-ItemProperty $Live NoTileApplicationNotification -Value 0
|
||||
|
||||
#Re-enables data collection
|
||||
Write-Output "Re-enabling data collection"
|
||||
$DataCollection = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\DataCollection"
|
||||
If (!(Test-Path $DataCollection)) {
|
||||
New-Item $DataCollection
|
||||
}
|
||||
Set-ItemProperty $DataCollection AllowTelemetry -Value 1
|
||||
|
||||
#Re-enables People Icon on Taskbar
|
||||
Write-Output "Enabling People icon on Taskbar"
|
||||
$People = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People"
|
||||
If (!(Test-Path $People)) {
|
||||
New-Item $People
|
||||
}
|
||||
Set-ItemProperty $People PeopleBand -Value 1
|
||||
|
||||
#Re-enables suggestions on start menu
|
||||
Write-Output "Enabling suggestions on the Start Menu"
|
||||
$Suggestions = "HKCU:\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager"
|
||||
If (!(Test-Path $Suggestions)) {
|
||||
New-Item $Suggestions
|
||||
}
|
||||
Set-ItemProperty $Suggestions SystemPaneSuggestionsEnabled -Value 1
|
||||
|
||||
#Re-enables scheduled tasks that were disabled when running the Debloat switch
|
||||
Write-Output "Enabling scheduled tasks that were disabled"
|
||||
Get-ScheduledTask XblGameSaveTaskLogon | Enable-ScheduledTask
|
||||
Get-ScheduledTask XblGameSaveTask | Enable-ScheduledTask
|
||||
Get-ScheduledTask Consolidator | Enable-ScheduledTask
|
||||
Get-ScheduledTask UsbCeip | Enable-ScheduledTask
|
||||
Get-ScheduledTask DmClient | Enable-ScheduledTask
|
||||
Get-ScheduledTask DmClientOnScenarioDownload | Enable-ScheduledTask
|
||||
|
||||
Write-Output "Re-enabling and starting WAP Push Service"
|
||||
#Enable and start WAP Push Service
|
||||
Set-Service "dmwappushservice" -StartupType Automatic
|
||||
Start-Service "dmwappushservice"
|
||||
|
||||
Write-Output "Re-enabling and starting the Diagnostics Tracking Service"
|
||||
#Enabling the Diagnostics Tracking Service
|
||||
Set-Service "DiagTrack" -StartupType Automatic
|
||||
Start-Service "DiagTrack"
|
||||
|
||||
Write-Output "Restoring 3D Objects in the 'My Computer' submenu in explorer"
|
||||
#Restoring 3D Objects in the 'My Computer' submenu in explorer
|
||||
Restore3dObjects
|
||||
}
|
||||
|
||||
Function CheckDMWService {
|
||||
|
||||
Param([switch]$Debloat)
|
||||
|
||||
If (Get-Service -Name dmwappushservice | Where-Object {$_.StartType -eq "Disabled"}) {
|
||||
Set-Service -Name dmwappushservice -StartupType Automatic
|
||||
}
|
||||
|
||||
If (Get-Service -Name dmwappushservice | Where-Object {$_.Status -eq "Stopped"}) {
|
||||
Start-Service -Name dmwappushservice
|
||||
}
|
||||
}
|
||||
|
||||
Function Enable-EdgePDF {
|
||||
Write-Output "Setting Edge back to default"
|
||||
$NoPDF = "HKCR:\.pdf"
|
||||
$NoProgids = "HKCR:\.pdf\OpenWithProgids"
|
||||
$NoWithList = "HKCR:\.pdf\OpenWithList"
|
||||
#Sets edge back to default
|
||||
If (Get-ItemProperty $NoPDF NoOpenWith) {
|
||||
Remove-ItemProperty $NoPDF NoOpenWith
|
||||
}
|
||||
If (Get-ItemProperty $NoPDF NoStaticDefaultVerb) {
|
||||
Remove-ItemProperty $NoPDF NoStaticDefaultVerb
|
||||
}
|
||||
If (Get-ItemProperty $NoProgids NoOpenWith) {
|
||||
Remove-ItemProperty $NoProgids NoOpenWith
|
||||
}
|
||||
If (Get-ItemProperty $NoProgids NoStaticDefaultVerb) {
|
||||
Remove-ItemProperty $NoProgids NoStaticDefaultVerb
|
||||
}
|
||||
If (Get-ItemProperty $NoWithList NoOpenWith) {
|
||||
Remove-ItemProperty $NoWithList NoOpenWith
|
||||
}
|
||||
If (Get-ItemProperty $NoWithList NoStaticDefaultVerb) {
|
||||
Remove-ItemProperty $NoWithList NoStaticDefaultVerb
|
||||
}
|
||||
|
||||
#Removes an underscore '_' from the Registry key for Edge
|
||||
$Edge2 = "HKCR:\AppXd4nrz8ff68srnhf9t5a8sbjyar1cr723_"
|
||||
If (Test-Path $Edge2) {
|
||||
Set-Item $Edge2 AppXd4nrz8ff68srnhf9t5a8sbjyar1cr723
|
||||
}
|
||||
}
|
||||
|
||||
Function FixWhitelistedApps {
|
||||
|
||||
If (!(Get-AppxPackage -AllUsers | Select Microsoft.Paint3D, Microsoft.WindowsCalculator, Microsoft.WindowsStore, Microsoft.Windows.Photos)) {
|
||||
|
||||
#Credit to abulgatz for these 4 lines of code
|
||||
Get-AppxPackage -allusers Microsoft.Paint3D | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"}
|
||||
Get-AppxPackage -allusers Microsoft.WindowsCalculator | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"}
|
||||
Get-AppxPackage -allusers Microsoft.WindowsStore | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"}
|
||||
Get-AppxPackage -allusers Microsoft.Windows.Photos | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"}
|
||||
}
|
||||
}
|
||||
|
||||
Function UninstallOneDrive {
|
||||
|
||||
Write-Host "Checking for pre-existing files and folders located in the OneDrive folders..."
|
||||
Start-Sleep 1
|
||||
If (Test-Path "$env:USERPROFILE\OneDrive\*") {
|
||||
Write-Host "Files found within the OneDrive folder! Checking to see if a folder named OneDriveBackupFiles exists."
|
||||
Start-Sleep 1
|
||||
|
||||
If (Test-Path "$env:USERPROFILE\Desktop\OneDriveBackupFiles") {
|
||||
Write-Host "A folder named OneDriveBackupFiles already exists on your desktop. All files from your OneDrive location will be moved to that folder."
|
||||
}
|
||||
else {
|
||||
If (!(Test-Path "$env:USERPROFILE\Desktop\OneDriveBackupFiles")) {
|
||||
Write-Host "A folder named OneDriveBackupFiles will be created and will be located on your desktop. All files from your OneDrive location will be located in that folder."
|
||||
New-item -Path "$env:USERPROFILE\Desktop" -Name "OneDriveBackupFiles"-ItemType Directory -Force
|
||||
Write-Host "Successfully created the folder 'OneDriveBackupFiles' on your desktop."
|
||||
}
|
||||
}
|
||||
Start-Sleep 1
|
||||
Move-Item -Path "$env:USERPROFILE\OneDrive\*" -Destination "$env:USERPROFILE\Desktop\OneDriveBackupFiles" -Force
|
||||
Write-Host "Successfully moved all files/folders from your OneDrive folder to the folder 'OneDriveBackupFiles' on your desktop."
|
||||
Start-Sleep 1
|
||||
Write-Host "Proceeding with the removal of OneDrive."
|
||||
Start-Sleep 1
|
||||
}
|
||||
Else {
|
||||
Write-Host "Either the OneDrive folder does not exist or there are no files to be found in the folder. Proceeding with removal of OneDrive."
|
||||
Start-Sleep 1
|
||||
Write-Host "Enabling the Group Policy 'Prevent the usage of OneDrive for File Storage'."
|
||||
$OneDriveKey = 'HKLM:Software\Policies\Microsoft\Windows\OneDrive'
|
||||
If (!(Test-Path $OneDriveKey)) {
|
||||
Mkdir $OneDriveKey
|
||||
Set-ItemProperty $OneDriveKey -Name OneDrive -Value DisableFileSyncNGSC
|
||||
}
|
||||
Set-ItemProperty $OneDriveKey -Name OneDrive -Value DisableFileSyncNGSC
|
||||
}
|
||||
|
||||
Write-Host "Uninstalling OneDrive. Please wait..."
|
||||
|
||||
|
||||
New-PSDrive HKCR -PSProvider Registry -Root HKEY_CLASSES_ROOT
|
||||
$onedrive = "$env:SYSTEMROOT\SysWOW64\OneDriveSetup.exe"
|
||||
$ExplorerReg1 = "HKCR:\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}"
|
||||
$ExplorerReg2 = "HKCR:\Wow6432Node\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}"
|
||||
Stop-Process -Name "OneDrive*"
|
||||
Start-Sleep 2
|
||||
If (!(Test-Path $onedrive)) {
|
||||
$onedrive = "$env:SYSTEMROOT\System32\OneDriveSetup.exe"
|
||||
|
||||
New-PSDrive HKCR -PSProvider Registry -Root HKEY_CLASSES_ROOT
|
||||
$onedrive = "$env:SYSTEMROOT\SysWOW64\OneDriveSetup.exe"
|
||||
$ExplorerReg1 = "HKCR:\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}"
|
||||
$ExplorerReg2 = "HKCR:\Wow6432Node\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}"
|
||||
Stop-Process -Name "OneDrive*"
|
||||
Start-Sleep 2
|
||||
If (!(Test-Path $onedrive)) {
|
||||
$onedrive = "$env:SYSTEMROOT\System32\OneDriveSetup.exe"
|
||||
}
|
||||
Start-Process $onedrive "/uninstall" -NoNewWindow -Wait
|
||||
Start-Sleep 2
|
||||
Write-Output "Stopping explorer"
|
||||
Start-Sleep 1
|
||||
taskkill.exe /F /IM explorer.exe
|
||||
Start-Sleep 3
|
||||
Write-Output "Removing leftover files"
|
||||
Remove-Item "$env:USERPROFILE\OneDrive" -Force -Recurse
|
||||
Remove-Item "$env:LOCALAPPDATA\Microsoft\OneDrive" -Force -Recurse
|
||||
Remove-Item "$env:PROGRAMDATA\Microsoft OneDrive" -Force -Recurse
|
||||
If (Test-Path "$env:SYSTEMDRIVE\OneDriveTemp") {
|
||||
Remove-Item "$env:SYSTEMDRIVE\OneDriveTemp" -Force -Recurse
|
||||
}
|
||||
Write-Output "Removing OneDrive from windows explorer"
|
||||
If (!(Test-Path $ExplorerReg1)) {
|
||||
New-Item $ExplorerReg1
|
||||
}
|
||||
Set-ItemProperty $ExplorerReg1 System.IsPinnedToNameSpaceTree -Value 0
|
||||
If (!(Test-Path $ExplorerReg2)) {
|
||||
New-Item $ExplorerReg2
|
||||
}
|
||||
Set-ItemProperty $ExplorerReg2 System.IsPinnedToNameSpaceTree -Value 0
|
||||
Write-Output "Restarting Explorer that was shut down before."
|
||||
Start-Process explorer.exe -NoNewWindow
|
||||
|
||||
Write-Host "Enabling the Group Policy 'Prevent the usage of OneDrive for File Storage'."
|
||||
$OneDriveKey = 'HKLM:Software\Policies\Microsoft\Windows\OneDrive'
|
||||
If (!(Test-Path $OneDriveKey)) {
|
||||
Mkdir $OneDriveKey
|
||||
}
|
||||
Start-Process $onedrive "/uninstall" -NoNewWindow -Wait
|
||||
Start-Sleep 2
|
||||
Write-Host "Stopping explorer"
|
||||
Start-Sleep 1
|
||||
taskkill.exe /F /IM explorer.exe
|
||||
Start-Sleep 3
|
||||
Write-Host "Removing leftover files"
|
||||
If (Test-Path "$env:USERPROFILE\OneDrive") {
|
||||
Remove-Item "$env:USERPROFILE\OneDrive" -Force -Recurse
|
||||
}
|
||||
If (Test-Path "$env:LOCALAPPDATA\Microsoft\OneDrive") {
|
||||
Remove-Item "$env:LOCALAPPDATA\Microsoft\OneDrive" -Force -Recurse
|
||||
}
|
||||
If (Test-Path "$env:PROGRAMDATA\Microsoft OneDrive") {
|
||||
Remove-Item "$env:PROGRAMDATA\Microsoft OneDrive" -Force -Recurse
|
||||
}
|
||||
If (Test-Path "$env:SYSTEMDRIVE\OneDriveTemp") {
|
||||
Remove-Item "$env:SYSTEMDRIVE\OneDriveTemp" -Force -Recurse
|
||||
}
|
||||
Write-Host "Removing OneDrive from windows explorer"
|
||||
If (!(Test-Path $ExplorerReg1)) {
|
||||
New-Item $ExplorerReg1
|
||||
}
|
||||
Set-ItemProperty $ExplorerReg1 System.IsPinnedToNameSpaceTree -Value 0
|
||||
If (!(Test-Path $ExplorerReg2)) {
|
||||
New-Item $ExplorerReg2
|
||||
}
|
||||
Set-ItemProperty $ExplorerReg2 System.IsPinnedToNameSpaceTree -Value 0
|
||||
Write-Host "Restarting Explorer that was shut down before."
|
||||
Start-Process explorer.exe -NoNewWindow
|
||||
Write-Host "OneDrive has been successfully uninstalled!"
|
||||
|
||||
Remove-item env:OneDrive
|
||||
}
|
||||
}
|
||||
|
||||
Function UnpinStart {
|
||||
#https://superuser.com/questions/1068382/how-to-remove-all-the-tiles-in-the-windows-10-start-menu
|
||||
#Unpins all tiles from the Start Menu
|
||||
Write-Host "Unpinning all tiles from the start menu"
|
||||
(New-Object -Com Shell.Application).
|
||||
NameSpace('shell:::{4234d49b-0245-4df3-b780-3893943456e1}').
|
||||
Items() |
|
||||
% { $_.Verbs() } |
|
||||
? {$_.Name -match 'Un.*pin from Start'} |
|
||||
% {$_.DoIt()}
|
||||
}
|
||||
|
||||
Function Remove3dObjects {
|
||||
#Removes 3D Objects from the 'My Computer' submenu in explorer
|
||||
Write-Host "Removing 3D Objects from explorer 'My Computer' submenu"
|
||||
$Objects32 = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace\{0DB7E03F-FC29-4DC6-9020-FF41B59E513A}"
|
||||
$Objects64 = "HKLM:\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace\{0DB7E03F-FC29-4DC6-9020-FF41B59E513A}"
|
||||
If (Test-Path $Objects32) {
|
||||
Remove-Item $Objects32 -Recurse
|
||||
}
|
||||
If (Test-Path $Objects64) {
|
||||
Remove-Item $Objects64 -Recurse
|
||||
}
|
||||
}
|
||||
|
||||
Function Restore3dObjects {
|
||||
#Restores 3D Objects from the 'My Computer' submenu in explorer
|
||||
Write-Host "Restoring 3D Objects from explorer 'My Computer' submenu"
|
||||
$Objects32 = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace\{0DB7E03F-FC29-4DC6-9020-FF41B59E513A}"
|
||||
$Objects64 = "HKLM:\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace\{0DB7E03F-FC29-4DC6-9020-FF41B59E513A}"
|
||||
If (!(Test-Path $Objects32)) {
|
||||
New-Item $Objects32
|
||||
}
|
||||
If (!(Test-Path $Objects64)) {
|
||||
New-Item $Objects64
|
||||
}
|
||||
}
|
||||
|
||||
#Interactive prompt Debloat/Revert options
|
||||
$Button = [Windows.MessageBoxButton]::YesNoCancel
|
||||
$ErrorIco = [Windows.MessageBoxImage]::Error
|
||||
$Warn = [Windows.MessageBoxImage]::Warning
|
||||
$Ask = 'The following will allow you to either Debloat Windows 10 or to revert changes made after Debloating Windows 10.
|
||||
|
||||
Select "Yes" to Debloat Windows 10
|
||||
|
||||
Select "No" to Revert changes made by this script
|
||||
|
||||
Select "Cancel" to stop the script.'
|
||||
|
||||
$EverythingorSpecific = "Would you like to remove everything that was preinstalled on your Windows Machine? Select Yes to remove everything, or select No to remove apps via a blacklist."
|
||||
$EdgePdf = "Do you want to stop edge from taking over as the default PDF viewer?"
|
||||
$EdgePdf2 = "Do you want to revert changes that disabled Edge as the default PDF viewer?"
|
||||
$Reboot = "For some of the changes to properly take effect it is recommended to reboot your machine. Would you like to restart?"
|
||||
$OneDriveDelete = "Do you want to uninstall One Drive?"
|
||||
$Unpin = "Do you want to unpin all items from the Start menu?"
|
||||
$InstallNET = "Do you want to install .NET 3.5?"
|
||||
$Prompt1 = [Windows.MessageBox]::Show($Ask, "Debloat or Revert", $Button, $ErrorIco)
|
||||
Switch ($Prompt1) {
|
||||
#This will debloat Windows 10
|
||||
Yes {
|
||||
#Everything is specific prompt
|
||||
$Prompt2 = [Windows.MessageBox]::Show($EverythingorSpecific, "Everything or Specific", $Button, $Warn)
|
||||
switch ($Prompt2) {
|
||||
Yes {
|
||||
#Creates a "drive" to access the HKCR (HKEY_CLASSES_ROOT)
|
||||
Write-Host "Creating PSDrive 'HKCR' (HKEY_CLASSES_ROOT). This will be used for the duration of the script as it is necessary for the removal and modification of specific registry keys."
|
||||
New-PSDrive HKCR -PSProvider Registry -Root HKEY_CLASSES_ROOT
|
||||
Start-Sleep 1
|
||||
Write-Host "Uninstalling bloatware, please wait."
|
||||
DebloatAll
|
||||
Write-Host "Bloatware removed."
|
||||
Start-Sleep 1
|
||||
Write-Host "Removing specific registry keys."
|
||||
Remove-Keys
|
||||
Write-Host "Leftover bloatware registry keys removed."
|
||||
Start-Sleep 1
|
||||
Write-Host "Checking to see if any Whitelisted Apps were removed, and if so re-adding them."
|
||||
Start-Sleep 1
|
||||
FixWhitelistedApps
|
||||
Start-Sleep 1
|
||||
Write-Host "Disabling Cortana from search, disabling feedback to Microsoft, and disabling scheduled tasks that are considered to be telemetry or unnecessary."
|
||||
Protect-Privacy
|
||||
Start-Sleep 1
|
||||
DisableCortana
|
||||
Write-Host "Cortana disabled and removed from search, feedback to Microsoft has been disabled, and scheduled tasks are disabled."
|
||||
Start-Sleep 1
|
||||
Write-Host "Stopping and disabling Diagnostics Tracking Service"
|
||||
DisableDiagTrack
|
||||
Write-Host "Diagnostics Tracking Service disabled"
|
||||
Start-Sleep 1
|
||||
Write-Host "Disabling WAP push service"
|
||||
DisableWAPPush
|
||||
Start-Sleep 1
|
||||
Write-Host "Re-enabling DMWAppushservice if it was disabled"
|
||||
CheckDMWService
|
||||
Start-Sleep 1
|
||||
Write-Host "Removing 3D Objects from the 'My Computer' submenu in explorer"
|
||||
Remove3dObjects
|
||||
Start-Sleep 1
|
||||
}
|
||||
No {
|
||||
#Creates a "drive" to access the HKCR (HKEY_CLASSES_ROOT)
|
||||
Write-Host "Creating PSDrive 'HKCR' (HKEY_CLASSES_ROOT). This will be used for the duration of the script as it is necessary for the removal and modification of specific registry keys."
|
||||
New-PSDrive HKCR -PSProvider Registry -Root HKEY_CLASSES_ROOT
|
||||
Start-Sleep 1
|
||||
Write-Host "Uninstalling bloatware, please wait."
|
||||
DebloatBlacklist
|
||||
Write-Host "Bloatware removed."
|
||||
Start-Sleep 1
|
||||
Write-Host "Removing specific registry keys."
|
||||
Remove-Keys
|
||||
Write-Host "Leftover bloatware registry keys removed."
|
||||
Start-Sleep 1
|
||||
Write-Host "Checking to see if any Whitelisted Apps were removed, and if so re-adding them."
|
||||
Start-Sleep 1
|
||||
FixWhitelistedApps
|
||||
Start-Sleep 1
|
||||
Write-Host "Disabling Cortana from search, disabling feedback to Microsoft, and disabling scheduled tasks that are considered to be telemetry or unnecessary."
|
||||
Protect-Privacy
|
||||
Start-Sleep 1
|
||||
DisableCortana
|
||||
Write-Host "Cortana disabled and removed from search, feedback to Microsoft has been disabled, and scheduled tasks are disabled."
|
||||
Start-Sleep 1
|
||||
Write-Host "Stopping and disabling Diagnostics Tracking Service"
|
||||
DisableDiagTrack
|
||||
Write-Host "Diagnostics Tracking Service disabled"
|
||||
Start-Sleep 1
|
||||
Write-Host "Disabling WAP push service"
|
||||
Start-Sleep 1
|
||||
DisableWAPPush
|
||||
Write-Host "Re-enabling DMWAppushservice if it was disabled"
|
||||
CheckDMWService
|
||||
Start-Sleep 1
|
||||
}
|
||||
}
|
||||
#Disabling EdgePDF prompt
|
||||
$Prompt3 = [Windows.MessageBox]::Show($EdgePdf, "Edge PDF", $Button, $Warn)
|
||||
Switch ($Prompt3) {
|
||||
Yes {
|
||||
Stop-EdgePDF
|
||||
Write-Host "Edge will no longer take over as the default PDF viewer."
|
||||
}
|
||||
No {
|
||||
Write-Host "You chose not to stop Edge from taking over as the default PDF viewer."
|
||||
}
|
||||
}
|
||||
#Prompt asking to delete OneDrive
|
||||
$Prompt4 = [Windows.MessageBox]::Show($OneDriveDelete, "Delete OneDrive", $Button, $ErrorIco)
|
||||
Switch ($Prompt4) {
|
||||
Yes {
|
||||
UninstallOneDrive
|
||||
Write-Host "OneDrive is now removed from the computer."
|
||||
}
|
||||
No {
|
||||
Write-Host "You have chosen to skip removing OneDrive from your machine."
|
||||
}
|
||||
}
|
||||
#Prompt asking if you'd like to unpin all start items
|
||||
$Prompt5 = [Windows.MessageBox]::Show($Unpin, "Unpin", $Button, $ErrorIco)
|
||||
Switch ($Prompt5) {
|
||||
Yes {
|
||||
UnpinStart
|
||||
Write-Host "Start Apps unpined."
|
||||
}
|
||||
No {
|
||||
Write-Host "Apps will remain pinned to the start menu."
|
||||
|
||||
}
|
||||
}
|
||||
#Prompt asking if you want to install .NET
|
||||
$Prompt6 = [Windows.MessageBox]::Show($InstallNET, "Install .Net", $Button, $Warn)
|
||||
Switch ($Prompt6) {
|
||||
Yes {
|
||||
Write-Host "Initializing the installation of .NET 3.5..."
|
||||
DISM /Online /Enable-Feature /FeatureName:NetFx3 /All
|
||||
Write-Host ".NET 3.5 has been successfully installed!"
|
||||
}
|
||||
No {
|
||||
Write-Host "Skipping .NET install."
|
||||
}
|
||||
}
|
||||
#Prompt asking if you'd like to reboot your machine
|
||||
$Prompt7 = [Windows.MessageBox]::Show($Reboot, "Reboot", $Button, $Warn)
|
||||
Switch ($Prompt7) {
|
||||
Yes {
|
||||
Write-Host "Unloading the HKCR drive..."
|
||||
Remove-PSDrive HKCR
|
||||
Start-Sleep 1
|
||||
Write-Host "Initiating reboot."
|
||||
Stop-Transcript
|
||||
Start-Sleep 2
|
||||
Restart-Computer
|
||||
}
|
||||
No {
|
||||
Write-Host "Unloading the HKCR drive..."
|
||||
Remove-PSDrive HKCR
|
||||
Start-Sleep 1
|
||||
Write-Host "Script has finished. Exiting."
|
||||
Stop-Transcript
|
||||
Start-Sleep 2
|
||||
Exit
|
||||
}
|
||||
}
|
||||
}
|
||||
No {
|
||||
Write-Host "Reverting changes..."
|
||||
Write-Host "Creating PSDrive 'HKCR' (HKEY_CLASSES_ROOT). This will be used for the duration of the script as it is necessary for the modification of specific registry keys."
|
||||
New-PSDrive HKCR -PSProvider Registry -Root HKEY_CLASSES_ROOT
|
||||
Revert-Changes
|
||||
#Prompt asking to revert edge changes as well
|
||||
$Prompt6 = [Windows.MessageBox]::Show($EdgePdf2, "Revert Edge", $Button, $ErrorIco)
|
||||
Switch ($Prompt6) {
|
||||
Yes {
|
||||
Enable-EdgePDF
|
||||
Write-Host "Edge will no longer be disabled from being used as the default Edge PDF viewer."
|
||||
}
|
||||
No {
|
||||
Write-Host "You have chosen to keep the setting that disallows Edge to be the default PDF viewer."
|
||||
}
|
||||
}
|
||||
#Prompt asking if you'd like to reboot your machine
|
||||
$Prompt7 = [Windows.MessageBox]::Show($Reboot, "Reboot", $Button, $Warn)
|
||||
Switch ($Prompt7) {
|
||||
Yes {
|
||||
Write-Host "Unloading the HKCR drive..."
|
||||
Remove-PSDrive HKCR
|
||||
Start-Sleep 1
|
||||
Write-Host "Initiating reboot."
|
||||
Stop-Transcript
|
||||
Start-Sleep 2
|
||||
Restart-Computer
|
||||
}
|
||||
No {
|
||||
Write-Host "Unloading the HKCR drive..."
|
||||
Remove-PSDrive HKCR
|
||||
Start-Sleep 1
|
||||
Write-Host "Script has finished. Exiting."
|
||||
Stop-Transcript
|
||||
Start-Sleep 2
|
||||
Exit
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
219
scripts/block-telemetry.ps1
vendored
Normal file
219
scripts/block-telemetry.ps1
vendored
Normal file
|
@ -0,0 +1,219 @@
|
|||
### This script blocks telemetry related domains via the hosts file and related IPs via Windows Firewall. ###
|
||||
###- Please note that adding these domains may break certain software like iTunes or Skype. As this issue is location dependent for some domains, they are not commented by default. ###
|
||||
### The domains known to cause issues marked accordingly.
|
||||
### Please see the related issue: https://github.com/W4RH4WK/Debloat-Windows-10/issues/79 ###
|
||||
### Author of this script: https://github.com/W4RH4WK/Debloat-Windows-10
|
||||
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\force-mkdir.psm1
|
||||
|
||||
Write-Output "Disabling telemetry via Group Policies"
|
||||
force-mkdir "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection" "AllowTelemetry" 0
|
||||
|
||||
# Entries related to Akamai have been reported to cause issues with Widevine
|
||||
# DRM.
|
||||
|
||||
Write-Output "Adding telemetry domains to hosts file"
|
||||
$hosts_file = "$env:systemroot\System32\drivers\etc\hosts"
|
||||
$domains = @(
|
||||
"184-86-53-99.deploy.static.akamaitechnologies.com"
|
||||
"a-0001.a-msedge.net"
|
||||
"a-0002.a-msedge.net"
|
||||
"a-0003.a-msedge.net"
|
||||
"a-0004.a-msedge.net"
|
||||
"a-0005.a-msedge.net"
|
||||
"a-0006.a-msedge.net"
|
||||
"a-0007.a-msedge.net"
|
||||
"a-0008.a-msedge.net"
|
||||
"a-0009.a-msedge.net"
|
||||
"a1621.g.akamai.net"
|
||||
"a1856.g2.akamai.net"
|
||||
"a1961.g.akamai.net"
|
||||
#"a248.e.akamai.net" # makes iTunes download button disappear (#43)
|
||||
"a978.i6g1.akamai.net"
|
||||
"a.ads1.msn.com"
|
||||
"a.ads2.msads.net"
|
||||
"a.ads2.msn.com"
|
||||
"ac3.msn.com"
|
||||
"ad.doubleclick.net"
|
||||
"adnexus.net"
|
||||
"adnxs.com"
|
||||
"ads1.msads.net"
|
||||
"ads1.msn.com"
|
||||
"ads.msn.com"
|
||||
"aidps.atdmt.com"
|
||||
"aka-cdn-ns.adtech.de"
|
||||
"a-msedge.net"
|
||||
"any.edge.bing.com"
|
||||
"a.rad.msn.com"
|
||||
"az361816.vo.msecnd.net"
|
||||
"az512334.vo.msecnd.net"
|
||||
"b.ads1.msn.com"
|
||||
"b.ads2.msads.net"
|
||||
"bingads.microsoft.com"
|
||||
"b.rad.msn.com"
|
||||
"bs.serving-sys.com"
|
||||
"c.atdmt.com"
|
||||
"cdn.atdmt.com"
|
||||
"cds26.ams9.msecn.net"
|
||||
"choice.microsoft.com"
|
||||
"choice.microsoft.com.nsatc.net"
|
||||
"compatexchange.cloudapp.net"
|
||||
"corpext.msitadfs.glbdns2.microsoft.com"
|
||||
"corp.sts.microsoft.com"
|
||||
"cs1.wpc.v0cdn.net"
|
||||
"db3aqu.atdmt.com"
|
||||
"df.telemetry.microsoft.com"
|
||||
"diagnostics.support.microsoft.com"
|
||||
"e2835.dspb.akamaiedge.net"
|
||||
"e7341.g.akamaiedge.net"
|
||||
"e7502.ce.akamaiedge.net"
|
||||
"e8218.ce.akamaiedge.net"
|
||||
"ec.atdmt.com"
|
||||
"fe2.update.microsoft.com.akadns.net"
|
||||
"feedback.microsoft-hohm.com"
|
||||
"feedback.search.microsoft.com"
|
||||
"feedback.windows.com"
|
||||
"flex.msn.com"
|
||||
"g.msn.com"
|
||||
"h1.msn.com"
|
||||
"h2.msn.com"
|
||||
"hostedocsp.globalsign.com"
|
||||
"i1.services.social.microsoft.com"
|
||||
"i1.services.social.microsoft.com.nsatc.net"
|
||||
"ipv6.msftncsi.com"
|
||||
"ipv6.msftncsi.com.edgesuite.net"
|
||||
"lb1.www.ms.akadns.net"
|
||||
"live.rads.msn.com"
|
||||
"m.adnxs.com"
|
||||
"msedge.net"
|
||||
"msftncsi.com"
|
||||
"msnbot-65-55-108-23.search.msn.com"
|
||||
"msntest.serving-sys.com"
|
||||
"oca.telemetry.microsoft.com"
|
||||
"oca.telemetry.microsoft.com.nsatc.net"
|
||||
"onesettings-db5.metron.live.nsatc.net"
|
||||
"pre.footprintpredict.com"
|
||||
"preview.msn.com"
|
||||
"rad.live.com"
|
||||
"rad.msn.com"
|
||||
"redir.metaservices.microsoft.com"
|
||||
"reports.wes.df.telemetry.microsoft.com"
|
||||
"schemas.microsoft.akadns.net"
|
||||
"secure.adnxs.com"
|
||||
"secure.flashtalking.com"
|
||||
"services.wes.df.telemetry.microsoft.com"
|
||||
"settings-sandbox.data.microsoft.com"
|
||||
#"settings-win.data.microsoft.com" # may cause issues with Windows Updates
|
||||
"sls.update.microsoft.com.akadns.net"
|
||||
#"sls.update.microsoft.com.nsatc.net" # may cause issues with Windows Updates
|
||||
"sqm.df.telemetry.microsoft.com"
|
||||
"sqm.telemetry.microsoft.com"
|
||||
"sqm.telemetry.microsoft.com.nsatc.net"
|
||||
"ssw.live.com"
|
||||
"static.2mdn.net"
|
||||
"statsfe1.ws.microsoft.com"
|
||||
"statsfe2.update.microsoft.com.akadns.net"
|
||||
"statsfe2.ws.microsoft.com"
|
||||
"survey.watson.microsoft.com"
|
||||
"telecommand.telemetry.microsoft.com"
|
||||
"telecommand.telemetry.microsoft.com.nsatc.net"
|
||||
"telemetry.appex.bing.net"
|
||||
"telemetry.microsoft.com"
|
||||
"telemetry.urs.microsoft.com"
|
||||
"vortex-bn2.metron.live.com.nsatc.net"
|
||||
"vortex-cy2.metron.live.com.nsatc.net"
|
||||
"vortex.data.microsoft.com"
|
||||
"vortex-sandbox.data.microsoft.com"
|
||||
"vortex-win.data.microsoft.com"
|
||||
"cy2.vortex.data.microsoft.com.akadns.net"
|
||||
"watson.live.com"
|
||||
"watson.microsoft.com"
|
||||
"watson.ppe.telemetry.microsoft.com"
|
||||
"watson.telemetry.microsoft.com"
|
||||
"watson.telemetry.microsoft.com.nsatc.net"
|
||||
"wes.df.telemetry.microsoft.com"
|
||||
"win10.ipv6.microsoft.com"
|
||||
"www.bingads.microsoft.com"
|
||||
"www.go.microsoft.akadns.net"
|
||||
"www.msftncsi.com"
|
||||
"client.wns.windows.com"
|
||||
#"wdcp.microsoft.com" # may cause issues with Windows Defender Cloud-based protection
|
||||
#"dns.msftncsi.com" # This causes Windows to think it doesn't have internet
|
||||
#"storeedgefd.dsx.mp.microsoft.com" # breaks Windows Store
|
||||
"wdcpalt.microsoft.com"
|
||||
"settings-ssl.xboxlive.com"
|
||||
"settings-ssl.xboxlive.com-c.edgekey.net"
|
||||
"settings-ssl.xboxlive.com-c.edgekey.net.globalredir.akadns.net"
|
||||
"e87.dspb.akamaidege.net"
|
||||
"insiderservice.microsoft.com"
|
||||
"insiderservice.trafficmanager.net"
|
||||
"e3843.g.akamaiedge.net"
|
||||
"flightingserviceweurope.cloudapp.net"
|
||||
#"sls.update.microsoft.com" # may cause issues with Windows Updates
|
||||
"static.ads-twitter.com" # may cause issues with Twitter login
|
||||
"www-google-analytics.l.google.com"
|
||||
"p.static.ads-twitter.com" # may cause issues with Twitter login
|
||||
"hubspot.net.edge.net"
|
||||
"e9483.a.akamaiedge.net"
|
||||
|
||||
#"www.google-analytics.com"
|
||||
#"padgead2.googlesyndication.com"
|
||||
#"mirror1.malwaredomains.com"
|
||||
#"mirror.cedia.org.ec"
|
||||
"stats.g.doubleclick.net"
|
||||
"stats.l.doubleclick.net"
|
||||
"adservice.google.de"
|
||||
"adservice.google.com"
|
||||
"googleads.g.doubleclick.net"
|
||||
"pagead46.l.doubleclick.net"
|
||||
"hubspot.net.edgekey.net"
|
||||
"insiderppe.cloudapp.net" # Feedback-Hub
|
||||
"livetileedge.dsx.mp.microsoft.com"
|
||||
|
||||
# extra
|
||||
"fe2.update.microsoft.com.akadns.net"
|
||||
"s0.2mdn.net"
|
||||
"statsfe2.update.microsoft.com.akadns.net"
|
||||
"survey.watson.microsoft.com"
|
||||
"view.atdmt.com"
|
||||
"watson.microsoft.com"
|
||||
"watson.ppe.telemetry.microsoft.com"
|
||||
"watson.telemetry.microsoft.com"
|
||||
"watson.telemetry.microsoft.com.nsatc.net"
|
||||
"wes.df.telemetry.microsoft.com"
|
||||
"m.hotmail.com"
|
||||
|
||||
# can cause issues with Skype (#79) or other services (#171)
|
||||
"apps.skype.com"
|
||||
"c.msn.com"
|
||||
# "login.live.com" # prevents login to outlook and other live apps
|
||||
"pricelist.skype.com"
|
||||
"s.gateway.messenger.live.com"
|
||||
"ui.skype.com"
|
||||
)
|
||||
Write-Output "" | Out-File -Encoding ASCII -Append $hosts_file
|
||||
foreach ($domain in $domains) {
|
||||
if (-Not (Select-String -Path $hosts_file -Pattern $domain)) {
|
||||
Write-Output "0.0.0.0 $domain" | Out-File -Encoding ASCII -Append $hosts_file
|
||||
}
|
||||
}
|
||||
|
||||
Write-Output "Adding telemetry ips to firewall"
|
||||
$ips = @(
|
||||
"134.170.30.202"
|
||||
"137.116.81.24"
|
||||
"157.56.106.189"
|
||||
"184.86.53.99"
|
||||
"2.22.61.43"
|
||||
"2.22.61.66"
|
||||
"204.79.197.200"
|
||||
"23.218.212.69"
|
||||
"65.39.117.230"
|
||||
"65.52.108.33" # Causes problems with Microsoft Store
|
||||
"65.55.108.23"
|
||||
"64.4.54.254"
|
||||
)
|
||||
Remove-NetFirewallRule -DisplayName "Block Telemetry IPs" -ErrorAction SilentlyContinue
|
||||
New-NetFirewallRule -DisplayName "Block Telemetry IPs" -Direction Outbound `
|
||||
-Action Block -RemoteAddress ([string[]]$ips)
|
32
scripts/disable-services.ps1
vendored
Normal file
32
scripts/disable-services.ps1
vendored
Normal file
|
@ -0,0 +1,32 @@
|
|||
### This script disables unwanted Windows services. ###
|
||||
### If you do not want to disable certain services comment out the corresponding lines below.###
|
||||
### Author of this script: https://github.com/W4RH4WK/Debloat-Windows-10
|
||||
|
||||
$services = @(
|
||||
"diagnosticshub.standardcollector.service" # Microsoft (R) Diagnostics Hub Standard Collector Service
|
||||
"DiagTrack" # Diagnostics Tracking Service
|
||||
"dmwappushservice" # WAP Push Message Routing Service (see known issues)
|
||||
"lfsvc" # Geolocation Service
|
||||
"MapsBroker" # Downloaded Maps Manager
|
||||
"NetTcpPortSharing" # Net.Tcp Port Sharing Service
|
||||
"RemoteAccess" # Routing and Remote Access
|
||||
"RemoteRegistry" # Remote Registry
|
||||
"SharedAccess" # Internet Connection Sharing (ICS)
|
||||
"TrkWks" # Distributed Link Tracking Client
|
||||
"WbioSrvc" # Windows Biometric Service (required for Fingerprint reader / facial detection)
|
||||
#"WlanSvc" # WLAN AutoConfig
|
||||
"WMPNetworkSvc" # Windows Media Player Network Sharing Service
|
||||
"wscsvc" # Windows Security Center Service
|
||||
#"WSearch" # Windows Search
|
||||
"XblAuthManager" # Xbox Live Auth Manager
|
||||
"XblGameSave" # Xbox Live Game Save Service
|
||||
"XboxNetApiSvc" # Xbox Live Networking Service
|
||||
"ndu" # Windows Network Data Usage Monitor
|
||||
# Services which cannot be disabled
|
||||
#"WdNisSvc"
|
||||
)
|
||||
|
||||
foreach ($service in $services) {
|
||||
Write-Output "Trying to disable $service"
|
||||
Get-Service -Name $service | Set-Service -StartupType Disabled
|
||||
}
|
47
scripts/disable-windows-defender.ps1
vendored
Normal file
47
scripts/disable-windows-defender.ps1
vendored
Normal file
|
@ -0,0 +1,47 @@
|
|||
### This script disables Windows Defender. ###
|
||||
###- Run it once (will throw errors), then reboot, run it again (this time no errors should occur) followed by another reboot.###
|
||||
### Author of this script: https://github.com/W4RH4WK/Debloat-Windows-10
|
||||
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\force-mkdir.psm1
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\take-own.psm1
|
||||
|
||||
Write-Output "Elevating priviledges for this process"
|
||||
do {} until (Elevate-Privileges SeTakeOwnershipPrivilege)
|
||||
|
||||
$tasks = @(
|
||||
"\Microsoft\Windows\Windows Defender\Windows Defender Cache Maintenance"
|
||||
"\Microsoft\Windows\Windows Defender\Windows Defender Cleanup"
|
||||
"\Microsoft\Windows\Windows Defender\Windows Defender Scheduled Scan"
|
||||
"\Microsoft\Windows\Windows Defender\Windows Defender Verification"
|
||||
)
|
||||
|
||||
foreach ($task in $tasks) {
|
||||
$parts = $task.split('\')
|
||||
$name = $parts[-1]
|
||||
$path = $parts[0..($parts.length-2)] -join '\'
|
||||
|
||||
Write-Output "Trying to disable scheduled task $name"
|
||||
Disable-ScheduledTask -TaskName "$name" -TaskPath "$path"
|
||||
}
|
||||
|
||||
Write-Output "Disabling Windows Defender via Group Policies"
|
||||
force-mkdir "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows Defender"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows Defender" "DisableAntiSpyware" 1
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows Defender" "DisableRoutinelyTakingAction" 1
|
||||
force-mkdir "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows Defender\Real-Time Protection"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows Defender\Real-Time Protection" "DisableRealtimeMonitoring" 1
|
||||
|
||||
Write-Output "Disabling Windows Defender Services"
|
||||
Takeown-Registry("HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\WinDefend")
|
||||
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\WinDefend" "Start" 4
|
||||
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\WinDefend" "AutorunsDisabled" 3
|
||||
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\WdNisSvc" "Start" 4
|
||||
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\WdNisSvc" "AutorunsDisabled" 3
|
||||
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\Sense" "Start" 4
|
||||
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\Sense" "AutorunsDisabled" 3
|
||||
|
||||
Write-Output "Removing Windows Defender context menu item"
|
||||
Set-Item "HKLM:\SOFTWARE\Classes\CLSID\{09A47860-11B0-4DA5-AFA5-26D86198A780}\InprocServer32" ""
|
||||
|
||||
Write-Output "Removing Windows Defender GUI / tray from autorun"
|
||||
Remove-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" "WindowsDefender" -ea 0
|
15
scripts/readme.txt
vendored
Normal file
15
scripts/readme.txt
vendored
Normal file
|
@ -0,0 +1,15 @@
|
|||
This feature enhances Spydish and adds several community powered PowerShell script files which allows to:
|
||||
- Uninstall preinstalled apps (debloating)
|
||||
- Disable various Windows 10 telemetry features
|
||||
- Block Microsoft telemetry IPs via Windows Firewall and hosts file
|
||||
- Remove OneDrive integration
|
||||
- Remove Windows Defender
|
||||
- and much more besides.
|
||||
|
||||
These are third party script files and the author of this app does not guarantee that they will also work for you. Every script contains a link to the original author.
|
||||
If you don't understand the scripts and know what they do, you should also NOT execute them.
|
||||
|
||||
You will also find bundled script files (called templates) written by the author of this app.
|
||||
These allow you to automate numerous processes, e.g. you could use the "templateBasicPrivacy" to handle the whole category Policies > Privacy in Spydish. Templates and script file written by the author of Spydish will get support on GitHub https://github.com/mirinsoft/spydish/issues
|
||||
|
||||
NOTE: If you no longer wish to see this notice, then remove the "readme.txt" in the scripts directory.
|
174
scripts/remove-default-apps.ps1
vendored
Normal file
174
scripts/remove-default-apps.ps1
vendored
Normal file
|
@ -0,0 +1,174 @@
|
|||
### This script removes unwanted Apps that come with Windows. ###
|
||||
### If you do not want to remove certain Apps comment out the corresponding lines below.###
|
||||
### Author of this script: https://github.com/W4RH4WK/Debloat-Windows-10
|
||||
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\take-own.psm1
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\force-mkdir.psm1
|
||||
|
||||
Write-Output "Elevating privileges for this process"
|
||||
do {} until (Elevate-Privileges SeTakeOwnershipPrivilege)
|
||||
|
||||
Write-Output "Uninstalling default apps"
|
||||
$apps = @(
|
||||
# default Windows 10 apps
|
||||
"Microsoft.3DBuilder"
|
||||
"Microsoft.Appconnector"
|
||||
"Microsoft.BingFinance"
|
||||
"Microsoft.BingNews"
|
||||
"Microsoft.BingSports"
|
||||
"Microsoft.BingTranslator"
|
||||
"Microsoft.BingWeather"
|
||||
#"Microsoft.FreshPaint"
|
||||
"Microsoft.GamingServices"
|
||||
"Microsoft.Microsoft3DViewer"
|
||||
"Microsoft.MicrosoftOfficeHub"
|
||||
"Microsoft.MicrosoftPowerBIForWindows"
|
||||
"Microsoft.MicrosoftSolitaireCollection"
|
||||
#"Microsoft.MicrosoftStickyNotes"
|
||||
"Microsoft.MinecraftUWP"
|
||||
"Microsoft.NetworkSpeedTest"
|
||||
"Microsoft.Office.OneNote"
|
||||
#"Microsoft.OneConnect"
|
||||
"Microsoft.People"
|
||||
"Microsoft.Print3D"
|
||||
"Microsoft.SkypeApp"
|
||||
"Microsoft.Wallet"
|
||||
#"Microsoft.Windows.Photos"
|
||||
"Microsoft.WindowsAlarms"
|
||||
#"Microsoft.WindowsCalculator"
|
||||
"Microsoft.WindowsCamera"
|
||||
"microsoft.windowscommunicationsapps"
|
||||
"Microsoft.WindowsMaps"
|
||||
"Microsoft.WindowsPhone"
|
||||
"Microsoft.WindowsSoundRecorder"
|
||||
#"Microsoft.WindowsStore" # can't be re-installed
|
||||
"Microsoft.Xbox.TCUI"
|
||||
"Microsoft.XboxApp"
|
||||
"Microsoft.XboxGameOverlay"
|
||||
"Microsoft.XboxGamingOverlay"
|
||||
"Microsoft.XboxSpeechToTextOverlay"
|
||||
"Microsoft.YourPhone"
|
||||
"Microsoft.ZuneMusic"
|
||||
"Microsoft.ZuneVideo"
|
||||
|
||||
# Threshold 2 apps
|
||||
"Microsoft.CommsPhone"
|
||||
"Microsoft.ConnectivityStore"
|
||||
"Microsoft.GetHelp"
|
||||
"Microsoft.Getstarted"
|
||||
"Microsoft.Messaging"
|
||||
"Microsoft.Office.Sway"
|
||||
"Microsoft.OneConnect"
|
||||
"Microsoft.WindowsFeedbackHub"
|
||||
|
||||
# Creators Update apps
|
||||
"Microsoft.Microsoft3DViewer"
|
||||
#"Microsoft.MSPaint"
|
||||
|
||||
#Redstone apps
|
||||
"Microsoft.BingFoodAndDrink"
|
||||
"Microsoft.BingHealthAndFitness"
|
||||
"Microsoft.BingTravel"
|
||||
"Microsoft.WindowsReadingList"
|
||||
|
||||
# Redstone 5 apps
|
||||
"Microsoft.MixedReality.Portal"
|
||||
"Microsoft.ScreenSketch"
|
||||
"Microsoft.XboxGamingOverlay"
|
||||
"Microsoft.YourPhone"
|
||||
|
||||
# non-Microsoft
|
||||
"2FE3CB00.PicsArt-PhotoStudio"
|
||||
"46928bounde.EclipseManager"
|
||||
"4DF9E0F8.Netflix"
|
||||
"613EBCEA.PolarrPhotoEditorAcademicEdition"
|
||||
"6Wunderkinder.Wunderlist"
|
||||
"7EE7776C.LinkedInforWindows"
|
||||
"89006A2E.AutodeskSketchBook"
|
||||
"9E2F88E3.Twitter"
|
||||
"A278AB0D.DisneyMagicKingdoms"
|
||||
"A278AB0D.MarchofEmpires"
|
||||
"ActiproSoftwareLLC.562882FEEB491" # next one is for the Code Writer from Actipro Software LLC
|
||||
"CAF9E577.Plex"
|
||||
"ClearChannelRadioDigital.iHeartRadio"
|
||||
"D52A8D61.FarmVille2CountryEscape"
|
||||
"D5EA27B7.Duolingo-LearnLanguagesforFree"
|
||||
"DB6EA5DB.CyberLinkMediaSuiteEssentials"
|
||||
"DolbyLaboratories.DolbyAccess"
|
||||
"DolbyLaboratories.DolbyAccess"
|
||||
"Drawboard.DrawboardPDF"
|
||||
"Facebook.Facebook"
|
||||
"Fitbit.FitbitCoach"
|
||||
"Flipboard.Flipboard"
|
||||
"GAMELOFTSA.Asphalt8Airborne"
|
||||
"KeeperSecurityInc.Keeper"
|
||||
"Microsoft.BingNews"
|
||||
"NORDCURRENT.COOKINGFEVER"
|
||||
"PandoraMediaInc.29680B314EFC2"
|
||||
"Playtika.CaesarsSlotsFreeCasino"
|
||||
"ShazamEntertainmentLtd.Shazam"
|
||||
"SlingTVLLC.SlingTV"
|
||||
"SpotifyAB.SpotifyMusic"
|
||||
#"TheNewYorkTimes.NYTCrossword"
|
||||
"ThumbmunkeysLtd.PhototasticCollage"
|
||||
"TuneIn.TuneInRadio"
|
||||
"WinZipComputing.WinZipUniversal"
|
||||
"XINGAG.XING"
|
||||
"flaregamesGmbH.RoyalRevolt2"
|
||||
"king.com.*"
|
||||
"king.com.BubbleWitch3Saga"
|
||||
"king.com.CandyCrushSaga"
|
||||
"king.com.CandyCrushSodaSaga"
|
||||
|
||||
# apps which cannot be removed using Remove-AppxPackage
|
||||
#"Microsoft.BioEnrollment"
|
||||
#"Microsoft.MicrosoftEdge"
|
||||
#"Microsoft.Windows.Cortana"
|
||||
#"Microsoft.WindowsFeedback"
|
||||
#"Microsoft.XboxGameCallableUI"
|
||||
#"Microsoft.XboxIdentityProvider"
|
||||
#"Windows.ContactSupport"
|
||||
|
||||
# apps which other apps depend on
|
||||
"Microsoft.Advertising.Xaml"
|
||||
)
|
||||
|
||||
foreach ($app in $apps) {
|
||||
Write-Output "Trying to remove $app"
|
||||
|
||||
Get-AppxPackage -Name $app -AllUsers | Remove-AppxPackage -AllUsers
|
||||
|
||||
Get-AppXProvisionedPackage -Online |
|
||||
Where-Object DisplayName -EQ $app |
|
||||
Remove-AppxProvisionedPackage -Online
|
||||
}
|
||||
|
||||
# Prevents Apps from re-installing
|
||||
$cdm = @(
|
||||
"ContentDeliveryAllowed"
|
||||
"FeatureManagementEnabled"
|
||||
"OemPreInstalledAppsEnabled"
|
||||
"PreInstalledAppsEnabled"
|
||||
"PreInstalledAppsEverEnabled"
|
||||
"SilentInstalledAppsEnabled"
|
||||
"SubscribedContent-314559Enabled"
|
||||
"SubscribedContent-338387Enabled"
|
||||
"SubscribedContent-338388Enabled"
|
||||
"SubscribedContent-338389Enabled"
|
||||
"SubscribedContent-338393Enabled"
|
||||
"SubscribedContentEnabled"
|
||||
"SystemPaneSuggestionsEnabled"
|
||||
)
|
||||
|
||||
force-mkdir "HKCU:\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager"
|
||||
foreach ($key in $cdm) {
|
||||
Set-ItemProperty "HKCU:\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" $key 0
|
||||
}
|
||||
|
||||
force-mkdir "HKLM:\SOFTWARE\Policies\Microsoft\WindowsStore"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Policies\Microsoft\WindowsStore" "AutoDownload" 2
|
||||
|
||||
# Prevents "Suggested Applications" returning
|
||||
force-mkdir "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent" "DisableWindowsConsumerFeatures" 1
|
||||
|
62
scripts/remove-onedrive.ps1
vendored
Normal file
62
scripts/remove-onedrive.ps1
vendored
Normal file
|
@ -0,0 +1,62 @@
|
|||
### This script will remove and disable OneDrive integration. ###
|
||||
### Author of this script: https://github.com/W4RH4WK/Debloat-Windows-10
|
||||
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\force-mkdir.psm1
|
||||
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\take-own.psm1
|
||||
|
||||
Write-Output "Kill OneDrive process"
|
||||
taskkill.exe /F /IM "OneDrive.exe"
|
||||
taskkill.exe /F /IM "explorer.exe"
|
||||
|
||||
Write-Output "Remove OneDrive"
|
||||
if (Test-Path "$env:systemroot\System32\OneDriveSetup.exe") {
|
||||
& "$env:systemroot\System32\OneDriveSetup.exe" /uninstall
|
||||
}
|
||||
if (Test-Path "$env:systemroot\SysWOW64\OneDriveSetup.exe") {
|
||||
& "$env:systemroot\SysWOW64\OneDriveSetup.exe" /uninstall
|
||||
}
|
||||
|
||||
Write-Output "Removing OneDrive leftovers"
|
||||
Remove-Item -Recurse -Force -ErrorAction SilentlyContinue "$env:localappdata\Microsoft\OneDrive"
|
||||
Remove-Item -Recurse -Force -ErrorAction SilentlyContinue "$env:programdata\Microsoft OneDrive"
|
||||
Remove-Item -Recurse -Force -ErrorAction SilentlyContinue "$env:systemdrive\OneDriveTemp"
|
||||
# check if directory is empty before removing:
|
||||
If ((Get-ChildItem "$env:userprofile\OneDrive" -Recurse | Measure-Object).Count -eq 0) {
|
||||
Remove-Item -Recurse -Force -ErrorAction SilentlyContinue "$env:userprofile\OneDrive"
|
||||
}
|
||||
|
||||
Write-Output "Disable OneDrive via Group Policies"
|
||||
force-mkdir "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows\OneDrive"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows\OneDrive" "DisableFileSyncNGSC" 1
|
||||
|
||||
Write-Output "Remove Onedrive from explorer sidebar"
|
||||
New-PSDrive -PSProvider "Registry" -Root "HKEY_CLASSES_ROOT" -Name "HKCR"
|
||||
mkdir -Force "HKCR:\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}"
|
||||
Set-ItemProperty "HKCR:\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}" "System.IsPinnedToNameSpaceTree" 0
|
||||
mkdir -Force "HKCR:\Wow6432Node\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}"
|
||||
Set-ItemProperty "HKCR:\Wow6432Node\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}" "System.IsPinnedToNameSpaceTree" 0
|
||||
Remove-PSDrive "HKCR"
|
||||
|
||||
# Thank you Matthew Israelsson
|
||||
Write-Output "Removing run hook for new users"
|
||||
reg load "hku\Default" "C:\Users\Default\NTUSER.DAT"
|
||||
reg delete "HKEY_USERS\Default\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" /v "OneDriveSetup" /f
|
||||
reg unload "hku\Default"
|
||||
|
||||
Write-Output "Removing startmenu entry"
|
||||
Remove-Item -Force -ErrorAction SilentlyContinue "$env:userprofile\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\OneDrive.lnk"
|
||||
|
||||
Write-Output "Removing scheduled task"
|
||||
Get-ScheduledTask -TaskPath '\' -TaskName 'OneDrive*' -ea SilentlyContinue | Unregister-ScheduledTask -Confirm:$false
|
||||
|
||||
Write-Output "Restarting explorer"
|
||||
Start-Process "explorer.exe"
|
||||
|
||||
Write-Output "Waiting for explorer to complete loading"
|
||||
Start-Sleep 10
|
||||
|
||||
Write-Output "Removing additional OneDrive leftovers"
|
||||
foreach ($item in (Get-ChildItem "$env:WinDir\WinSxS\*onedrive*")) {
|
||||
Takeown-Folder $item.FullName
|
||||
Remove-Item -Recurse -Force $item.FullName
|
||||
}
|
68
scripts/templateAppsPrivacy.ps1
vendored
Normal file
68
scripts/templateAppsPrivacy.ps1
vendored
Normal file
|
@ -0,0 +1,68 @@
|
|||
### This template will block and disable telemetry features of the following apps: ###
|
||||
###- Block Google Chrome Software Reporter Tool
|
||||
# The Software Reporter Tool (also known as Chrome Cleanup Tool and Software Removal Tool, the executable file is software_reporter_tool.exe), is a tool that Google distributes with the Google Chrome web browser.
|
||||
# It is a part of Google Chrome's Clean up Computer feature which scans your computer for harmful software. If this tool finds any harmful app or extension which can cause problems, it removes them from your computer.
|
||||
# Anything that interferes with a user's browsing experience may be removed by the tool.
|
||||
# Its disadvantages, high CPU load or privacy implications, may be reason enough to block it from running. This script will disable the software_reporter_tool.exe in a more cleaner way using Image File Execution Options Debugger value.
|
||||
# Setting this value to an executable designed to kill processes disables it. Chrome won't re-enable it with almost each update. Next to this, it will also be disabled per default in Registry.
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Google\Chrome" -Name ChromeCleanupEnabled -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Google\Chrome" -Name ChromeCleanupReportingEnabled -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Google\Chrome" -Name MetricsReportingEnabled -Type String -Value 0 -Force
|
||||
# This will disable the software_reporter_tool.exe in a more cleaner way using Image File Execution Options Debugger value.
|
||||
# Setting this value to an executable designed to kill processes disables it. Chrome won't re-enable it with almost each update.
|
||||
If (!(Test-Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\software_reporter_tool.exe")) {
|
||||
New-Item -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\software_reporter_tool.exe" -Force | Out-Null
|
||||
Write-Output "Google Chrome Software Reporter Tool has been successfully blocked."
|
||||
}
|
||||
Set-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\software_reporter_tool.exe" -Name "Debugger" -Type String -Value %windir%\System32\taskkill.exe -Force
|
||||
|
||||
###- Disable Mozilla Firefox telemetry
|
||||
# Firefox 75 comes with a new telemetry agent that sends information about your operating system and your default browser to Firefox every day.
|
||||
# The information collected is sent as a background telemetry ping every 24 hours to Mozilla.
|
||||
# Mozilla has introduced a Windows group policy that prevents the default-browser-agent.exe executable from sending your default browser info.
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Mozilla\Firefox" -Name DisableTelemetry -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Mozilla\Firefox" -Name DisableDefaultBrowserAgent -Type DWord -Value 1 -Force
|
||||
|
||||
###- Disable CCleaner Monitoring
|
||||
# Since Avast acquired Piriform, the popular system cleaning software CCleaner has become bloated with malware, bundled PUPs(potentially unwanted programs), and an alarming amount of pop-up ads.
|
||||
# If you're highly dependent on CCleaner you can disable with this script the CCleaner Active Monitoring ("Active Monitoring" feature has been renamed with v5.46 to "Smart Cleaning"),
|
||||
# automatic Update check and download function, trial offer notifications, the new integrated Software Updater and the privacy option to "Help Improve CCleaner by sending anonymous usage data".
|
||||
Stop-Process -name CCleaner*
|
||||
New-ItemProperty -Path "HKCU:\Software\Piriform\CCleaner" -Name Monitoring -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Piriform\CCleaner" -Name HelpImproveCCleaner -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Piriform\CCleaner" -Name SystemMonitoring -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Piriform\CCleaner" -Name UpdateAuto -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Piriform\CCleaner" -Name UpdateCheck -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Piriform\CCleaner" -Name CheckTrialOffer -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\Software\Piriform\CCleaner" -Name (Cfg)GetIpmForTrial -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\Software\Piriform\CCleaner" -Name (Cfg)SoftwareUpdater -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\Software\Piriform\CCleaner" -Name (Cfg)SoftwareUpdaterIpm -Type String -Value 0 -Force
|
||||
Get-ScheduledTask -TaskName "CCleaner Update" | Disable-ScheduledTask
|
||||
|
||||
###- Disable Dropbox Update service
|
||||
# This will disable Dropbox auto update service
|
||||
Get-ScheduledTask -TaskName "DropboxUpdateTaskMachineCore" | Disable-ScheduledTask
|
||||
Get-ScheduledTask -TaskName "DropboxUpdateTaskMachineUA" | Disable-ScheduledTask
|
||||
|
||||
###- Disable Google Update service
|
||||
# This will disable Google update service
|
||||
Get-ScheduledTask -TaskName "GoogleUpdateTaskMachineCore" | Disable-ScheduledTask
|
||||
Get-ScheduledTask -TaskName "GoogleUpdateTaskMachineUA" | Disable-ScheduledTask
|
||||
|
||||
###- Disable Media Player telemetry
|
||||
# This will disable Media Player telemetry
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\MediaPlayer\Preferences" -Name UsageTracking -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Policies\Microsoft\WindowsMediaPlayer" -Name PreventCDDVDMetadataRetrieval -Type String -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Policies\Microsoft\WindowsMediaPlayer" -Name PreventMusicFileMetadataRetrieval -Type String -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Policies\Microsoft\WindowsMediaPlayer" -Name PreventRadioPresetsRetrieval -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\WMDRM" -Name DisableOnline -Type String -Value 1 -Force
|
||||
Set-Service WMPNetworkSvc -StartupType Disabled
|
||||
|
||||
###- Disable Microsoft Office telemetry
|
||||
# This will disable Microsoft Office telemetry (supports Microsoft Office 2013 and 2016)
|
||||
Get-ScheduledTask -TaskName "OfficeTelemetryAgentFallBack2016" | Disable-ScheduledTask
|
||||
Get-ScheduledTask -TaskName "OfficeTelemetryAgentLogOn2016" | Disable-ScheduledTask
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Policies\Microsoft\Office\15.0\osm" -Name Enablelogging -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Policies\Microsoft\Office\15.0\osm" -Name EnableUpload -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Policies\Microsoft\Office\16.0\osm" -Name Enablelogging -Type String -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Policies\Microsoft\Office\16.0\osm" -Name EnableUpload -Type String -Value 0 -Force
|
68
scripts/templateBasicPrivacy (Undo).ps1
vendored
Normal file
68
scripts/templateBasicPrivacy (Undo).ps1
vendored
Normal file
|
@ -0,0 +1,68 @@
|
|||
### Info: This script will revert all changes made with the template "basicPrivacyTemplate" ###
|
||||
###- Enable telemetry in Windows 10
|
||||
New-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\DataCollection" -Name AllowTelemetry -Type DWord -Value 3 -Force
|
||||
New-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\DataCollection" -Name MaxTelemetryAllowed -Type DWord -Value 3 -Force
|
||||
# Start and Enable Diagnostic Tracking Service
|
||||
New-ItemProperty -Path "HKLM:\SYSTEM\ControlSet001\Services\DiagTrack" -Name "Start" -Type DWord -Value 2 -Force
|
||||
Start-Service -Name DiagTrack
|
||||
Set-Service -Name DiagTrack -StartupType Auto
|
||||
# Start and Enable dmwappushservice Service
|
||||
New-ItemProperty -Path "HKLM:\SYSTEM\ControlSet001\Services\dmwappushsvc" -Name "Start" -Type DWord -Value 2 -Force
|
||||
Start-Service -Name dmwappushservice
|
||||
Set-Service -Name dmwappushservice -StartupType Auto
|
||||
|
||||
###- Enable suggestions and automatic Installation of apps
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "ContentDeliveryAllowed" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "OemPreInstalledAppsEnabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "PreInstalledAppsEnabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "reInstalledAppsEverEnabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SilentInstalledAppsEnabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SubscribedContent-338387Enabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SubscribedContent-338388Enabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "ubscribedContent-338389Enabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SubscribedContent-353698Enabled" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SystemPaneSuggestionsEnabled" -Type DWord -Value 1 -Force
|
||||
Remove-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent" -Name "DisableWindowsConsumerFeatures" -ErrorAction SilentlyContinue
|
||||
|
||||
###- Enable Bing in Windows Search
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" -Name "CortanaConsent" -Type DWord -Value 1
|
||||
Remove-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" -Name "BingSearchEnabled" -ErrorAction SilentlyContinue
|
||||
|
||||
###- Enable Location tracking
|
||||
If (!(Test-Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location")) {
|
||||
New-Item -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location" -Force | Out-Null
|
||||
}
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location" -Name "Value" -Type String -Value "Allow"
|
||||
|
||||
###- Turn on Advertising ID for Relevant Ads
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo" -Name "Enabled" -Type DWord -Value 1 -Force
|
||||
|
||||
###- Turn on help Microsoft improve typing and writing
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\InputPersonalization" -Name "AllowInputPersonalization" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\InputPersonalization" -Name "RestrictImplicitInkCollection" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\InputPersonalization" -Name "RestrictImplicitTextCollection" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\HandwritingErrorReports" -Name "PreventHandwritingErrorReports" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\TabletPC" -Name "PreventHandwritingDataSharing" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Show feedback notifications
|
||||
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Siuf\Rules" -Name "PeriodInNanoSeconds"
|
||||
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Siuf\Rules" -Name "NumberOfSIUFInPeriod"
|
||||
|
||||
###- Enable Clipboard history
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Clipboard" -Name "EnableClipboardHistory" -Type DWord -Value 1 -Force
|
||||
|
||||
###- Enable Timeline history
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\System" -Name "EnableActivityFeed" -Type DWord -Value 1 -Force
|
||||
|
||||
###- Enable off Wi-Fi Sense
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\WcmSvc\wifinetworkmanager\config" -Name "AutoConnectAllowedOEM" -Type DWord -Value 1 -Force
|
||||
|
||||
###- Enable Customer Experience Improvement Program
|
||||
Get-ScheduledTask -TaskPath "\Microsoft\Windows\Customer Experience Improvement Program\" | Enable-ScheduledTask
|
||||
|
||||
###- Enable Windows Error Reporting
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Type DWord -Value 0 -Force
|
||||
Get-ScheduledTask -TaskName "QueueReporting" | Enable-ScheduledTask
|
||||
|
||||
###- Allow using diagnostic data
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Privacy" -Name "TailoredExperiencesWithDiagnosticDataEnabled" -Type DWord -Value 1 -Force
|
94
scripts/templateBasicPrivacy.ps1
vendored
Normal file
94
scripts/templateBasicPrivacy.ps1
vendored
Normal file
|
@ -0,0 +1,94 @@
|
|||
### Info: Run this template to apply the following policies at once. You can run each policy also individually by selecting it from the list below. ###
|
||||
###- Disable telemetry in Windows 10
|
||||
# As you use Windows 10, Microsoft will collect usage information. All its options are available in Settings -> Privacy - Feedback and Diagnostics. There you can set the options "Diagnostic and usage data" to Basic, Enhanced and Full.
|
||||
# This will set diagnostic data to Basic, which is the lowest level available for all consumer versions of Windows 10
|
||||
# NOTE: Diagnostic Data must be set to Full to get preview builds from Windows-Insider-Program! Just set the value of the AllowTelemetry key to "3" and run the script. All other changes remain unaffected.
|
||||
New-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\DataCollection" -Name "AllowTelemetry" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\DataCollection" -Name "MaxTelemetryAllowed" -Type DWord -Value 1 -Force
|
||||
# Stop and Disable Diagnostic Tracking Service
|
||||
New-ItemProperty -Path "HKLM:\SYSTEM\ControlSet001\Services\DiagTrack" -Name "Start" -Type DWord -Value 4 -Force
|
||||
Stop-Service -Name DiagTrack
|
||||
Set-Service -Name DiagTrack -StartupType Disabled
|
||||
# Stop and Disable dmwappushservice Service
|
||||
New-ItemProperty -Path "HKLM:\SYSTEM\ControlSet001\Services\dmwappushsvc" -Name "Start" -Type DWord -Value 4 -Force
|
||||
Stop-Service -Name dmwappushservice
|
||||
Set-Service -Name dmwappushservice -StartupType Disabled
|
||||
|
||||
###- Block suggestions and automatic Installation of apps
|
||||
# Microsoft flushes various apps into the system without being asked, especially games such as Candy Crush Saga. Users have to uninstall these manually if they don't want them on their computer.
|
||||
# To prevent these downloads from starting in the first place, a small intervention in the registry helps. Suggested apps pinned to Start are basically just advertising. This script will also disable suggested apps (ex: Candy Crush Soda Saga) for all accounts.
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "ContentDeliveryAllowed" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "OemPreInstalledAppsEnabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "PreInstalledAppsEnabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "reInstalledAppsEverEnabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SilentInstalledAppsEnabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SubscribedContent-338387Enabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SubscribedContent-338388Enabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "ubscribedContent-338389Enabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SubscribedContent-353698Enabled" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" -Name "SystemPaneSuggestionsEnabled" -Type DWord -Value 0 -Force
|
||||
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent")) {
|
||||
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent" -Force | Out-Null}
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\CloudContent" -Name "DisableWindowsConsumerFeatures" -Type DWord -Value 1 -Force
|
||||
|
||||
###- Disable Bing in Windows Search
|
||||
# Like Google, Bing is a search engine that needs your data to improve its search results. Windows 10, by default, sends everything you search for in the Start Menu to their servers to give you results from Bing search.
|
||||
# These searches are then uploaded to Microsoft's Privacy Dashboard.
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" -Name "CortanaConsent" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" -Name "BingSearchEnabled" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Disable Location tracking
|
||||
# When Location Tracking is turned on, Windows and its apps are allowed to detect the current location of your computer or device.
|
||||
# This can be used to pinpoint your exact location, e.g. Map traces the location of PC and helps you in exploring nearby restaurants.
|
||||
If (!(Test-Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location")) {
|
||||
New-Item -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location" -Force | Out-Null
|
||||
}
|
||||
New-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location" -Name "Value" -Type String -Value "Deny" -Force
|
||||
|
||||
###- Turn off Advertising ID for Relevant Ads
|
||||
# Windows 10 comes integrated with advertising. Microsoft assigns a unique identificator to track your activity in the Microsoft Store and on UWP apps to target you with relevant ads.
|
||||
# If someone is giving you personalized ads, it means they are tracking your data. Turn off the advertising feature from Windows 10 with this script to stay secure.
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo" -Name "Enabled" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Turn off help Microsoft improve typing and writing
|
||||
# When the Getting to know you privacy setting is turned on for inking & typing personalization in Windows 10, you can use your typing history and handwriting patterns to create a local user dictionary for you that is used to make better typing suggestions and improve handwriting recognition for each of the languages you use.
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\InputPersonalization" -Name "AllowInputPersonalization" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\InputPersonalization" -Name "RestrictImplicitInkCollection" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\InputPersonalization" -Name "RestrictImplicitTextCollection" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\HandwritingErrorReports" -Name "PreventHandwritingErrorReports" -Type DWord -Value 1 -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\TabletPC" -Name "PreventHandwritingDataSharing" -Type DWord -Value 1 -Force
|
||||
|
||||
###- Do not show feedback notifications
|
||||
# Windows 10 doesn’t just automatically collect information about your computer usage. It does do that, but it may also pop up from time to time and ask for feedback.
|
||||
# This information is used to improve Windows 10 - in theory. As of Windows 10’s “November Update,” the Windows Feedback application is installed by default on all Windows 10 PCs.
|
||||
# If you are running Windows 10 in a corporate setting, you should likely disable the Windows Feedback prompts that appear every few weeks.
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Siuf\Rules" -Name "PeriodInNanoSeconds" -Type DWord -Value 0 -Force
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Siuf\Rules" -Name "NumberOfSIUFInPeriod" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Disable Clipboard history
|
||||
# With Windows 10 build 17666 or later, Microsoft has allowed cloud synchronization of clipboard. It is a special feature to sync clipboard content across all your devices connected with your Microsoft Account.
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Clipboard" -Name "EnableClipboardHistory" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Disable Timeline history
|
||||
# Microsoft made Timeline available to the public with Windows 10 build 17063. It collects a history of activities you've performed, including files you've opened and web pages you've viewed in Edge.
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\System" -Name "EnableActivityFeed" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Disable off Wi-Fi Sense
|
||||
# Wi-Fi Sense is a feature in Windows 10 that allows you to connect to your friends shared Wi-Fi connections.
|
||||
# That is, you and your friends may opt to share your or their Wi-Fi connections. If your computer is logged into a Microsoft account, by default it will share your Wi-Fi password with your Skype, Outlook and Facebook friends, which means your Wi-Fi password will be sent to Microsoft.
|
||||
# You should at least stop your PC from sending your Wi-Fi password.
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\WcmSvc\wifinetworkmanager\config" -Name "AutoConnectAllowedOEM" -Type DWord -Value 0 -Force
|
||||
|
||||
###- Disable Customer Experience Improvement Program
|
||||
Get-ScheduledTask -TaskPath "\Microsoft\Windows\Customer Experience Improvement Program\" | Disable-ScheduledTask
|
||||
|
||||
###- Disable Windows Error Reporting
|
||||
# The error reporting feature in Windows is what produces those alerts after certain program or operating system errors, prompting you to send the information about the problem to Microsoft.
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\Windows Error Reporting" -Name "Disabled" -Type DWord -Value 1 -Force
|
||||
Get-ScheduledTask -TaskName "QueueReporting" | Disable-ScheduledTask
|
||||
|
||||
###- Prevent using diagnostic data ###
|
||||
#Starting with Windows 10 build 15019, a new privacy setting to "let Microsoft provide more tailored experiences with relevant tips and recommendations by using your diagnostic data" has been added.
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Privacy" -Name "TailoredExperiencesWithDiagnosticDataEnabled" -Type DWord -Value 0 -Force
|
||||
|
||||
### Info: The execution of this template is recommended in case when reinstalling Windows or after major updates.
|
203
scripts/templateFirewallTelemetry.ps1
vendored
Normal file
203
scripts/templateFirewallTelemetry.ps1
vendored
Normal file
|
@ -0,0 +1,203 @@
|
|||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
# Rules are provided by crazy-max/WindowsSpyBlocker
|
||||
# https://github.com/crazy-max/WindowsSpyBlocker/blob/master/data/firewall/spy.txt
|
||||
# Last updated on 23 Jan, 2020
|
||||
# Template was adapted for SharpApp https://github.com/mirinsoft/sharpapp
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
### Block Microsoft Telemetry IPs via Windows Firewall ###
|
||||
### This script will not block Windows updates and third party applications from Microsoft like OneDrive, Skype, Live etc. ###
|
||||
### To do so, you can get the "hardcoreFirewallTemplate" from the Marketplace ###
|
||||
Write-Output "Adding telemetry IPs to firewall"
|
||||
$ips = @(
|
||||
"13.68.31.193"
|
||||
"13.66.56.243"
|
||||
"13.68.82.8"
|
||||
"13.70.180.171"
|
||||
"13.73.26.107"
|
||||
"13.78.130.220"
|
||||
"13.78.232.226"
|
||||
"13.78.233.133"
|
||||
"13.88.28.53"
|
||||
"13.92.194.212"
|
||||
"20.44.86.43"
|
||||
"20.189.74.153"
|
||||
"23.99.49.121"
|
||||
"23.102.4.253"
|
||||
"23.102.21.4"
|
||||
"23.103.182.126"
|
||||
"40.68.222.212"
|
||||
"40.69.153.67"
|
||||
"40.70.184.83"
|
||||
"40.70.220.248"
|
||||
"40.70.221.249"
|
||||
"40.77.228.47"
|
||||
"40.77.228.87"
|
||||
"40.77.228.92"
|
||||
"40.77.232.101"
|
||||
"40.79.85.125"
|
||||
"40.90.221.9"
|
||||
"40.115.3.210"
|
||||
"40.115.119.185"
|
||||
"40.119.211.203"
|
||||
"40.124.34.70"
|
||||
"51.140.40.236"
|
||||
"51.140.157.153"
|
||||
"51.143.111.7"
|
||||
"51.143.111.81"
|
||||
"52.114.6.46"
|
||||
"52.114.6.47"
|
||||
"52.114.7.36"
|
||||
"52.114.7.37"
|
||||
"52.114.7.38"
|
||||
"52.114.7.39"
|
||||
"52.114.32.5"
|
||||
"52.114.32.6"
|
||||
"52.114.32.7"
|
||||
"52.114.32.8"
|
||||
"52.114.32.24"
|
||||
"52.114.32.25"
|
||||
"52.114.36.1"
|
||||
"52.114.36.2"
|
||||
"52.114.36.3"
|
||||
"52.114.36.4"
|
||||
"52.114.74.43"
|
||||
"52.114.74.44"
|
||||
"52.114.74.45"
|
||||
"52.114.75.78"
|
||||
"52.114.75.79"
|
||||
"52.114.75.149"
|
||||
"52.114.75.150"
|
||||
"52.114.76.34"
|
||||
"52.114.76.35"
|
||||
"52.114.76.37"
|
||||
"52.114.77.33"
|
||||
"52.114.77.34"
|
||||
"52.114.77.137"
|
||||
"52.114.77.164"
|
||||
"52.114.88.19"
|
||||
"52.114.88.20"
|
||||
"52.114.88.21"
|
||||
"52.114.88.22"
|
||||
"52.114.88.28"
|
||||
"52.114.88.29"
|
||||
"52.114.128.7"
|
||||
"52.114.128.8"
|
||||
"52.114.128.9"
|
||||
"52.114.128.10"
|
||||
"52.114.128.43"
|
||||
"52.114.128.44"
|
||||
"52.114.128.58"
|
||||
"52.114.132.14"
|
||||
"52.114.132.20"
|
||||
"52.114.132.21"
|
||||
"52.114.132.22"
|
||||
"52.114.132.23"
|
||||
"52.114.132.73"
|
||||
"52.114.132.74"
|
||||
"52.114.158.50"
|
||||
"52.114.158.51"
|
||||
"52.114.158.52"
|
||||
"52.114.158.53"
|
||||
"52.114.158.91"
|
||||
"52.114.158.92"
|
||||
"52.114.158.102"
|
||||
"52.138.204.217"
|
||||
"52.138.216.83"
|
||||
"52.155.172.105"
|
||||
"52.157.234.37"
|
||||
"52.158.208.111"
|
||||
"52.164.241.205"
|
||||
"52.169.189.83"
|
||||
"52.170.83.19"
|
||||
"52.174.22.246"
|
||||
"52.178.147.240"
|
||||
"52.178.151.212"
|
||||
"52.178.178.16"
|
||||
"52.178.223.23"
|
||||
"52.183.114.173"
|
||||
"52.229.39.152"
|
||||
"52.230.85.180"
|
||||
"52.236.42.239"
|
||||
"52.236.43.202"
|
||||
"65.52.100.7"
|
||||
"65.52.100.9"
|
||||
"65.52.100.11"
|
||||
"65.52.100.91"
|
||||
"65.52.100.92"
|
||||
"65.52.100.93"
|
||||
"65.52.100.94"
|
||||
"65.52.161.64"
|
||||
"65.55.29.238"
|
||||
"65.55.44.51"
|
||||
"65.55.44.54"
|
||||
"65.55.44.108"
|
||||
"65.55.44.109"
|
||||
"65.55.83.120"
|
||||
"65.55.113.11"
|
||||
"65.55.113.12"
|
||||
"65.55.113.13"
|
||||
"65.55.176.90"
|
||||
"65.55.252.43"
|
||||
"65.55.252.63"
|
||||
"65.55.252.70"
|
||||
"65.55.252.71"
|
||||
"65.55.252.72"
|
||||
"65.55.252.93"
|
||||
"65.55.252.190"
|
||||
"65.55.252.202"
|
||||
"66.119.147.131"
|
||||
"104.41.207.73"
|
||||
"104.43.137.66"
|
||||
"104.43.139.21"
|
||||
"104.43.140.223"
|
||||
"104.43.228.53"
|
||||
"104.43.228.202"
|
||||
"104.43.237.169"
|
||||
"104.45.11.195"
|
||||
"104.45.214.112"
|
||||
"104.46.1.211"
|
||||
"104.46.38.64"
|
||||
"104.210.4.77"
|
||||
"104.210.40.87"
|
||||
"104.210.212.243"
|
||||
"104.214.35.244"
|
||||
"104.214.78.152"
|
||||
"131.253.6.87"
|
||||
"131.253.6.103"
|
||||
"131.253.40.37"
|
||||
"134.170.30.202"
|
||||
"134.170.30.203"
|
||||
"134.170.30.204"
|
||||
"134.170.30.221"
|
||||
"134.170.52.151"
|
||||
"134.170.235.16"
|
||||
"157.56.74.250"
|
||||
"157.56.91.77"
|
||||
"157.56.106.184"
|
||||
"157.56.106.185"
|
||||
"157.56.106.189"
|
||||
"157.56.113.217"
|
||||
"157.56.121.89"
|
||||
"157.56.124.87"
|
||||
"157.56.149.250"
|
||||
"157.56.194.72"
|
||||
"157.56.194.73"
|
||||
"157.56.194.74"
|
||||
"168.61.24.141"
|
||||
"168.61.146.25"
|
||||
"168.61.149.17"
|
||||
"168.61.172.71"
|
||||
"168.62.187.13"
|
||||
"168.63.100.61"
|
||||
"168.63.108.233"
|
||||
"191.236.155.80"
|
||||
"191.237.218.239"
|
||||
"191.239.50.18"
|
||||
"191.239.50.77"
|
||||
"191.239.52.100"
|
||||
"191.239.54.52"
|
||||
"207.68.166.254"
|
||||
)
|
||||
Remove-NetFirewallRule -DisplayName "Spydish Microsoft Telemetry Block" -ErrorAction SilentlyContinue
|
||||
New-NetFirewallRule -DisplayName "Spydish Microsoft Telemetry Block" -Direction Outbound `
|
||||
-Action Block -RemoteAddress ([string[]]$ips)
|
81
scripts/templateSettingsPrivacy.ps1
vendored
Normal file
81
scripts/templateSettingsPrivacy.ps1
vendored
Normal file
|
@ -0,0 +1,81 @@
|
|||
### This template will turn off all options under Windows 10 Settings > Privacy page ###
|
||||
# Windows 10 provides a wealth of data access to make apps useful and valuable to you.
|
||||
# These capabilities, which are security constructs that gate access to personal data, include things like Calendar, Contacts, Call History, and more.
|
||||
# Each capability has its own privacy settings page so that you can control it and what apps and services can use that capability.
|
||||
|
||||
###- Disable app access to account info
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\userAccountInformation" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to calendar
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\appointments" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to call history
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\phoneCallHistory" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to call
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\phoneCall" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to contacts
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\contacts" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to diagnostic information
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\appDiagnostics" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to documents
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\documentsLibrary" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to email
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\email" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to file system
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\broadFileSystemAccess" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to location
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to messaging
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\chat" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to microphone
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\microphone" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to motion
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\activity" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to notifications
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\userNotificationListener" -Type String -Name Value -Value Deny -Force
|
||||
|
||||
###- Disable app access to other devices
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\bluetooth" -Name Value -Type String -Value Deny -Force
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\bluetoothSync" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to pictures
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\picturesLibrary" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to radios
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\radios" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to tasks
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\userDataTasks" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to videos
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\videosLibrary" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable app access to webcam
|
||||
New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\webcam" -Name Value -Type String -Value Deny -Force
|
||||
|
||||
###- Disable apps from running in background
|
||||
# Disabling this function means, Windows 10 apps have no more permission to run in the background so they can't update their live tiles, fetch new data, and receive notifications.
|
||||
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\BackgroundAccessApplications" -Name GlobalUserDisabled -Type DWord -Value 1 -Force
|
||||
|
||||
###- Disable tracking of app starts
|
||||
# Windows can personalize your Start menu based on the apps that you launch.
|
||||
# This allows you to quickly have access to your list of Most used apps both in the Start menu and when you search your device.
|
||||
New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" -Name Start_TrackProgs -Type DWord -Value 0 -Force
|
||||
|
||||
###- Open privacy settings
|
||||
$Result = [System.Windows.Forms.MessageBox]::Show("Script has been successfully executed.`r`n`r`nWould you like to open the Settings > Privcay page to check the results?","Spydish",4)
|
||||
If ($Result -eq "Yes")
|
||||
{
|
||||
Start-Process "ms-settings:privacy-general"
|
||||
}
|
63
scripts/unpin-startmenu-tiles.ps1
vendored
Normal file
63
scripts/unpin-startmenu-tiles.ps1
vendored
Normal file
|
@ -0,0 +1,63 @@
|
|||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
# Script is provided by an user from superuser.com
|
||||
# Compatibility: Tested on Windows 10, version 1903, 1909, 2004
|
||||
# Script was adapted for Spydish https://github.com/mirinsoft/spydish
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
### This script will clean Windows 10s start menu from all the default pinned apps (live tiles) that you are using. ###
|
||||
### It will remove all titles for the current logged user, plus it will optionally do the same for all new users accounts created on the computer.
|
||||
|
||||
$START_MENU_LAYOUT = @"
|
||||
<LayoutModificationTemplate xmlns:defaultlayout="http://schemas.microsoft.com/Start/2014/FullDefaultLayout" xmlns:start="http://schemas.microsoft.com/Start/2014/StartLayout" Version="1" xmlns:taskbar="http://schemas.microsoft.com/Start/2014/TaskbarLayout" xmlns="http://schemas.microsoft.com/Start/2014/LayoutModification">
|
||||
<LayoutOptions StartTileGroupCellWidth="6" />
|
||||
<DefaultLayoutOverride>
|
||||
<StartLayoutCollection>
|
||||
<defaultlayout:StartLayout GroupCellWidth="6" />
|
||||
</StartLayoutCollection>
|
||||
</DefaultLayoutOverride>
|
||||
</LayoutModificationTemplate>
|
||||
"@
|
||||
|
||||
$layoutFile="C:\Windows\StartMenuLayout.xml"
|
||||
|
||||
#Delete layout file if it already exists
|
||||
If(Test-Path $layoutFile)
|
||||
{
|
||||
Remove-Item $layoutFile
|
||||
}
|
||||
|
||||
#Creates the blank layout file
|
||||
$START_MENU_LAYOUT | Out-File $layoutFile -Encoding ASCII
|
||||
|
||||
$regAliases = @("HKLM", "HKCU")
|
||||
|
||||
#Assign the start layout and force it to apply with "LockedStartLayout" at both the machine and user level
|
||||
foreach ($regAlias in $regAliases){
|
||||
$basePath = $regAlias + ":\SOFTWARE\Policies\Microsoft\Windows"
|
||||
$keyPath = $basePath + "\Explorer"
|
||||
IF(!(Test-Path -Path $keyPath)) {
|
||||
New-Item -Path $basePath -Name "Explorer"
|
||||
}
|
||||
Set-ItemProperty -Path $keyPath -Name "LockedStartLayout" -Value 1
|
||||
Set-ItemProperty -Path $keyPath -Name "StartLayoutFile" -Value $layoutFile
|
||||
}
|
||||
|
||||
#Restart Explorer, open the start menu (necessary to load the new layout), and give it a few seconds to process
|
||||
Stop-Process -name explorer
|
||||
Start-Sleep -s 5
|
||||
$wshell = New-Object -ComObject wscript.shell; $wshell.SendKeys('^{ESCAPE}')
|
||||
Start-Sleep -s 5
|
||||
|
||||
#Enable the ability to pin items again by disabling "LockedStartLayout"
|
||||
foreach ($regAlias in $regAliases){
|
||||
$basePath = $regAlias + ":\SOFTWARE\Policies\Microsoft\Windows"
|
||||
$keyPath = $basePath + "\Explorer"
|
||||
Set-ItemProperty -Path $keyPath -Name "LockedStartLayout" -Value 0
|
||||
}
|
||||
|
||||
#Restart Explorer and delete the layout file
|
||||
Stop-Process -name explorer
|
||||
|
||||
# Uncomment the next line to make clean start menu default for all new users
|
||||
#Import-StartLayout -LayoutPath $layoutFile -MountPath $env:SystemDrive\
|
||||
|
||||
Remove-Item $layoutFile
|
Loading…
Add table
Reference in a new issue