isolated-bcrypt

0.0.4 • Public • Published

isolated-bcrypt

This is a dirty, dirty hack around bcrypt being horribly broken in node 0.11. You probably shouldn't use this in production.

Recommended usage

var bcrypt;
try {
  bcrypt = require('bcrypt')
} catch (e) {
  bcrypt = require('isolated-bcrypt')
}

bcrypt.hash(password, rounds, function (err, hashed) {
  bcrypt.compare(password, hashed, function (err, same) {
    console.log('passwords match?', same)
  })
})

Notes

I haven't bothered implementing the longer genSalt method. Nag me if you think you need it.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.4
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.4
    0
  • 0.0.3
    0
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i isolated-bcrypt

Weekly Downloads

0

Version

0.0.4

License

MIT

Last publish

Collaborators

  • qard