Skip to content

Commit b823d48

Browse files
authored
Merge pull request #37 from Harvester57/defender-sandboxing
Add Defender sandboxing policy
2 parents d945002 + d0a349d commit b823d48

File tree

5 files changed

+37
-23
lines changed

5 files changed

+37
-23
lines changed

AdditionalHardening.admx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!--
33
Author: Florian Stosse <florian.stosse@gmail.com>
4-
Version: 1.1
4+
Version: 1.1.1
55
Date: 2024-12-08
66
-->
77
<policyDefinitions xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" revision="1.0" schemaVersion="1.0" xmlns="http://schemas.microsoft.com/GroupPolicy/2006/07/PolicyDefinitions">

AdditionalSystemHardening.admx

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -137,16 +137,12 @@
137137
<enabledList defaultKey="Software\Microsoft\Cryptography\Wintrust\Config">
138138
<item valueName="EnableCertPaddingCheck">
139139
<value>
140-
<string>
141-
1
142-
</string>
140+
<string>1</string>
143141
</value>
144142
</item>
145143
<item key="Software\Wow6432Node\Microsoft\Cryptography\Wintrust\Config" valueName="EnableCertPaddingCheck">
146144
<value>
147-
<string>
148-
1
149-
</string>
145+
<string>1</string>
150146
</value>
151147
</item>
152148
</enabledList>
@@ -200,14 +196,10 @@
200196
<parentCategory ref="System" />
201197
<supportedOn ref="windows:SUPPORTED_Windows_6_3" />
202198
<enabledValue>
203-
<string>
204-
4
205-
</string>
199+
<string>4</string>
206200
</enabledValue>
207201
<disabledValue>
208-
<string>
209-
0
210-
</string>
202+
<string>0</string>
211203
</disabledValue>
212204
</policy>
213205
<policy name="LoadAppInit_DLLs" class="Machine" displayName="$(string.LoadAppInit_DLLs)" explainText="$(string.LoadAppInit_DLLs_Explain)" key="Software\Microsoft\Windows NT\CurrentVersion\Windows" valueName="LoadAppInit_DLLs">
@@ -339,9 +331,7 @@
339331
</enum>
340332
<boolean id="HyperVMitigations" key="SOFTWARE\Microsoft\Windows NT\CurrentVersion\Virtualization" valueName="MinVmVersionForCpuBasedMitigations">
341333
<trueValue>
342-
<string>
343-
1.0
344-
</string>
334+
<string>1.0</string>
345335
</trueValue>
346336
<falseValue>
347337
<delete />
@@ -412,9 +402,7 @@
412402
<enabledList defaultKey="SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon">
413403
<item valueName="CachedLogonsCount">
414404
<value>
415-
<string>
416-
2
417-
</string>
405+
<string>2</string>
418406
</value>
419407
</item>
420408
<item key="SYSTEM\CurrentControlSet\Control\Lsa" valueName="TokenLeakDetectDelaySecs">
@@ -531,5 +519,15 @@
531519
<decimal value="0" />
532520
</disabledValue>
533521
</policy>
522+
<policy name="DefenderSandboxing" class="Machine" displayName="$(string.DefenderSandboxing)" explainText="$(string.DefenderSandboxing_Explain)" key="SYSTEM\CurrentControlSet\Control\Session Manager\Environment" valueName="MP_FORCE_USE_SANDBOX">
523+
<parentCategory ref="System" />
524+
<supportedOn ref="windows:SUPPORTED_Windows_6_3" />
525+
<enabledValue>
526+
<string>1</string>
527+
</enabledValue>
528+
<disabledValue>
529+
<string>0</string>
530+
</disabledValue>
531+
</policy>
534532
</policies>
535533
</policyDefinitions>

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ All notable changes to this project will be documented in this file.
33

44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
55

6+
## [v1.1.1] - 2024-12-08
7+
### Added
8+
- New policy to enable or disable the Windows Defender sandbox
9+
### Fixed
10+
- Indentation value for REG_SZ-based policies
11+
612
## [v1.1] - 2024-12-08
713
### Changed
814
- Major refactoring of the codebase

en-US/AdditionalSystemHardening.adml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,11 +84,11 @@ Disabling this policy will explicitly disable the ASLR mechanism.</string>
8484
<string id="User32_Exception">Additional registry fix for CVE-2015-6161</string>
8585
<string id="User32_Exception_Explain">Enable this policy to change the registry value FEATURE_ALLOW_USER32_EXCEPTION_HANDLER_HARDENING to 1.
8686

87-
This modification is necessary to fully fix an ASLR bypass vulnerability (CVE-2015-6161). For more informations, refer to the MS15-124 security bulletin (https://docs.microsoft.com/en-us/security-updates/SecurityBulletins/2015/ms15-124).</string>
87+
This modification is necessary to fully fix an ASLR bypass vulnerability (CVE-2015-6161). For more information, refer to the MS15-124 security bulletin (https://docs.microsoft.com/en-us/security-updates/SecurityBulletins/2015/ms15-124).</string>
8888
<string id="Info_Disclosure">Additional registry fix for CVE-2017-8529</string>
8989
<string id="Info_Disclosure_Explain">Enable this policy to change the registry value FEATURE_ENABLE_PRINT_INFO_DISCLOSURE_FIX to 1.
9090

91-
This modification is necessary to fully fix an information disclosure vulnerability in Microsoft browsers (CVE-2017-8529). For more informations, refer to the related security update guide (https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2017-8529).</string>
91+
This modification is necessary to fully fix an information disclosure vulnerability in Microsoft browsers (CVE-2017-8529). For more information, refer to the related security update guide (https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2017-8529).</string>
9292
<string id="MSCacheV2_Iteration">Number of PBKDF2 iterations for cached logons credentials hashing</string>
9393
<string id="MSCacheV2_Iteration_Explain">For domains logons, if credentials caching is enabled, credentials are stored as MSCacheV2 hashes, dervided using the PBKDF2-SHA1 hashing algorithm.
9494

@@ -101,7 +101,7 @@ The recommended value depends on the target environment, the CPU power available
101101

102102
When the policy is enabled, the default value configured is 1954 (2 000 896 rounds). This is the recommended value (at the time of December 2022) for the PBKDF2-HMAC-SHA1 algorithm, considering the compute power of a RTX 4090 GPU in a offline bruteforce attack model.
103103

104-
More informations:
104+
More information:
105105
- https://tobtu.com/minimum-password-settings/
106106
- https://cheatsheetseries.owasp.org/cheatsheets/Password_Storage_Cheat_Sheet.html#pbkdf2</string>
107107
<string id="PSLockDownPolicy">Enable PowerShell Constrained Language Mode</string>
@@ -167,7 +167,7 @@ It is recommended to use the default behavior and let the Sudo command open a ne
167167

168168
Mandatory mode is a new functionnality introduced to prevent the Windows Downdate attack (and other related dowgrading attacks) by forcing the verification of the components of the Secure Kernel and the hypervisor at boot time. Consequently, enabling this functionnality can lead to boot failure (and a denial of service) in case of a modification of a core component of Secure Kernel, hypervisor or a related dependant module.
169169

170-
NOTE: if you already have Virtualization-Based Security enabled with UEFI Lock, this setting will not do anything, as the VBS configuration is already written and locked in a UEFI variable. This variable needs to be deleted using the bcdedit.exe tool before deploying the Mandatory flag and the UEFI Lock. Guidance and more informations about this procedure are available here:
170+
NOTE: if you already have Virtualization-Based Security enabled with UEFI Lock, this setting will not do anything, as the VBS configuration is already written and locked in a UEFI variable. This variable needs to be deleted using the bcdedit.exe tool before deploying the Mandatory flag and the UEFI Lock. Guidance and more information about this procedure are available here:
171171

172172
https://learn.microsoft.com/en-us/windows/security/identity-protection/credential-guard/configure?tabs=reg#disable-virtualization-based-security
173173

@@ -182,6 +182,12 @@ Disabling this policy will disable the verification of the components, only if t
182182
If you enable this setting, co-installers execution will be prevented, and additional configuration software for specific devices (mouses, gaming keyboards, etc) must be downloaded and manually installed from the manufacturer website.
183183

184184
If you disable this setting, co-installers execution will be permitted, which is a significant security risk (potentially dangerous code execution).</string>
185+
<string id="DefenderSandboxing">Enable Windows Defender sandbox</string>
186+
<string id="DefenderSandboxing_Explain">This policy enables the sandbox (content process) for the main process of Windows Defender.
187+
188+
The new content processes, which run with low privileges, aggressively leverage all available mitigation policies to reduce the attack surface. They enable and prevent runtime changes for modern exploit mitigation techniques such as Data Execution Prevention (DEP), Address space layout randomization (ASLR), and Control Flow Guard (CFG). They also disable Win32K system calls and all extensibility points, as well as enforce that only signed and trusted code is loaded.
189+
190+
More information: https://www.microsoft.com/en-us/security/blog/2018/10/26/windows-defender-antivirus-can-now-run-in-a-sandbox/</string>
185191
</stringTable>
186192
<presentationTable>
187193
<presentation id="MSCacheV2_Iteration">

fr-FR/AdditionalSystemHardening.adml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,10 @@ Désactiver cette politique désactivera le mode Obligatoire, seulement si le ve
184184
Si vous activez ce paramètre, l'exécution des co-installeurs sera bloquée. Pour certains périphériques spécifiques (claviers paramétrables, cartes graphiques, etc), il sera nécessaire d'installer manuellement le logiciel de contrôle à partir du site du fabricant.
185185

186186
Si vous désactivez ce paramètre, l'exécution es co-installeurs sera autorisée, ce qui pose un risque de sécurité important (exécution de code non maîtrisé sur le système).</string>
187+
<string id="DefenderSandboxing">Activer le bac à sable de Windows Defender</string>
188+
<string id="DefenderSandboxing_Explain">Cette politique permet d'activer le bac à sable pour le processus principal de Windows Defender, permettant à celui-ci d'appliquer des durcissements modernes au processus (ALSR, CFG, DEP, signature du code chargé, ...)
189+
190+
Plus d'informations : https://www.microsoft.com/en-us/security/blog/2018/10/26/windows-defender-antivirus-can-now-run-in-a-sandbox/</string>
187191
</stringTable>
188192
<presentationTable>
189193
<presentation id="MSCacheV2_Iteration">

0 commit comments

Comments
 (0)