User accounts for terminated employees represent a significant security risk and must be disabled immediately after employee quits an organization.
NetWrix Inactive Users Tracker for PowerShell is a freeware PowerShell cmdlet that scans all domain user accounts and reports inactive users based on specified thresholds (e.g. not logged on within last 90 days).
NOTE: NetWrix Identity Management Suite is not shareware. Please contact NetWrix Corporation at www.netwrix.com to obtain more information.