[SNMP4J] TestAgent and SNMPv3

Jochen Katz katz at agentpp.com
Tue Dec 19 16:42:39 CET 2006


Hi,

>> the agent. Are you using unique engine ids for agent and manager?
> 
> To be honest, I don't know.  I'm just trying to query the TestAgent bundled
> with snmp4j-agent using the snmp4j-tool.  From `snmp4j_usage.txt', I believe

until now there seems to be no command line switch to set the local
engine id, so both (agent and manager) generate it from the local host
and this results in identical ids. Change the following line in
SnmpRequest.java:

     if (version == SnmpConstants.version3) {
       USM usm = new USM(SecurityProtocols.getInstance(),
===>                    new OctetString(MPv3.createLocalEngineID(new
OctetString("MyManager"))), 0);
       SecurityModels.getInstance().addSecurityModel(usm);
       addUsmUser(snmp);
     }

Regards,
  Jochen



More information about the SNMP4J mailing list