node-phpbb-password
phpbb's password hashing algorithm for Nodejs
Installation
In a project
npm install --save phpbb-password
For command line use
npm install -g phpbb-password
Usage
In your code
var phpbb = ;// hash a passwordvar hash = phpbbhash'bonjour, mot de passe';console; // examples : $H$9sPKRpbzFtCY8ZGFvmPQU7qAaZlQ1E. $H$9940UI0zss3hbAt6bytgCIAthYapG20// verifyvar ok = phpbb;console; // true
In the shell
export HASH=$(phpbb-password hash "mypassword")echo $(phpbb-password verify "mypassword" "$HASH")
TODO
- Tests !
- Async ?
License
Since the original PHP code come from PHPbb itself, I think this code must also be under the GPLv2. If you think we can use BSD or something else, let me know !