This commit is contained in:
2026-05-11 09:15:08 +02:00
parent 9bec2b9e42
commit 404ee3fec4
641 changed files with 416825 additions and 0 deletions
@@ -0,0 +1,9 @@
#!/bin/bash
{
awk -F: '/^[^:]+:[^!*]/{print $1}' /etc/shadow | while read -r usr; do
change=$(date -d "$(chage --list $usr | grep '^Last password change' | cut -d: -f2 | grep -v 'never$')" +%s)
if [[ "$change" -gt "$(date +%s)" ]]; then
echo "User: \"$usr\" last password change was \"$(chage --list $usr | grep '^Last password change' | cut -d: -f2)\""
fi
done
}