-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Only perform asynchronous, save-time hashing
The original default method of hashing passwords during the `setter` method was not ideal for node async i/o. The benefit of doing it at set-time was to immediately hash the password, to prevent any leaking. To add some of this security to the asynchronous method, we use the bookshelf `virtuals` plugin, and never set `password` on the model `attributes` hash. This will prevent the password from being exposed during a toJSON call (or other).
- Loading branch information
Showing
4 changed files
with
151 additions
and
284 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.