|
For the latest news and information visit The GNU Crypto project |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgnu.crypto.key.srp6.SRPKey
public abstract class SRPKey
An abstract representation of a base SRP ephemeral key.
This object encapsulates the two numbers:
Note that in SRP, all arithmetic is done modulo N.
Reference:
Field Summary | |
---|---|
protected BigInteger |
g
The generator. |
protected BigInteger |
N
The public, Germaine prime, shared modulus. |
Fields inherited from interface java.security.Key |
---|
serialVersionUID |
Constructor Summary | |
---|---|
protected |
SRPKey(BigInteger N,
BigInteger g)
|
Method Summary | |
---|---|
boolean |
equals(Object obj)
Returns true if the designated object is an instance of
SRPKey and has the same SRP parameter values as this one. |
String |
getAlgorithm()
Returns the standard algorithm name for this key. |
byte[] |
getEncoded()
Deprecated. see getEncoded(int). |
abstract byte[] |
getEncoded(int format)
|
String |
getFormat()
Returns null since this implementation does not encode SRP
keys. |
BigInteger |
getG()
Returns the generator. |
BigInteger |
getN()
Returns the public shared modulus. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final BigInteger N
protected final BigInteger g
Constructor Detail |
---|
protected SRPKey(BigInteger N, BigInteger g)
Method Detail |
---|
public String getAlgorithm()
Returns the standard algorithm name for this key.
getAlgorithm
in interface Key
public byte[] getEncoded()
getEncoded
in interface Key
public String getFormat()
Returns null
since this implementation does not encode SRP
keys.
getFormat
in interface Key
public BigInteger getN()
Returns the public shared modulus.
N
.public BigInteger getG()
Returns the generator.
g
.public boolean equals(Object obj)
Returns true
if the designated object is an instance of
SRPKey
and has the same SRP parameter values as this one.
equals
in class Object
obj
- the other non-null SRP key to compare to.
true
if the designated object is of the same type and
value as this one.public abstract byte[] getEncoded(int format)
|
For the latest news and information visit The GNU Crypto project |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |