google-web-oauth is ssh authentication software. this provides you with multi-factor authentication.
for ubuntu
- Get the oAuth client ID on google.
- Please place the secret file to
/etc/google-web-oauth/client_secret.json
- set binary.
- /lib/x86_64-linux-gnu/security/google-web-oauth.so
- /usr/bin/google-web-oauth
- Write the following in /etc/pam.d/sshd
auth required google-web-oauth.so
#@include common-auth # must comment out.
- Write the following in sshd_config and restart sshd process.
KbdInteractiveAuthentication yes
UsePAM yes
AuthenticationMethods publickey,keyboard-interactive
ChallengeResponseAuthentication yes
In this case, they skip ForceCommand when use ProxyCommand, it is vulnerable...
- Get the oAuth client ID on google.
- Please place the secret file to
/etc/google-web-oauth/client_secret.json
- set binary.
- /usr/bin/google-web-oauth
- Write the following in sshd_config and restart sshd process.
ForceCommand sudo SSH_CONNECTION="$SSH_CONNECTION" /usr/bin/google-web-oauth && eval ${SSH_ORIGINAL_COMMAND:-/bin/bash}
To install, use go get
:
$ go get -d github.com/pyama86/google-web-oauth
- Fork (https://github.com/pyama86/google-web-oauth/fork)
- Create a feature branch
- Commit your changes
- Rebase your local changes against the master branch
- Run test suite with the
go test ./...
command and confirm that it passes - Run
gofmt -s
- Create a new Pull Request