[SNMP4J] ResponseEvent in case of wrong USM credentials

Girish Venkatasubramanian girishvs at gmail.com
Tue Feb 5 21:30:36 CET 2019


Hello
I am trying to understand if failure of an SNMP GET due to incorrect
username/auth/priv can be distinguished from failure because of other
causes.

I am using the code as shown in the example
https://www.snmp4j.org/doc/org/snmp4j/Snmp.html

First, I tried with the correct userName/auth/priv keys and the
ResponseEvent was as expected i.e. with a non-null responsePDU containing
the value of the polled OID.

Then, I tried with an incorrect userName. The responsePDU was null, which
is exactly the same when I poll a device which is known to be down.

Is there a way to identify that the polling failed due to incorrect
credentials ? Any pointers to documentation/examples will be
much appreciated.

Thanks


More information about the SNMP4J mailing list