Class SRP6VerifierGenerator
- java.lang.Object
-
- org.bouncycastle.crypto.agreement.srp.SRP6VerifierGenerator
-
public class SRP6VerifierGenerator extends java.lang.Object
Generates new SRP verifier for user
-
-
Constructor Summary
Constructors Constructor Description SRP6VerifierGenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.math.BigInteger
generateVerifier(byte[] salt, byte[] identity, byte[] password)
Creates a new SRP verifiervoid
init(java.math.BigInteger N, java.math.BigInteger g, Digest digest)
Initialises generator to create new verifiersvoid
init(SRP6GroupParameters group, Digest digest)
-
-
-
Field Detail
-
N
protected java.math.BigInteger N
-
g
protected java.math.BigInteger g
-
digest
protected Digest digest
-
-
Method Detail
-
init
public void init(java.math.BigInteger N, java.math.BigInteger g, Digest digest)
Initialises generator to create new verifiers- Parameters:
N
- The safe prime to use (see DHParametersGenerator)g
- The group parameter to use (see DHParametersGenerator)digest
- The digest to use. The same digest type will need to be used later for the actual authentication attempt. Also note that the final session key size is dependent on the chosen digest.
-
init
public void init(SRP6GroupParameters group, Digest digest)
-
generateVerifier
public java.math.BigInteger generateVerifier(byte[] salt, byte[] identity, byte[] password)
Creates a new SRP verifier- Parameters:
salt
- The salt to use, generally should be large and randomidentity
- The user's identifying information (eg. username)password
- The user's password- Returns:
- A new verifier for use in future SRP authentication
-
-