Re: [SNMP4J] Set USM security parameters per request

2017-02-01 Thread Frank Fock
Hi Ron,

You can remove the time information for a specific target by calling
UsmTimeTable.remove(engineID).

You can get the engineID by calling MPv3.getEngineID(Address).

Best regards,
Frank

> On 2 Feb 2017, at 00:01, Ronald Braswell  wrote:
> 
> I have code which calls USM.removeEngineTime(engineID) that I use to enable
> the re-discovery process again for a device with which my SNMP manager has
> lost communications.   This works for several devices.   But one device has
> problems.
> 
> If I call USM.removeEngineTime(engineID) for this device before it comes
> back up, when it does come back up the requests go out with a reboots
> parameter of 0 but with a time parameter > 0 indicating the time since the
> call to removeEngineTime.   The device does not respond to this.  If I do
> another removeEngineTime after the device comes back up the time security
> parameter is 0 as well as the reboots parameter and it works.   The problem
> is that I don't know when the device comes back up since it does not send a
> trap or notification indicating this.   When I call my function
> (resetUsmUser(securityName))  it resets all TimeTableEntries with
> securityName even if the entry is not the localized one for the device
> having the problem.   I have a number of like devices using the same USM
> security name and passphrases.   I would prefer the ones still up not have
> to go through the discovery process as well.I would like to be able to
> set the reboots, time for the request to 0 just for a particular request
> going to the particular device.
> 
> Is there a way to do this with SNMP4J?Is there a away in the SNMP4J API
> to tell which localized UserTableEntry belongs to a particular device (USM
> discovery process enabled)?
> 
> Ron

___
SNMP4J mailing list
SNMP4J@agentpp.org
https://oosnmp.net/mailman/listinfo/snmp4j


[SNMP4J] Set USM security parameters per request

2017-02-01 Thread Ronald Braswell
I have code which calls USM.removeEngineTime(engineID) that I use to enable
the re-discovery process again for a device with which my SNMP manager has
lost communications.   This works for several devices.   But one device has
problems.

If I call USM.removeEngineTime(engineID) for this device before it comes
back up, when it does come back up the requests go out with a reboots
parameter of 0 but with a time parameter > 0 indicating the time since the
call to removeEngineTime.   The device does not respond to this.  If I do
another removeEngineTime after the device comes back up the time security
parameter is 0 as well as the reboots parameter and it works.   The problem
is that I don't know when the device comes back up since it does not send a
trap or notification indicating this.   When I call my function
(resetUsmUser(securityName))  it resets all TimeTableEntries with
securityName even if the entry is not the localized one for the device
having the problem.   I have a number of like devices using the same USM
security name and passphrases.   I would prefer the ones still up not have
to go through the discovery process as well.I would like to be able to
set the reboots, time for the request to 0 just for a particular request
going to the particular device.

Is there a way to do this with SNMP4J?Is there a away in the SNMP4J API
to tell which localized UserTableEntry belongs to a particular device (USM
discovery process enabled)?

Ron
___
SNMP4J mailing list
SNMP4J@agentpp.org
https://oosnmp.net/mailman/listinfo/snmp4j