This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
2fa [2024/05/03 17:25] – -formatting, condense hogwild | 2fa [2024/05/03 18:01] – hogwild | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Setting up 2FA for SSH using GoogleAuthenticator ====== | ====== Setting up 2FA for SSH using GoogleAuthenticator ====== | ||
- | [FIXME] | + | This is content taken from the following forum thread: \\ [[https:// |
- | These are simple configuration notes. This is not intended to be a complete HOWTO. | + | These are simple configuration notes and are not intended to be a complete HOWTO. |
- | + | ||
- | \\ | + | |
This setup uses openssh with google-authenticator as 2-Factor Authentication. Only the root user is supported. | This setup uses openssh with google-authenticator as 2-Factor Authentication. Only the root user is supported. | ||
- | |||
- | Prerequisites : - setup entware (not covered here) \\ | ||
\\ | \\ | ||
+ | |||
+ | Prerequisite: | ||
+ | |||
+ | \\ First, we install openssh-server and google-authenticator: | ||
opkg install openssh-server-pam google-authenticator-libpam | opkg install openssh-server-pam google-authenticator-libpam | ||
- | (hopefully | + | Hopefully |
- | now the configs: | + | \\ |
+ | |||
+ | Next, we enable openssh-server . This is not covered here. < | ||
- | / | + | Next, we configure the correct settings in configuration file / |
#!/bin/sh | #!/bin/sh | ||
Line 46: | Line 48: | ||
exit 0 | exit 0 | ||
- | this new service | + | \\ |
+ | |||
+ | The new service | ||
- | / | + | / |
Port 2222 # to be changed if desired | Port 2222 # to be changed if desired |