MFA on ODA configuration(google-authenticator)
step-by-step:
vim /etc/ssh/sshd_config
# set 'ChallengeResponseAuthentication yes' and save.
# make sure to set 'PermitRootLogin yes'.
yum -y update
yum -y install qrencode
yum -y install libpng
yum install -y oracle-epel-release-el8(depending on OS version)
yum -y install google-authenticator(can use dnf or yum)
cd /lib64/security/
ls
-- copy the "pam_google_authenticator.so"
vim /etc/pam.d/sshd
# insert anoher line/entry:
auth required pam_google_authenticator.so
Note: before proceeding to the next step, please make sure the TIME-DATE and
TIMEZONE of your machine and mobile device are the same(in sync).
---now we can configure and enable the google authenticator by generating QR code
and sscanning it on the mobile device to get the verification code.
google-authenticator
y
y
n(depending on user preference)
y