2626 For Immy purposes, add this script as a Combined Task with Script Parameters enabled.
2727 Returns [bool] during test phase. In set phase writes summary output (Absent) or relies on helper output (Present).
2828 Validates inputs (color hex, interval range). All registry writes are HKLM so run in System context.
29+
30+ Script courtesy of https://github.com/MWGMorningwood/
31+
2932#>
3033[CmdletBinding (SupportsShouldProcess = $false )]
3134param (
@@ -106,11 +109,17 @@ Enable Debug Logging. Maps to "Enable Debug Logging" in Activity Log settings.
106109| `0` | Disabled |
107110| `1` | Enabled (default) |
108111'@ )][ValidateSet (0 , 1 )][int ]$EnableDebugLogging = 1 ,
112+ [Parameter (HelpMessage = @'
113+ A list of URLs that will completely bypass blocking. Entering **ANY** will decrease security on that website significantly.
114+ '@ )][string []]$urlAllowlist ,
109115
110116 [Parameter (HelpMessage = @'
111117Branding: Company Name shown in extension UI.
112118'@ )][string ]$CompanyName = ' CyberDrain' ,
113119 [Parameter (HelpMessage = @'
120+ Branding: Company URL shown in extension UI.
121+ '@ )][string ]$CompanyUrl = ' https://cyberdrain.com/' ,
122+ [Parameter (HelpMessage = @'
114123Branding: Product Name shown in extension UI.
115124'@ )][string ]$ProductName = ' Check - Phishing Protection' ,
116125 [Parameter (HelpMessage = @'
@@ -161,7 +170,9 @@ function Get-DesiredItem {
161170 [string ]$CustomRulesUrl ,
162171 [int ]$UpdateInterval ,
163172 [int ]$EnableDebugLogging ,
173+ [string []]$urlAllowlist ,
164174 [string ]$CompanyName ,
175+ [string ]$CompanyUrl ,
165176 [string ]$ProductName ,
166177 [string ]$SupportEmail ,
167178 [string ]$PrimaryColor ,
@@ -186,9 +197,11 @@ function Get-DesiredItem {
186197 @ { Path = $b.ManagedKey ; Name = ' customRulesUrl' ; Type = ' String' ; Value = $CustomRulesUrl },
187198 @ { Path = $b.ManagedKey ; Name = ' updateInterval' ; Type = ' DWord' ; Value = $UpdateInterval },
188199 @ { Path = $b.ManagedKey ; Name = ' enableDebugLogging' ; Type = ' DWord' ; Value = $EnableDebugLogging }
200+ @ { Path = $b.ManagedKey ; Name = ' urlAllowlist' ; Type = ' MultiString' ; Value = $urlAllowlist }
189201 )
190202 $brandingItems = @ (
191203 @ { Path = $brandingKey ; Name = ' companyName' ; Type = ' String' ; Value = $CompanyName },
204+ @ { Path = $brandingKey ; Name = ' companyURL' ; Type = ' String' ; Value = $CompanyUrl },
192205 @ { Path = $brandingKey ; Name = ' productName' ; Type = ' String' ; Value = $ProductName },
193206 @ { Path = $brandingKey ; Name = ' supportEmail' ; Type = ' String' ; Value = $SupportEmail },
194207 @ { Path = $brandingKey ; Name = ' primaryColor' ; Type = ' String' ; Value = $PrimaryColor },
@@ -237,7 +250,9 @@ $desiredItems = Get-DesiredItem `
237250 - CustomRulesUrl $CustomRulesUrl `
238251 - UpdateInterval $UpdateInterval `
239252 - EnableDebugLogging $EnableDebugLogging `
253+ - urlAllowlist $urlAllowlist `
240254 - CompanyName $CompanyName `
255+ - CompanyUrl $CompanyUrl `
241256 - ProductName $ProductName `
242257 - SupportEmail $SupportEmail `
243258 - PrimaryColor $PrimaryColor `
0 commit comments