Skip to content

Commit

Permalink
version files update
Browse files Browse the repository at this point in the history
  • Loading branch information
HotCakeX committed Oct 17, 2023
1 parent 3cd3d9f commit 11ae849
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Harden-Windows-Security Module/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.1.8
0.1.9
29 changes: 17 additions & 12 deletions Harden-Windows-Security.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -277,10 +277,15 @@ function Compare-SecureString {
#endregion functions

if (Test-IsAdmin) {

# Get the current configurations and preferences of the Microsoft Defender
$MDAVConfigCurrent = Get-MpComputerStatus
$MDAVPreferencesCurrent = Get-MpPreference

# backup the current allowed apps list in Controlled folder access in order to restore them at the end of the script
# doing this so that when we Add and then Remove PowerShell executables in Controlled folder access exclusions
# no user customization will be affected
[string[]]$CFAAllowedAppsBackup = (Get-MpPreference).ControlledFolderAccessAllowedApplications
[string[]]$CFAAllowedAppsBackup = $MDAVPreferencesCurrent.ControlledFolderAccessAllowedApplications

# Temporarily allow the currently running PowerShell executables to the Controlled Folder Access allowed apps
# so that the script can run without interruption. This change is reverted at the end.
Expand Down Expand Up @@ -360,9 +365,6 @@ try {
Write-Error 'TPM is not available or enabled, please go to your UEFI settings to enable it and then try again.'
break
}

# Get the current configuration of the Microsoft Defender
$MDAVConfigCurrent = Get-MpComputerStatus

if (-NOT ($MDAVConfigCurrent.AMServiceEnabled -eq $true)) {
Write-Error 'Microsoft Defender Anti Malware service is not enabled, please enable it and then try again.'
Expand Down Expand Up @@ -677,14 +679,17 @@ try {
}
}

# Set Microsoft Defender engine and platform update channel to beta - Devices in the Windows Insider Program are subscribed to this channel by default.
switch (Select-Option -SubCategory -Options 'Yes', 'No', 'Exit' -Message "`nSet Microsoft Defender engine and platform update channel to beta ?") {
'Yes' {
Set-MpPreference -EngineUpdatesChannel beta
Set-MpPreference -PlatformUpdatesChannel beta
} 'No' { break }
'Exit' { &$CleanUp }
}
# Only show this prompt if Engine and Platform update channels are not already set to Beta
if ( ($MDAVPreferencesCurrent.EngineUpdatesChannel -ne '2') -or ($MDAVPreferencesCurrent.PlatformUpdatesChannel -ne '2') ) {
# Set Microsoft Defender engine and platform update channel to beta - Devices in the Windows Insider Program are subscribed to this channel by default.
switch (Select-Option -SubCategory -Options 'Yes', 'No', 'Exit' -Message "`nSet Microsoft Defender engine and platform update channel to beta ?") {
'Yes' {
Set-MpPreference -EngineUpdatesChannel beta
Set-MpPreference -PlatformUpdatesChannel beta
} 'No' { break }
'Exit' { &$CleanUp }
}
}

} 'No' { break }
'Exit' { &$CleanUp }
Expand Down
2 changes: 1 addition & 1 deletion Version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2023.10.12
2023.10.17
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This module offers rigorous compliance verification and security assessment. It enables you to evaluate the conformity of your system based on the security standards and recommendations of this repository. The module employs various techniques such as Security Policy, PowerShell cmdlet and Registry keys to conduct the checks.

Compliance checking strictly follows the guidelines and security measures of this GitHub repository. Any minor deviation from them will result in a `$false` value for the corresponding check.
Compliance checking strictly follows the guidelines and security measures of this GitHub repository. Any minor deviation from them will result in a `false` value for the corresponding check.

<br>

Expand Down

0 comments on commit 11ae849

Please sign in to comment.