0x6d69636b / windows_hardening

HardeningKitty and Windows Hardening Settings
MIT License
2.33k stars 306 forks source link

please consider using Set-StrictMode #124

Closed rafalfitt closed 1 year ago

rafalfitt commented 2 years ago

Set-StrictMode -Version Latest

more info: https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/set-strictmode?view=powershell-7.2

0x6d69636b commented 2 years ago

Could you provide more information: Should the Strict-Mode set in the HardeningKitty module? Or is this an appendix for the hardening list? If so, what is the security/hardening benefit? Is there a group policy to set Strict-Mode?

rafalfitt commented 2 years ago

it is a Powershell command, so it is for the HardeningKitty module.

rafalfitt commented 2 years ago

https://devblogs.microsoft.com/scripting/enforce-better-script-practices-by-using-set-strictmode/

An78toi13ne06 commented 1 year ago

Set-Strictmode is irrelevant in a release as this should only be use during the coding process and disabled in the production version. Set-Strictmode only help getting more explicit error messages when developing.

0x6d69636b commented 1 year ago

Thanks @An78toi13ne06 for the clarification. I ran HardeningKitty with Set-Strictmode on without any errors and will use it for new versions.

rafalfitt commented 1 year ago

Thank you @0x6d69636b :-) Please keep it in both versions, released or not.