scoutforpets / objection-password

Automatic password hashing for Objection.js
62 stars 28 forks source link

Any consideration into moving from Bcrypt to Bcryptjs #17

Closed BrentBrightling closed 5 years ago

BrentBrightling commented 5 years ago

Hey there,

I was just wondering if there is any consideration into switching over to Bcryptjs instead of bcrypt. It seems like there are a number of developers who experience several issues with bcrypt, and from my research it seems like to be able to run bcrypt on some machines it requires a lot of dependencies to be installed. The general consensus is to just run bcryptjs as it is more standalone.

Any insight on this? Or should I just use my own fork if I want to go this route?

jamesdixon commented 5 years ago

Hey @BrentBrightling,

Thanks for the message. I won't be moving this to Bcrypt.js as it's magnitudes slower than native Bcrypt. I too have run into issues with Bcrypt before and at one point tried using the JS version. Unfortunately, it was just too slow to be usable for authentication purposes so I ended up figuring out the issue with the native version and haven't looked back.

Cheers, James

medmin commented 4 years ago

Could you share your solution with the native bcrypt ? I have warnings when trying to install objection-password. Apparently, there are some issues when installing the bcrypt lib. The installation is successful eventually, but there are warnings in the console.

Thanks.