Skip to content

Instantly share code, notes, and snippets.

@snevas
Created August 19, 2020 14:13
Show Gist options
  • Save snevas/c34d738576cfcb0a7178ad95c4877b66 to your computer and use it in GitHub Desktop.
Save snevas/c34d738576cfcb0a7178ad95c4877b66 to your computer and use it in GitHub Desktop.
Ubuntu 20.04 alternate gdm-login (screensaver unlock password)
# apt install db5.3-util whois
# mkdir /var/local/screenpass
# chown root:shadow /var/local/screenpass
# chmod 2750 /var/local/screenpass
$ mkpasswd -m des
# db5.3_load -h /var/local/screenpass -t hash -T passwd.db
[user]
[despass]
^D
# cp /etc/pam.d/gdm-password /etc/pam.d/_gdm-password
Replace "@include common-auth" in /etc/pam.d/gdm-password with:
auth [success=1 default=ignore] pam_userdb.so crypt=crypt db=/var/local/screenpass/passwd
auth requisite pam_deny.so
auth required pam_permit.so
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment