Closed ryanwarsaw closed 7 years ago
@ryanwarsaw can we proceed with this? I'm trying to get Thimble working with node 6.9.x https://github.com/mozilla/thimble.mozilla.org/pull/1714 and it fails with bcrypt (I get this error).
@cadecairos what do you think?
Go for it, hopefully it's just a drop in replacement.
HOWEVER.
I just found this, which suggests CPU time available to heroku instances impacts the JS bcrypt much more than you'd expect: https://github.com/dcodeIO/bcrypt.js/issues/42
ughhhhh why can't we have nice things???
@gideonthomas No problems at all, I think we can work around this. The folks running the bcrypt module we use have been looking for help to set the pre-built binaries again. I'll make my way over there and see if I can lend a helping hand.
We currently use a native version of bcrypt with Javascript bindings as our library of choice. This is problematic because this library lacks pre-built binaries, which forces
node-gyp
to fallback to manual compilation of the library. This causes issues when setting up login, especially if you don't have your environment setup right.Let's switch over to something like: https://www.npmjs.com/package/bcryptjs, it's slower but it's written in Javascript entirely and removes the requirement to manually compile bcrypt.