DHKickstartParameters
public class DHKickstartParametersImpl extends java.lang.Object implements DHKickstartParameters
DHKickstartParametersImpl
provides the kickstart public parameters needed to
initialize Diffie Hellman key exchange. These parameters have to exchanged out-of-band as
defined by RFC 2786. This implement of the DHKickstartParameters
interface provides
a static method to create kickstart parameters from a set of properties of the following form:
dh.publicKey.<securityName>=<publicKeyHexFormattedWithoutSeparator>
dh.authProtocol.<securityName>=<OID>
dh.privProtocol.<securityName>=<OID>
dh.vacm.role.<securityName>=<vacmRole>
dh.reset.<securityName>=true|false
Constructor | Description |
---|---|
DHKickstartParametersImpl(org.snmp4j.smi.OctetString securityName,
org.snmp4j.smi.OctetString publicKey) |
Create a Diffie Hellman kickstart parameter set with default authentication (MD5) and privacy (DES) protocols.
|
DHKickstartParametersImpl(org.snmp4j.smi.OctetString securityName,
org.snmp4j.smi.OctetString publicKey,
org.snmp4j.smi.OID authenticationProtocol,
org.snmp4j.smi.OID privacyProtocol,
java.lang.String vacmRole,
boolean resetRequested) |
Create a Diffie Hellman kickstart parameter set with the provided authentication and privacy protocols.
|
Modifier and Type | Method | Description |
---|---|---|
boolean |
equals(java.lang.Object o) |
|
org.snmp4j.smi.OID |
getAuthenticationProtocol() |
As extension for RFC 2786 this parameter allows to select the authentication protocol to use for the
kickstart operation.
|
org.snmp4j.smi.OID |
getPrivacyProtocol() |
As extension for RFC 2786 this parameter allows to select the privacy protocol to use for the
kickstart operation.
|
org.snmp4j.smi.OctetString |
getPublicKey() |
Gets the public Diffie Hellman public key for this security name (from the command generator).
|
org.snmp4j.smi.OctetString |
getSecurityName() |
Gets the security name associated with the kickstart parameters.
|
java.lang.String |
getVacmRole() |
Returns the (optional) role associated with the security name.
|
int |
hashCode() |
|
boolean |
isResetRequested() |
Indicates whether an existing user with StorageType nonVolatile or permanent should be replaced by this kickstart
user or not.
|
static java.util.List<DHKickstartParameters> |
readFromProperties(java.lang.String propertyPrefix,
java.util.Properties properties) |
|
java.lang.String |
toString() |
public DHKickstartParametersImpl(org.snmp4j.smi.OctetString securityName, org.snmp4j.smi.OctetString publicKey, org.snmp4j.smi.OID authenticationProtocol, org.snmp4j.smi.OID privacyProtocol, java.lang.String vacmRole, boolean resetRequested)
securityName
- the security name of the provisioned user.publicKey
- the Diffie Hellman public key as defined by RFC 2786.authenticationProtocol
- the OID of the authentication protocol to be used by this user.privacyProtocol
- the OID of the privacy protocol to be used by this user.vacmRole
- the agent implementation specific VACM role that defines the access rights associated with the user.resetRequested
- if true
, existing nonVoltile or permanent USM user with the same security name will be replaced
by this new kickstart user.public DHKickstartParametersImpl(org.snmp4j.smi.OctetString securityName, org.snmp4j.smi.OctetString publicKey)
securityName
- the security name of the provisioned user.publicKey
- the Diffie Hellman public key as defined by RFC 2786.public org.snmp4j.smi.OctetString getSecurityName()
DHKickstartParameters
getSecurityName
in interface DHKickstartParameters
public org.snmp4j.smi.OctetString getPublicKey()
DHKickstartParameters
getPublicKey
in interface DHKickstartParameters
public org.snmp4j.smi.OID getAuthenticationProtocol()
DHKickstartParameters
null
is returned.getAuthenticationProtocol
in interface DHKickstartParameters
null
if the default (usmHMACMD5AuthProtocol) should be
used.public org.snmp4j.smi.OID getPrivacyProtocol()
DHKickstartParameters
null
is returned.getPrivacyProtocol
in interface DHKickstartParameters
null
if the default (usmDESPrivProtocol) should be
used.public java.lang.String getVacmRole()
DHKickstartParameters
admin - unlimited access monitor - read-only access
getVacmRole
in interface DHKickstartParameters
public boolean isResetRequested()
isResetRequested
in interface DHKickstartParameters
true
if a reset of an existing user is requested, false
otherwise.public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public static java.util.List<DHKickstartParameters> readFromProperties(java.lang.String propertyPrefix, java.util.Properties properties)
Copyright © 2018 SNMP4J.org. All rights reserved.