|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.sun.management.snmp.usm.SnmpUsmAlgorithmImpl
com.sun.management.snmp.usm.SnmpUsmDesAlgorithm
This is an implementation of Des encryption algorithm. It is based on JCE. If you use this algorithm, make sure that JCE jar files are accessible.
| Field Summary | |
static String |
DES_PRIV
Algorithm name as defined in rfc 2574, "usmDESPrivProtocol". |
| Constructor Summary | |
SnmpUsmDesAlgorithm(SnmpEngine engine)
Constructor. |
|
SnmpUsmDesAlgorithm(SnmpEngine engine,
String properties_encrypt,
String properties_decrypt)
Constructor. |
|
| Method Summary | |
byte[] |
decrypt(byte[] key,
com.sun.management.internal.snmp.SnmpEncryptionPair pair)
Decrypts the passed encrypted data using the provided IV parameter. |
com.sun.management.internal.snmp.SnmpEncryptionPair |
encrypt(byte[] key,
byte[] data,
int dataLength)
Encrypts the passed data with the provided key. |
String |
getAlgorithm()
Gets the unique algorithm name. |
int |
getDeltaSize()
Gets the delta size. |
int |
getKeySize()
The privacy algorithm key size. |
String |
getOid()
Gets the algorithm OID as defined in RFC 2574. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.sun.management.snmp.usm.SnmpUsmAlgorithm |
getAlgorithm |
| Field Detail |
public static final String DES_PRIV
| Constructor Detail |
public SnmpUsmDesAlgorithm(SnmpEngine engine)
throws SnmpUsmException
engine - The local snmp engine.
public SnmpUsmDesAlgorithm(SnmpEngine engine,
String properties_encrypt,
String properties_decrypt)
throws SnmpUsmException
engine - The local SNMP engine.properties_encrypt - The String used to instantiate the proper
JCE Cipher encryption object.properties_decrypt - The String used to instantiate the proper
JCE Cipher decryption object.| Method Detail |
public int getKeySize()
getKeySize in interface SnmpUsmPrivAlgorithmpublic int getDeltaSize()
getDeltaSize in interface SnmpUsmPrivAlgorithmpublic String getOid()
getOid in interface SnmpUsmAlgorithm
public com.sun.management.internal.snmp.SnmpEncryptionPair encrypt(byte[] key,
byte[] data,
int dataLength)
throws SnmpUsmException
encrypt in interface SnmpUsmPrivAlgorithmkey - The key to use.data - The data to encrypt.dataLength - The data length.
SnmpUsmException
public byte[] decrypt(byte[] key,
com.sun.management.internal.snmp.SnmpEncryptionPair pair)
throws SnmpUsmException
decrypt in interface SnmpUsmPrivAlgorithmkey - The Des key.pair - The data + IV parameter.
SnmpUsmExceptionpublic String getAlgorithm()
SnmpUsmAlgorithm
getAlgorithm in interface SnmpUsmAlgorithm
|
FCS Release jdmk-5_1-b34.1 2005.02.10_16:46:09_MET |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||