Magic Quadrant™ for Privileged Access Management 2025: Netwrix Recognized for the Fourth Year in a Row. Download the report.

Platform
Resource centerHow-to-Guide
How to Get a List of Users with Password Never Expires

How to Get a List of Users with Password Never Expires

Netwrix Auditor for Active Directory

  • Run Netwrix Auditor → Navigate to “Reports” → Open “Active Directory” → Go to “Active Directory - State-in-Time” → Select “User Accounts – Passwords Never Expire” → Click “View”.
  • To receive the report regularly by email, click the “Subscribe” button and choose the schedule you prefer.
Image


Native Auditing

  • Open the Powershell ISE → Create new script with the following code and run it, specifying the path for export:
      # Import the AD module to the session

Import-Module ActiveDirectory

#Search for the users and export report

get-aduser -filter * -properties Name, PasswordNeverExpires | where {
$_.passwordNeverExpires -eq "true" } | Select-Object DistinguishedName,Name,Enabled |
Export-csv c:\data\pw_never_expires.csv -NoTypeInformation
      
  • Open the file produced by the script in MS Excel.
Image

Share on