Install libpam-barada by entering the following commands in the terminal:
sudo apt update sudo apt install libpam-barada
PAM module to provide two-factor authentication based on HOTP
Use HOTP (RFC4226) two-factor authentication with PAM. . In addition to a normal password, users are also assigned a 128 bit key and arbitrary-length PIN number. Every time you'd like to login using a OTP, you calculate a secure hash based on your assigned PIN and an increasing counter, the result of which is a six character one time password. . While this module could be used in conjunction with many different client devices, it was written specifically with Android devices in mind. There is companion software which runs on Android, so that your phone essentially becomes a SecureID token. All you need to do is open up the software, type in your PIN, and you get back a 6-character number that you can use to login to your system.