Skip to content

Instantly share code, notes, and snippets.

@MDtThomas
Created March 30, 2022 12:01
Show Gist options
  • Save MDtThomas/c7bfba9e5ec4349af7cea0fbee4a1a9d to your computer and use it in GitHub Desktop.
Save MDtThomas/c7bfba9e5ec4349af7cea0fbee4a1a9d to your computer and use it in GitHub Desktop.
[ActiveDirectory-Users]
Search-ADAccount -LockedOut | Sort-Object -Property LastLogonDate | Format-Table Name,SamAccountName,LastLogonDate,LockedOut
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment