ivankruchkoff / google-authenticator

GNU General Public License v2.0
27 stars 14 forks source link

Google Authenticator

Contributors: ivankk

Tags: authentication, otp, password, security, login, android, iphone, blackberry

Requires at least: 4.5

Tested up to: 5.6

Stable tag: 0.53

License: GPLv2 or later

License URI: http://www.gnu.org/licenses/gpl-2.0.html

Google Authenticator for your WordPress blog.

Description

The Google Authenticator plugin for WordPress gives you two-factor authentication using the Google Authenticator app for Android/iPhone/Blackberry.

If you are security aware, you may already have the Google Authenticator app installed on your smartphone, using it for two-factor authentication on Gmail/Dropbox/Lastpass/Amazon etc.

The two-factor authentication requirement can be enabled on a per-user basis. You could enable it for your administrator account, but log in as usual with less privileged accounts.

If You need to maintain your blog using an Android/iPhone app, or any other software using the XMLRPC interface, you can enable the App password feature in this plugin, but please note that enabling the App password feature will make your blog less secure.

Installation

  1. Make sure your webhost is capable of providing accurate time information for PHP/WordPress, ie. make sure a NTP daemon is running on the server.
  2. Install and activate the plugin.
  3. Enter a description on the Users -> Profile and Personal options page, in the Google Authenticator section.
  4. Scan the generated QR code with your phone, or enter the secret manually, remember to pick the time based one.
    You may also want to write down the secret on a piece of paper and store it in a safe place.
  5. Remember to hit the Update profile button at the bottom of the page before leaving the Personal options page.
  6. That's it, your WordPress blog is now a little more secure.

Frequently Asked Questions

Can I use Google Authenticator for WordPress with the Android/iPhone apps for WordPress?

Yes, you can enable the App password feature to make that possible, but notice that the XMLRPC interface isn't protected by two-factor authentication, only a long password.

I want to update the secret, should I just scan the new QR code after creating a new secret?

No, you'll have to delete the existing account from the Google Authenticator app on your smartphone before you scan the new QR code, that is unless you change the description as well.

I am unable to log in using this plugin, what's wrong?

The Google Authenticator verification codes are time based, so it's crucial that the clock in your phone is accurate and in sync with the clock on the server where your WordPress installation is hosted.

If you have an Android phone, you can use an app like ClockSync to set your clock in case your Cell provider doesn't provide accurate time information.

Another option is to enable "relaxed mode" in the settings for the plugin, this will enable more valid codes by allowing up to a 4 min. timedrift in each direction.

I have several users on my WordPress installation, is that a supported configuration?

Yes, each user has his own Google Authenticator settings.

During installation I forgot the thing about making sure my webhost is capable of providing accurate time information, I'm now unable to login, please help.

If you have SSH or FTP access to your webhosting account, you can manually delete the plugin from your WordPress installation, just delete the wp-content/plugins/google-authenticator directory, and you'll be able to login using username/password again.

I don't own a Smartphone, isn't there another way to generate these secret codes?

Yes, there is a webbased version here : https://gauth.apps.gbraad.nl/

Github project here: https://github.com/gbraad/gauth

Can I create backupcodes?

No, but if you're using an Android smartphone you can replace the Google Authenticator app with Authenticator Plus.

It's a really nice app that can import your existing settings, sync between devices and backup/restore using your sd-card. It's not a free app, but it's well worth the money.

Any known incompatabilities?

Yes, the Man-in-the-middle attack/replay detection code isn't compatible with the test/setup mode in the "Stop spammer registration plugin", please remember to remove the "Check credentials on all login attempts" checkmark before installing my plugin.

Screenshots

  1. The enhanced log-in box.
  2. Google Authenticator section on the Profile and Personal options page.
  3. QR code on the Profile and Personal options page.
  4. Google Authenticator app on Android

Changelog

0.53

0.52

0.51

0.50

0.49

0.48

0.47

0.46

0.45

0.44

0.43

0.42

0.41

0.40

0.39

0.38

0.37

0.36

0.35

0.30

0.20

Credits

Thanks to:

Paweł Nowacki for the Polish translation

Fabio Zumbi for the Portuguese translation

Guido Schalkx for the Dutch Translation.

Henrik.Schack for writing/maintaining versions 0.20 through 0.48

Tobias Bäthge for his code rewrite and German translation.

Pascal de Bruijn for his "relaxed mode" idea.

Daniel Werl for his usability tips.

Dion Hulse for his bugfixes.

Aldo Latino for his Italian translation.

Kaijia Feng for his Simplified Chinese translation.

Alex Concha for his security tips.

Jerome Etienne for his jquery-qrcode plugin.

Sébastien Prunier for his Spanish and French translation.