|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.beepcore.beep.profile.sasl.otp.algorithm.AlgorithmImpl
Field Summary |
Fields inherited from interface org.beepcore.beep.profile.sasl.otp.algorithm.Algorithm |
ERR_HASH_FAILURE |
Constructor Summary | |
AlgorithmImpl(java.lang.String internal)
Method AlgorithmImpl |
Method Summary | |
protected abstract byte[] |
foldHash(byte[] hash)
Method foldHash is provided for implementations, as the value of the message digest hash must be folding into 64 bits before it can be used by the SASLOTPProfile and its supporting classes. |
byte[] |
generateHash(byte[] data)
Method generateHash generate a hash value using the appropriate hash function. |
byte[] |
generateHash(java.lang.String s)
Method generateHash generate a hash value using the appropriate hash function. |
abstract java.lang.String |
getName()
Method getName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AlgorithmImpl(java.lang.String internal)
internal
- The data used by the JVM internally to represent
a certain MessageDigest hash algorithm. This is
defined in JVM documentation and in constants in
SASLOTPProfile.Method Detail |
public abstract java.lang.String getName()
getName
in interface Algorithm
public byte[] generateHash(java.lang.String s) throws InvalidParameterException
generateHash
in interface Algorithm
s
- The data to be hashed
SASLException
- if an error is encountered during the
generation of hte hash.
InvalidParameterException
public byte[] generateHash(byte[] data) throws InvalidParameterException
generateHash
in interface Algorithm
data
- The data to be hashed
SASLException
- if an error is encountered during the
generation of hte hash.
InvalidParameterException
protected abstract byte[] foldHash(byte[] hash) throws InvalidParameterException
hash
- The hash value to be folded
InvalidParameterException
- of the has provided is
somehow improper or invalid.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |