au.net.aba.crypto.provider
Class DESKey
java.lang.Object
|
+--au.net.aba.crypto.provider.DESKey
- public class DESKey
- extends java.lang.Object
- implements SecretKey, java.io.Externalizable
a class that provides a basic DES key.
- See Also:
- Serialized Form
Field Summary |
static java.lang.String |
ident
|
Constructor Summary |
DESKey()
constructor for serialisation |
DESKey(byte[] rawKey)
standard constructor. |
Method Summary |
java.lang.String |
getAlgorithm()
returns the algorithm for this key. |
byte[] |
getEncoded()
returns an encoded representation of this key. |
java.lang.String |
getFormat()
returns the format for this key. |
void |
readExternal(java.io.ObjectInput in)
serialisation support using Externalizable. |
void |
writeExternal(java.io.ObjectOutput out)
serialisation support using Externalizable. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
ident
public static final java.lang.String ident
DESKey
public DESKey()
- constructor for serialisation
DESKey
public DESKey(byte[] rawKey)
- standard constructor.
- Parameters:
rawKey
- the byte array containing the raw key data.
getAlgorithm
public java.lang.String getAlgorithm()
- returns the algorithm for this key.
- Returns:
- the string "DES"
getFormat
public java.lang.String getFormat()
- returns the format for this key.
- Returns:
- the string "RAW"
getEncoded
public byte[] getEncoded()
- returns an encoded representation of this key.
- Returns:
- the key as raw byte data.
writeExternal
public void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
- serialisation support using Externalizable.
- Specified by:
- writeExternal in interface java.io.Externalizable
- Parameters:
out
- the object output stream.
readExternal
public void readExternal(java.io.ObjectInput in)
throws java.io.IOException
- serialisation support using Externalizable.
- Specified by:
- readExternal in interface java.io.Externalizable
- Parameters:
in
- the object input stream.