Kaseya Community

Local User Password Policy

This question is not answered

Hello,

I am working on a password policy to deploy to remote computer using agent procedure. A problem I am having is turning off the "Set PasswordExpires" at the group level. I would like to set this for the users group "Users" rather than trying to set it for each individual user account.

Here is what I have that works at the user level:

wmic path Win32_UserAccount where Name='kadmin' set PasswordExpires=false

How can I set PasswordExpires=True at the group level "Users"?

Thanks in advance

Dave

All Replies
  • Change of plans. Can I run the command above for all users with the exception of kadmin, or would I have to run a line to rebuild the password for kadmin?

    I am using set Registry Values in the agent procedure to change the following, but I don't want kadmin to change.

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Network\MinPwdLen

    {08 00 00 00}

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\PasswordExpiryWarning

    {0x00000010}

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Network\MaxPasswordAge

    {180}

    HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Policies\Network\AlphanumPwds

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Netlogon\Parameters\MaximumPasswordAge

    {180}

  • Can a powershell wild card be used in Name=, for all users?

    wmic path win32_useraccount where name='.*?' set passwordexpires=true