Skip to content
This repository has been archived by the owner on May 10, 2022. It is now read-only.

pyama86/pam-google-web-oauth-rs

Repository files navigation

Warning

This project will be close, because using OAuth method will be deprecate. please see it: https://developers-jp.googleblog.com/2022/03/oauth-google-oauth.html

pam-google-web-oauth

Description

pam-google-web-oauth is ssh authentication software. this provides you multi-factor authentication.

demo

Usage

Install Script

$ curl -s https://pam-google-web-oauth.lolipop.io/install.sh | bash -

Manualy install

  1. Get the oAuth client ID on google.

  2. set binary.

    • debian: /lib/x86_64-linux-gnu/security/pam-google-web-oauth.so
    • centos: /lib64/security/pam-google-web-oauth.so
  3. Write the following in /etc/pam.d/sshd

auth required pam-google-web-oauth.so client_id=%CLIENT_ID% client_secret=%CLIENT_SECRET% user_dir=/opt/pam-google-web-oauth
#@include common-auth # must comment out.
  1. Write the following in sshd_config and restart sshd process.
KbdInteractiveAuthentication yes
UsePAM yes
AuthenticationMethods publickey,keyboard-interactive
ChallengeResponseAuthentication yes

Contribution

  1. Fork (https://github.com/pyama86/google-web-oauth/fork)
  2. Create a feature branch
  3. Commit your changes
  4. Rebase your local changes against the master branch
  5. Run test suite with the go test ./... command and confirm that it passes
  6. Run gofmt -s
  7. Create a new Pull Request

Author

pyama86