public class SRP6Server extends Object
Modifier and Type | Field and Description |
---|---|
protected BigInteger |
A |
protected BigInteger |
b |
protected BigInteger |
B |
protected Digest |
digest |
protected BigInteger |
g |
protected BigInteger |
N |
protected SecureRandom |
random |
protected BigInteger |
S |
protected BigInteger |
u |
protected BigInteger |
v |
Constructor and Description |
---|
SRP6Server() |
Modifier and Type | Method and Description |
---|---|
BigInteger |
calculateSecret(BigInteger clientA)
Processes the client's credentials.
|
BigInteger |
generateServerCredentials()
Generates the server's credentials that are to be sent to the client.
|
void |
init(BigInteger N,
BigInteger g,
BigInteger v,
Digest digest,
SecureRandom random)
Initialises the server to accept a new client authentication attempt
|
protected BigInteger |
selectPrivateValue() |
protected BigInteger N
protected BigInteger g
protected BigInteger v
protected SecureRandom random
protected Digest digest
protected BigInteger A
protected BigInteger b
protected BigInteger B
protected BigInteger u
protected BigInteger S
public void init(BigInteger N, BigInteger g, BigInteger v, Digest digest, SecureRandom random)
N
- The safe prime associated with the client's verifierg
- The group parameter associated with the client's verifierv
- The client's verifierdigest
- The digest algorithm associated with the client's verifierrandom
- For key generationpublic BigInteger generateServerCredentials()
public BigInteger calculateSecret(BigInteger clientA) throws CryptoException
clientA
- The client's credentialsCryptoException
- If client's credentials are invalidprotected BigInteger selectPrivateValue()
Copyright © 2015. All rights reserved.