Implements the client side SRP-6a protocol. Note that this class is stateful, and therefore NOT threadsafe.
This implementation of SRP is based on the optimized message sequence put forth by Thomas Wu in the paper
"SRP-6: Improvements and Refinements to the Secure Remote Password Protocol, 2002"
Initialises the client to begin new authentication attempt
N The safe prime associated with the client's verifier
g The group parameter associated with the client's verifier
digest The digest algorithm associated with the client's verifier
random For key generation
Generates client's credentials given the client's salt, identity and password
salt The salt used in the client's verifier.
identity The user's identity (eg. username)
password The user's password
- Client's public value to send to server
Generates the secret S given the server's credentials
Computes the client evidence message M1 using the previously received values.
To be called after calculating the secret S.
"some data are missing from the previous operations (A,B,S)");
Authenticates the server evidence message M2 received and saves it only if correct.
"some data are missing from the previous operations (A,M1,S)");
Computes the final session key as a result of the SRP successful mutual authentication
To be called after verifying the server evidence message M2.
"some data are missing from the previous operations (S,M1,M2)");