Extract dates from /etc/shadow
chage -l <username>
Example Output:
Last password change : Dec 17, 2015
Password expires : Mar 16, 2016
Password inactive : never
Account expires : never
Minimum number of days between password change : 7
Maximum number of days between password change : 90
Number of days of warning before password expires : 14
for n in $(sudo cat /etc/shadow | awk '{FS=":";print $3}'); do date -d "01/01/1970 +${n}days" +%F; done
To avoid the useless-use-of-cat-award:
for n in $(sudo awk '{FS=":";print $3}' /etc/shadow); do date -d "01/01/1970 +${n}days" +%F; done
report password status on the named account passwd -S username
for user in $(cut -d: -f1 /etc/passwd); do sudo passwd -S $user; done