Difference between revisions of "Google-authenticator-libpam"

From wikieduonline
Jump to navigation Jump to search
(Created page with " brew install google-authenticator-libpam == See also == * {{Google Authenticator}}")
 
Line 1: Line 1:
 
  brew install google-authenticator-libpam
 
  brew install google-authenticator-libpam
  
 +
 +
Add 2-factor authentication for ssh:
 +
  echo "auth required /usr/local/opt/google-authenticator-libpam/lib/security/pam_google_authenticator.so" \
 +
  | sudo tee -a /etc/pam.d/sshd
 +
 +
Add 2-factor authentication for ssh allowing users to log in without OTP:
 +
  echo "auth required /usr/local/opt/google-authenticator-libpam/lib/security/pam_google_authenticator.so" \
 +
  "nullok" | sudo tee -a /etc/pam.d/sshd
  
 
== See also ==
 
== See also ==
 
* {{Google Authenticator}}
 
* {{Google Authenticator}}

Revision as of 11:21, 11 November 2020

brew install google-authenticator-libpam


Add 2-factor authentication for ssh:
 echo "auth required /usr/local/opt/google-authenticator-libpam/lib/security/pam_google_authenticator.so" \
 | sudo tee -a /etc/pam.d/sshd

Add 2-factor authentication for ssh allowing users to log in without OTP:
 echo "auth required /usr/local/opt/google-authenticator-libpam/lib/security/pam_google_authenticator.so" \
 "nullok" | sudo tee -a /etc/pam.d/sshd

See also

Advertising: