[SNMP4J] How do I send a noAuthNoPriv INFORM?

Frank Fock fock at agentpp.com
Sat Dec 10 23:09:55 CET 2005


Todd,

There are no constants defined for noAuthNoPriv security level,
because it is specified by just setting the auth and priv protocol
OIDs to null.

Best regards,
Frank

Todd Wohlers wrote:

>I am trying to send a noAuthNoPriv INFORM, but haven't
>had much luck.  I have figured out how to send
>authNoPriv and authPriv INFORMs, but not noAuthNoPriv.
>
>Is a noAuthNoPriv INFORM supported by SNMP4J?
>
>I tried the following, but UsmUser throws an exception
>complaining that the passwords must be 8 characters. 
>I didn't see a way to create or add a user name
>without specifying passwords.  I also didn't see any
>classes that predefined the OIDs for noAuth and noPriv
>like AuthMD5.ID and PrivDES.IS, so I defined them
>myself.
>
>        UsmUser user = new UsmUser(new
>OctetString("my-user"),
>                    new OID("1.3.6.1.6.3.10.1.1.1"), 
>//noAuth
>                    null
>                    new OID("1.3.6.1.6.3.10.1.2.1"), 
>//noPriv
>                    null);
>        snmp.getUSM().addUser(new
>OctetString("my-user"), createUser());
>
>        Address targetAddress =
>GenericAddress.parse("udp:localhost/162");
>        UserTarget target = new UserTarget();
>       
>target.setSecurityLevel(SecurityLevel.NOAUTH_NOPRIV);
>        target.setSecurityName(new
>OctetString("my-user")),
>        target.setVersion(SnmpConstants.version3);
>        target.setAddress("1.2.3.4");
>
>Thanks,
>
>Todd
>
>__________________________________________________
>Do You Yahoo!?
>Tired of spam?  Yahoo! Mail has the best spam protection around 
>http://mail.yahoo.com 
>_______________________________________________
>SNMP4J mailing list
>SNMP4J at agentpp.org
>http://lists.agentpp.org/mailman/listinfo/snmp4j
>
>
>  
>


-- 
AGENT++
http://www.agentpp.com
http://www.mibexplorer.com
http://www.mibdesigner.com





More information about the SNMP4J mailing list