PHP Classes

Secure Password Generation and Validation: Create and validate password hashes

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 434 All time: 6,293 This week: 660Up
Version License PHP version Categories
secure-password 1.0BSD License5.3PHP 5, Cryptography, Validation, Secu...
Description 

Author

This class can create and validate password hashes.

It can take a password string and create a hash to be able to verify it later without storing the original password text.

It uses only strong algorithms like blowfish, sha256 and sha512 to generate salts with strong entropy using openssl_random_pseudo_bytes or mcrypt_create_iv.

It also implements the standard used by the Mozilla security team to first hash the password using HMAC, then using that hash for the actual hashing sequence.

The class can also verify if a previously generated hash matches a given password.

Picture of Ole Aass
Name: Ole Aass <contact>
Classes: 1 package by
Country: Norway Norway

  Files folder image Files (6)  
File Role Description
Accessible without login Plain text file example1.php Example Basic example
Accessible without login Plain text file example2.php Example Example using HMAC layer
Accessible without login Plain text file hmacKey.txt Example Key used in HMAC example
Accessible without login Plain text file LICENSE.txt Lic. License
Accessible without login Plain text file makeHmacKey.php Example How to generate a HMAC key
Plain text file Password.php Class Main class file

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:434
This week:0
All time:6,293
This week:660Up