Search Over 30,000 FREE Plugins from the Official WordPress Plugin Directory Repository

PHP Native password hash

Makes Wordpress use PHP's native password_hash() functions for portable, stronger, and time-attack safe bcrypt hashes.

Requires PHP 5.5 or later

This plugin swaps out Wordpress core's password hashing mechanism with PHP 5.5's password_hash() and its accompanying functions. By default, PHP uses bcrypt to hash the passwords.

  • A password salt will be generated using a Cryptographically Secure Pseudo-Random Number Generator (CSPRNG)
  • Password hashes are safe from dictionary attacks with rainbow tables or any other precomputed hash lists, because a secure salt is generated for each password.
  • The password hashing is iterated multiple times to provide a good resistance against brute-force attacks.
  • Password checks are made in a way that it mitigates time-attacks.
  • You do not have to reset passwords of all users. Passwords already hashed in the database will be rehashed automatically and transparently the next time the user logs in.
  • PHP might come up with newer password hashing algorithms, and they will be automatically supported without having to reset all the passwords.

This plugin was made initially because one of our applications used Wordpress for authentication, but we needed to use an external system to verify the passwords directly from the database too. Since Wordpress has its own password hashing algorithm, we decided to make this plugin to address that problem. With this plugin, passwords generated by both Wordpress and other custom applications now use the PHP's default password_hash() functions without compromising any of the applications security.

Author Ayesh Karunaratne
Profile
Contributors ayeshrajans
Tags bcrypt, password, password hashing, password security, password_hash, security
  1. Upload the plugin files to the /wp-content/plugins/password-hash directory, or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the 'Plugins' screen in WordPress.
  3. You are all set! There is nothing to configure. All existing users passwords will be rehashed on their next successful login. There is no configuration UI; it just works.

1.0

  • Initial release.

Why does this plugin require PHP 5.5?

Because the underline functionality is only available since PHP 5.5. There are other open source workarounds, but we found the effort not worth it. The oldest PHP version officially supported by PHP maintainers is PHP 5.6 as of now, so if you are using an older version, you are risking your site to potential bugs and security issues.

Do I have to reset all existing passwords?

Nope! This plugin is smart enough to identify an old password hash, capable to seamlessly validate it using the old algorithm, and update the hash with the new version automatically. Your users wouldn't notice a thing.

What happens if I uninstall this plugin?

Technically, password hashing is a one-way operation. This means we cannot undo the effect of this plugin. Your existing users will need to reset their passwords. However, your password hashes will remain safe.

How do I confirm the new hashing algorithm is in use?

The easiest way would be to check your database from PHPMyAdmin or any other software in its line. Check if the password hash field in your users table has the format $2y$10.... Those who have not updated their hashes will be have a different format. However, if the plugin was unable to make its changes, you will see a notification in your Wordpress dashboard. If you do not see anything, you are golden.

How did pirates collaborate before computers?

Pier to pier networking.

Share  
Download
Version 1.0

Requires WordPress version: 3.7 or higher

Compatible up to: 4.7.2

Last Updated 01 Feb 2017

Date Added: 06 Jan 2017

Evaluation
star1
star2
star3
star4
star5

5 stars
1 ratings
50 downloads

Compatibility

Not Enough Data

Reports:
Works: 0
Broken: 0