Script for user accounts passworks over 90days

Ralph Le Grange 1 Reputation point
2022-12-12T11:29:07.51+00:00

Hi Team

Does anyone have a script for to extract user accounts whose passwords are over 90 days , but need to exclude OU with Service accounts)

and add to a specific security group

Thanks
ralph

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,628 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Andreas Baumgarten 120.2K Reputation points MVP
    2022-12-12T12:25:27.71+00:00

    Hi @Ralph Le Grange ,

    maybe these 2 threads are helpful:

    https://community.spiceworks.com/topic/2215374-get-aduser-exclude-specific-ou-and-save-to-csv

    https://learn.microsoft.com/en-us/answers/questions/1116190/how-to-create-powershell-list-accounts-last-passwo.html

    ----------

    (If the reply was helpful please don't forget to upvote and/or accept as answer, thank you)

    Regards
    Andreas Baumgarten


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.