This repository has been archived by the owner on Dec 9, 2020. It is now read-only.
Make password checking algorithm configurable #7
+75
−40
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hey Micahl,
First off, thanks for all your hard work on the .NET OAuth 2.0 provider. I found it to be the simplest solution to grok and work with.
Based on the ideas you outlined in your open issue on making password hashing agnostic, I've created a patch to address this concern. Instead of exposing a hash function however, I'm exposing a function to compare a password with a stored hash. I did this because most of the recommended password hashing functions (BCrypt, SCrypt) recommend hashing a password with a salt. If we were to expose a function that generated a hash, we would have to ask for this salt too. In reality though, all we care about is whether the password is correct or not, so I'm letting the consumer of the library dictate that. Hope that makes sense.
Let me know if I've overlooked something. Thanks.