in my company we are using Snmp4J(-Agent) 2.6.3 for our integration tests. Everything is working fine with a Snmp V2 agent, but we have a particular case in V3 we would like to test and where getting something unexpected. In short after a while we change on the fly the access credentials to a Snmp V3 agent to test the behavior of our manager. In this case we are expecting to receive a PDU response type with an SNMP authentication error, but the agent throws an exception instead:
1164 [main] DEBUG org.snmp4j.security.USM - USM.getUser - User 'snmptest_SHA_AES256' unknown org.snmp4j.MessageException: Message processing model 3 returned error: Unknown security name 1164 [main] DEBUG org.snmp4j.security.USM - Security name not found for engineID=70:75:62:6c:69:63, securityName=73:6e:6d:70:74:65:73:74:5f:53:48:41:5f:41:45:53:32:35:36
The trick to change the credentials consists in 4 steps: unregister all the managed objects, close the server, register the managed objects again and restart:
With Snmp V2 this works fine, but Snmp V3 has this problem.
What should I check?
Thanks for your great product!