|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.management.snmp.mpm.SnmpMsgTranslatorV1V2
public class SnmpMsgTranslatorV1V2
This translator is dedicated to translate V1 V2 parameters in the context of SNMP V3 messages. It infers some parameters such as context name and context engine Id.
Constructor Summary | |
---|---|
SnmpMsgTranslatorV1V2(SnmpEngine engine)
|
Method Summary | |
---|---|
byte[] |
getAccessContext(SnmpMsg msg)
The access context (used in IP ACL) is the community string. |
byte[] |
getContextEngineId(SnmpMsg msg)
Context engine Id is ALL THE TIME the local one. |
byte[] |
getContextName(SnmpMsg msg)
A context name can be added at the end of the community string via @ separator. |
byte[] |
getEncryptedPdu(SnmpMsg msg)
No encryption, returns null. |
byte[] |
getFlatSecurityParameters(SnmpMsg msg)
The IP address is used as the ACL key. |
byte |
getMsgFlags(SnmpMsg msg)
Returns the message flags. |
int |
getMsgId(SnmpMsg msg)
Returns the request or message Id contained in the passed message. |
int |
getMsgMaxSize(SnmpMsg msg)
Returns the response max message size. |
int |
getMsgSecurityModel(SnmpMsg msg)
Returns the message security model. |
byte[] |
getRawContextName(SnmpMsg msg)
The received community string contains : The context Name + the access context (via @ separator). |
int |
getSecurityLevel(SnmpMsg msg)
Returns the message security level. |
SnmpSecurityParameters |
getSecurityParameters(SnmpMsg msg)
Returns the message security parameters. |
void |
setContextEngineId(SnmpMsg req,
byte[] contextEngineId)
Does nothing, is used in V3 to set the context engine id after decryption. |
void |
setContextName(SnmpMsg req,
byte[] contextName)
Does nothing, is used in V3 to set the context name after decryption. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SnmpMsgTranslatorV1V2(SnmpEngine engine)
Method Detail |
---|
public int getMsgId(SnmpMsg msg)
SnmpMsgTranslator
getMsgId
in interface SnmpMsgTranslator
public int getMsgMaxSize(SnmpMsg msg)
SnmpMsgTranslator
getMsgMaxSize
in interface SnmpMsgTranslator
public byte getMsgFlags(SnmpMsg msg)
SnmpMsgTranslator
getMsgFlags
in interface SnmpMsgTranslator
public int getSecurityLevel(SnmpMsg msg)
SnmpMsgTranslator
getSecurityLevel
in interface SnmpMsgTranslator
public int getMsgSecurityModel(SnmpMsg msg)
SnmpMsgTranslator
getMsgSecurityModel
in interface SnmpMsgTranslator
public SnmpSecurityParameters getSecurityParameters(SnmpMsg msg)
SnmpMsgTranslator
getSecurityParameters
in interface SnmpMsgTranslator
public byte[] getFlatSecurityParameters(SnmpMsg msg)
getFlatSecurityParameters
in interface SnmpMsgTranslator
public byte[] getContextEngineId(SnmpMsg msg)
getContextEngineId
in interface SnmpMsgTranslator
public byte[] getRawContextName(SnmpMsg msg)
getRawContextName
in interface SnmpMsgTranslator
public byte[] getContextName(SnmpMsg msg)
getContextName
in interface SnmpMsgTranslator
public byte[] getAccessContext(SnmpMsg msg)
getAccessContext
in interface SnmpMsgTranslator
public byte[] getEncryptedPdu(SnmpMsg msg)
getEncryptedPdu
in interface SnmpMsgTranslator
public void setContextName(SnmpMsg req, byte[] contextName)
setContextName
in interface SnmpMsgTranslator
public void setContextEngineId(SnmpMsg req, byte[] contextEngineId)
setContextEngineId
in interface SnmpMsgTranslator
|
Open Source build 02 opendmk-1.0-b02 2007.10.01_19:17:46_MEST |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |