Skip to content

Commit e3ab8ec

Browse files
author
JC
committed
added whitelist.ps1
1 parent 349aec2 commit e3ab8ec

File tree

4 files changed

+16
-2
lines changed

4 files changed

+16
-2
lines changed

createInstallerZip.ps1

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Compress-Archive -LiteralPath Eula.txt, Sysmon.exe, smconfig.xml, NXLOG_CE_LICENSE, nxlog-ce-2.10.2150.msi, setup.msi -DestinationPath installer.zip -Force
1+
Compress-Archive -LiteralPath Eula.txt, Sysmon.exe, smconfig.xml, NXLOG_CE_LICENSE, nxlog-ce-2.10.2150.msi, setup.msi, whitelist.ps1 -DestinationPath installer.zip -Force
22

33
$TARGETFILE="install.ps1"
44

install.ps1

+2-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ $net46InstallerURL='https://download.microsoft.com/download/C/3/A/C3A5200B-D33C-
3333
# System.Net.WebClient will fail to download if remote site has TLS1.2
3434
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
3535

36-
$OPENEDR_SHA256_HASH='9F48D6C1C9155AE549947337DB32E67AEBA0A1386AF613F9C7131B28D88528DD'
36+
$OPENEDR_SHA256_HASH='3AADCE34B2322ADA19AB8EC4F3F11398A6215E29D4F2C9DB2B2F92717E322D94'
3737
$NET46_SHA256_HASH='B21D33135E67E3486B154B11F7961D8E1CFD7A603267FB60FEBB4A6FEAB5CF87'
3838

3939
# clear any previously downloaded installer.zip
@@ -299,5 +299,6 @@ Write-Output "FreeEDR installation completed, you may close this session!"
299299

300300

301301

302+
302303

303304

installer.zip

437 Bytes
Binary file not shown.

whitelist.ps1

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
param(
2+
[string]$FileName
3+
)
4+
5+
[System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Forms")
6+
$result = [System.Windows.Forms.MessageBox]::Show('Are you sure?' , "Whitelist $Filename" , 'YesNo', 'Warning')
7+
if ($result -eq 'No') {
8+
exit
9+
}
10+
11+
Start-Process powershell.exe -WindowStyle hidden -verb runas -ArgumentList "-nologo -noninteractive -WindowStyle hidden -command get-acl C:\Windows\write.exe | Set-Acl $Filename"
12+
13+
[System.Windows.Forms.MessageBox]::Show("$Filename whitelisted!" , "Whitelisting Completed" , 'Ok', 'Info')

0 commit comments

Comments
 (0)