Skip to main content

Posts

Showing posts from February, 2019

Implementing Google Authentication on CentOS 7.x

IntroductionTraditional login credentials on a Linux system involves a username and password. However, a lot of services are adding two-factor authentication in order to be more secure, so not only something you know (the password) but also something you have (an authenticator). This can be easily done using the Google Authenticator, an app you can download on any modern smartphone.You can add the same capability to your Linux system so that the login process will ask you for your password and the token.InstallationThe following root commands will get the Google Authenticator library and instal it on your system, along with NTP to ensure the clock is kept in sync, which is crucial for this to work:yum install ntp systemctl enable ntpd systemctl start ntpd yum install pam-devel wget https://github.com/google/google-authenticator/archive/master.zip unzip master.zip cd google* ./bootstrap.sh ./configure make make install ConfigurationFirst, you need to add Google Authenticator t…