I have a group of servers (Windows 2008 / 2012 / 2016) that are not connected to a domain.
I would like to use a command line script (powershell / ) that would allow me to change only the following values :
Security settings->Account Policies->Password Policy
Enforce password history : 3 passwords remembered
Maximum password age : 45 days
Minimum password age : 1 day
Maximum password length: 8 characters
Password must meet complexity requirements : Enabled
Store a password using reversible encryption : Disabled
I only want to change (via a script) the 6 values listed above and not change any other security settings.
How can this be accomplished?