javax.management.snmp
Interface SnmpUsmKeyHandler


Deprecated. Use package com.sun.management.snmp in preference to classes in this package. This class may be removed in a future version of Java DMK.

public interface SnmpUsmKeyHandler

This interface allows you to compute key localization and delta generation. It is useful when adding user in USM MIB. An instance of SnmpUsmKeyHandler is associated to each SnmpEngine object. When computing key, an authentication algorithm is needed. The supported ones are : usmHMACMD5AuthProtocol and usmHMACSHAAuthProtocol.

Since:
Java DMK 5.0

Field Summary
static int DES_DELTA_SIZE
          Deprecated. DES privacy algorithm delta size.
static int DES_KEY_SIZE
          Deprecated. DES privacy algorithm key size.
 
Method Summary
 byte[] calculateAuthDelta(String algoName, byte[] oldKey, byte[] newKey, byte[] random)
          Deprecated. Calculate the delta parameter needed when processing key change.
 byte[] calculatePrivDelta(String algoName, byte[] oldKey, byte[] newKey, byte[] random, int deltaSize)
          Deprecated. Calculate the delta parameter needed when processing key change for a privacy algorithm.
 byte[] localizeAuthKey(String algoName, byte[] key, SnmpEngineId engineId)
          Deprecated. Localize the passed key using the passed SnmpEngineId.
 byte[] localizePrivKey(String algoName, byte[] key, SnmpEngineId engineId, int keysize)
          Deprecated. Localize the passed privacy key using the passed SnmpEngineId.
 byte[] password_to_key(String algoName, String password)
          Deprecated. Translate a password to a key.
 

Field Detail

DES_KEY_SIZE

public static final int DES_KEY_SIZE
Deprecated. 
DES privacy algorithm key size. To be used when localizing privacy key

See Also:
Constant Field Values

DES_DELTA_SIZE

public static final int DES_DELTA_SIZE
Deprecated. 
DES privacy algorithm delta size. To be used when calculating privacy key delta.

See Also:
Constant Field Values
Method Detail

password_to_key

public byte[] password_to_key(String algoName,
                              String password)
                       throws IllegalArgumentException
Deprecated. 
Translate a password to a key. It MUST be compliant to RFC 2574 description.

Parameters:
algoName - The authentication algorithm to use.
password - Password to convert.
Returns:
The key.
Throws:
IllegalArgumentException - If the algorithm is unknown.

localizeAuthKey

public byte[] localizeAuthKey(String algoName,
                              byte[] key,
                              SnmpEngineId engineId)
                       throws IllegalArgumentException
Deprecated. 
Localize the passed key using the passed SnmpEngineId. It MUST be compliant to RFC 2574 description.

Parameters:
algoName - The authentication algorithm to use.
key - The key to localize;
engineId - The Id used to localize the key.
Returns:
The localized key.
Throws:
IllegalArgumentException - If the algorithm is unknown.

localizePrivKey

public byte[] localizePrivKey(String algoName,
                              byte[] key,
                              SnmpEngineId engineId,
                              int keysize)
                       throws IllegalArgumentException
Deprecated. 
Localize the passed privacy key using the passed SnmpEngineId. It MUST be compliant to RFC 2574 description.

Parameters:
algoName - The authentication algorithm to use.
key - The key to localize;
engineId - The Id used to localize the key.
keysize - The privacy algorithm key size.
Returns:
The localized key.
Throws:
IllegalArgumentException - If the algorithm is unknown.

calculateAuthDelta

public byte[] calculateAuthDelta(String algoName,
                                 byte[] oldKey,
                                 byte[] newKey,
                                 byte[] random)
                          throws IllegalArgumentException
Deprecated. 
Calculate the delta parameter needed when processing key change. This computation is done by the key change initiator. It MUST be compliant to RFC 2574 description.

Parameters:
algoName - The authentication algorithm to use.
oldKey - The old key.
newKey - The new key.
random - The random value.
Returns:
The delta.
Throws:
IllegalArgumentException - If the algorithm is unknown.

calculatePrivDelta

public byte[] calculatePrivDelta(String algoName,
                                 byte[] oldKey,
                                 byte[] newKey,
                                 byte[] random,
                                 int deltaSize)
                          throws IllegalArgumentException
Deprecated. 
Calculate the delta parameter needed when processing key change for a privacy algorithm. This computation is done by the key change initiator. It MUST be compliant to RFC 2574 description.

Parameters:
algoName - The authentication algorithm to use.
oldKey - The old key.
newKey - The new key.
random - The random value.
deltaSize - The algorithm delta size.
Returns:
The delta.
Throws:
IllegalArgumentException - If the algorithm is unknown.

FCS Release
jdmk-5_1-b34.1 2005.02.10_16:46:09_MET

Copyright 1998-2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.