Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,14 @@ console.log(verifier)

*note:* `derivePrivateKey` is provided for completeness with the SRP 6a specification. It is however recommended to use some form of "slow hashing", like [PBKDF2](https://en.wikipedia.org/wiki/PBKDF2), to reduce the viability of a brute force attack against the verifier.

*note:* The use of a username as part of the verifier calculation means that if the user changes their
username they must simultaneously provide an update salt and verifier to the server. If a user
is able to login with multiple identifiers (e.g. username, phone number, or email address) you would
need a separate verifier for each identifier. To avoid these issues you can leave the `username` blank
for purposes of this algorithm. The downside of not using a username is that a server can do an attack
to determine whether two users have the same password. For normal apps that trust the server but use
SRP just to avoid transmitting plaintext passwords, this may be an acceptable trade-off.

### Logging in

Authenticating with the server involves mutliple steps.
Expand Down