add quirks/yubico.sh
This commit is contained in:
parent
b1d9041579
commit
9ddb16b714
15
quirks/yubico.sh
Executable file
15
quirks/yubico.sh
Executable file
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash -ex
|
||||
|
||||
#
|
||||
# Quirk to enforce login and sudo with a Yubikey
|
||||
#
|
||||
|
||||
[[ -f "$sysroot"/etc/pam.d/sudo ]] && \
|
||||
sed -i -e 's#auth\s*include\s*system-auth#auth required pam_yubico.so mode=challenge-response\nauth include system-auth#g' \
|
||||
"$sysroot"/etc/pam.d/sudo
|
||||
|
||||
[[ -f "$sysroot"/etc/pam.d/gdm-password ]] && \
|
||||
sed -i -e 's#auth\s*substack\s*password-auth#auth required pam_yubico.so mode=challenge-response\nauth substack password-auth#g' \
|
||||
"$sysroot"/etc/pam.d/gdm-password
|
||||
|
||||
:
|
Loading…
Reference in a new issue