Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #one liner command line to get last password set times for all users on the mac
- # see http://applehelpwriter.com/2018/03/14/6228
- echo; echo Password Last Changed:; u=$(dscl . list /Users | egrep -v '^_|daemon|nobody'); for i in $u; do printf \\n$i\\t; currentUser=$i;t=$(dscl . read /Users/"$currentUser" | grep -A1 passwordLastSetTime | grep real | awk -F'real>|</real' '{print $2}'); date -j -f %s "$t" 2> /dev/null; done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement