rmm-scripts/installUblock.ps1

17 lines
703 B
PowerShell

#Zebra - 2/22/2024
#Force installs uBlock Origin to Edge and Chrome.
#Delete regkeys to remove
# Defining the web store extension IDs
$chromeKey = "cjpalhdlnbpafiamejdnhcphjbkeiagm"
$edgeKey = "odfafepnkmbhccpbejgmiehpchacaeak"
# Defining the paths for each regkey
$chromePath = "HKLM:\SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist"
$edgePath = "HKLM:\SOFTWARE\Policies\Microsoft\Edge\ExtensionInstallForcelist"
# Add the keys to the registry
New-ItemProperty -Path $chromePath -Name "1" -Value $chromeKey -PropertyType "String" -Force
New-ItemProperty -Path $edgePath -Name "1" -Value $edgeKey -PropertyType "String" -Force
Write-Host "uBlock installed on Chrome and Edge successfully."