How to find out when an Active Directory user account password is due to expire, here is a easy powershell script which will display when each users AD account is due to expire:

Get-ADUser -filter {Enabled -eq $True -and PasswordNeverExpires -eq $False} -Properties "DisplayName", "msDS-UserPasswordExpiryTimeComputed" | Select-Object -Property "Displayname",@{Name="ExpiryDate";Expression={[datetime]::FromFileTime($_."msDS-UserPasswordExpiryTimeComputed")}}

Leave a Reply

Your email address will not be published. Required fields are marked *