Ronald Braswell | 30 Jan 14:23 2016
Picon

D-TLS Transport Mapping

Hi,

Has anyone provided a D-TLS Transport Mapping?

Ron
_______________________________________________
SNMP4J mailing list
SNMP4J <at> agentpp.org
https://oosnmp.net/mailman/listinfo/snmp4j
nino fattore | 29 Jan 19:37 2016
Picon

Weblogic and snmp4j

I have done a little prototype of a stand alone snmp4j agent.it woks as stand alone. I can get snmp queries and
respond to them 
and also sending traps.I do not know how to use my prototype in a weblogic environment.Anyone could help me?Thanks,Nino
_______________________________________________
SNMP4J mailing list
SNMP4J <at> agentpp.org
https://oosnmp.net/mailman/listinfo/snmp4j
Steffen Brüntjen | 22 Jan 11:27 2016
Picon

System.out.println() in TableUtils

Hi!

There are two System.out.println() statements in TableUtils. They were added in Version 4.3.0 and appear
to be debug statements. Shouldn't they be turned to log statements?

(I hope the mailing list is the right place for this and I'm sorry if not!) 

Best regards and thanks
Steffen Brüntjen

_______________________________________________
SNMP4J mailing list
SNMP4J <at> agentpp.org
https://oosnmp.net/mailman/listinfo/snmp4j
Michał Steiner | 22 Jan 10:05 2016
Picon

Statistics about number of retries and snmp request times

Hi,

I'm looking for  a way to gather detailed statistics about SNMP
communication (number of retries and exact times).
SNMP4j supports  re-sending request if response didn't come within timeout
limit which is very useful feature but it can mask some issues existing in
the network. For example when there is a lot of retries because we are
loosing some pockets, it will not be obviously visible. To find out how
many retries was required you need to measure time between send request and
getting response then depending on your TimeOutModel you need make some
calculations.

This approach is not very useful because:
- calculations may not be accurate  because we measure time of whole
message handling not sending single PDU
- you will need to modify all places in your code where you calling SNMP4j
send method. It could be many of them.

Much better would be have possibility to get such info from Snmp class. For
example you could add request  listener to the Snmp, and  in
 PendingRequest#responseReceived() method notify it about received
response, something like this:

public void responseReceived() {

requestListener.onResponseReceived(
target.getAddress(), //ip address
pdu.getType(),  //get get-next etc
pdu.size(),  //how many oids
(System.nanoTime() - startedInNano) /
(Continue reading)

Bruno Filipe Basilio | 19 Jan 01:18 2016
Picon

Problems in DefaultTcpTransportMapping when receiving fragmented header


Hi,

Thank you for all your work in snmp4j and related.
We are using snmp4j to handle NTCIP-PMPP protocol which is based in SNMP over TCP.

More details about NTCIP-PMPP specification, see:
http://www.ntcip.org/library/documents/pdf/pmpp01.pdf


The problem is that using upstream DefaultTcpTransportMapping some data is discarded when the message
received has a fragmented header, resulting in incoherent message.
Some changes were made to work around the problem, but as you can see bellow, it isn't the prettiest since we
hadn't many experience coding in snmp4j.
You can see an example of the data exchange and the test code we have used to replicate the problem using only
snmp4j example code.

All feedback is appreciated, but maybe you can suggest a better solution and add it in upstream snmp4j.

Here follows an example of the data exchanged and the fragmented response.
*Sent data*
7E 05 13 C1 30 31 02 01 00 04 06 50 75 62 6C 69 63 A0 24 02 04 28 BA 92 8B 02 01 00 02 01 00 30 16 30 14 06 10 2B 06 01 04 01 89 36 04
02 03 05 08 01 03 05 01 05 00 AE 11 7E

*Received data fragments*
1)
7E 05 13

2)
C1 30 70 02 01 00 04 06 50 75 62 6C 69 63 A2 63 02 04 28 BA 92 8B 02 01 00 02 01 00 30 55 30 53 06 10 2B 06 01 04 01 89 36 04 02 03 05
08 01 03 05 01 04 3F 44 52 49 56 45 5B 6E 6C 5D 57 49 54 48 5B 6E 6C 5D 43 41 52 45 5B 6E 70 5D 54 48 41 4E 4B 20 59 4F 55 5B
(Continue reading)

Frank Fock | 31 Dec 12:12 2015

SNMP4J 2.4.1 and SNMP4J-Agent 2.4.1 Released


Hi,

Today, SNMP4J version 2.4.1 and SNMP4J-Agent 2.4.1 with support for
RFC 7630 (SHA-2 authentication) have been released.

If you have already downloaded SNMP4J 2.4.0, please update it with 2.4.1 
because the
SHA-2 authentication of 2.4.0 uses an invalid MAC/key length!

MIB Explorer 4.1 will follow mid January and will then also provide
SHA-2 support.

Because this is the last release of AGENT++ products for 2015, I would 
like to
thank you cordially for the confidence you have shown us and for
using SNMP4J APIs and wish you a peaceful and Happy New Year!

Frank Fock

RELEASE NOTES

SNMP4J 2.4.1

* Fixed: SHA-2 authentication protocols used wrong MAC and key lengths 
(were switched accidentally
   in version 2.4.0.
* Fixed: Compilation warning in TransportMappings due to generic 
refactorings in version 2.4.0.
* Added [SFJ-112]: Added SHA-2 (SHA-224,-256,-384,-512) support to USM 
(Continue reading)

Daniel Frank | 14 Dec 13:31 2015

Re: Empty SNMP Packets send to Agent

Hello Jochen,

Thank you for your answer. In the meanwhile I found out what the problem
was. I sent the request to the management interface of the network
component. The running snmp agent got the request but answered via another
network interface so I didn't get the response.

Now I have another problem. I do some set requests and the values are set
successfully, but the response parameter of the ResponseEvent is always
null.

What could be the problem there? In Wireshark I can see the response with
all necessary 

informations about the successful action.

Best regards,

Daniel

------------- DNWS Payment & Services Ltd. ------------

Daniel Frank      -- Dipl. Inf. (FH) –

Dachauerstr.15

85764 Oberschleißheim

Email:  <mailto:d.frank <at> dnws-payment.com> d.frank <at> dnws-payment.com

(Continue reading)

nino fattore | 7 Dec 23:15 2015
Picon

to add a trap user recipient

Please, I 'd like to know what to do after an SNMP4j agent is started to add a new V3 or V2c trap recipient.Is it
enough to add a new row in the SnmpTargetMib with new user information? I mean something similar to what I
see in the TestAgent in the method addNotificationTargets()?Thanks,Nino
_______________________________________________
SNMP4J mailing list
SNMP4J <at> agentpp.org
https://oosnmp.net/mailman/listinfo/snmp4j
Réda BENKIRANE | 7 Dec 10:52 2015
Picon

Can you suggest me how to make a Table in which we can add rows dynamically?

Hi,
I am working on an SNMP4J agent and I want this agent to be able to create a conceptual table. This conceptual
table can have 0 rows or as much rows as I need. I want to add rows and fill those rows with values not from the
agent but from a SNMP manager (client) at runtime (i.e. : The Manager sends a SET request to the agent and as a
consequence of the set, a new row is added).
I managed to find a code with a class that contains methods to create, initialize and build an MOTable with
snmp4j package. However, I don't know how to add rows to this table.
Can you suggest me how can I modify the following code ? Or what do I need to add in the agent or in the SNMP4J
manager to do what I want ?
Here is the MOTableBuilder.java class : 
import java.util.ArrayList;import java.util.List;
import org.snmp4j.agent.MOAccess;import org.snmp4j.agent.mo.DefaultMOMutableRow2PC;import
org.snmp4j.agent.mo.DefaultMOTable;import org.snmp4j.agent.mo.MOColumn;import
org.snmp4j.agent.mo.MOMutableTableModel;import org.snmp4j.agent.mo.MOTable;import
org.snmp4j.agent.mo.MOTableIndex;import org.snmp4j.agent.mo.MOTableSubIndex;import
org.snmp4j.smi.OID;import org.snmp4j.smi.SMIConstants;import org.snmp4j.smi.Variable;

/** * <p>Utility class for adding dynamic data into an { <at> link MOTable}</p> *  *  <pre><code> MOTableBuilder
builder = new MOTableBuilder(new
OID(".1.3.6.1.2.1.2.2.1"))	.addColumnType(SMIConstants.SYNTAX_INTEGER,MOAccessImpl.ACCESS_READ_ONLY)	.addColumnType(SMIConstants.SYNTAX_OCTET_STRING,MOAccessImpl.ACCESS_READ_ONLY);	for(MyObject
o: myObjects) {			builder.addRowValue(new Integer32(o.getId()))		.addRowValue(new
OctetString(o.getName()));	}MOTable table = builder.build(); </code><pre>  *  <at> author johanrask *
*/public class MOTableBuilder {
	private MOTableSubIndex[] subIndexes = new MOTableSubIndex[] { new
MOTableSubIndex(			SMIConstants.SYNTAX_INTEGER) };	private MOTableIndex indexDef = new
MOTableIndex(subIndexes, false);
	private final List<MOColumn> columns = new ArrayList<MOColumn>();	private final List<Variable[]>
tableRows = new ArrayList<Variable[]>();	private int currentRow = 0;	private int currentCol = 0;
	private OID tableRootOid;
	//private int colTypeCnt = 0;
(Continue reading)

Daniel Frank | 4 Dec 06:28 2015

Empty SNMP Packets send to Agent

Hi,

I’m trying to create a SNMP manager which retrieves informations from a
network device via

snmp v3. Unfortunately the sent SNMP packets are empty. I would appreciate
your help to find

my mistake.

The Manager code looks like this:

public class SNMPTest {

       public static void main(String[] args) throws Exception {

             LogFactory.setLogFactory(new Log4jLogFactory());

             Snmp snmp = null;

        try {

             String Username = "ProvisionTest";

            PDU pdu = new ScopedPDU();

            USM usm = new USM(SecurityProtocols.getInstance(), new
OctetString(MPv3.createLocalEngineID()), 0);

            SecurityModels.getInstance().addSecurityModel(usm);
(Continue reading)

Michał Steiner | 2 Dec 09:19 2015
Picon

TableUtils - more efficient fetching of sparse tables

Hi,

I've noticed that getTable method in org.snmp4j.util.TableUtils could be
more efficient for sparse tables.

Consider table with 3 columns and 3 rows, but in first column there is a
lot of empty cells:

 Column1           Column2        Column3
 value-1-1         value-2-1     value-3-1
 <empty>           value-2-2     value-3-2
 <empty>           value-2-3     value-3-3

Today implementation works more or less like this:

get-next   Column1      Column2       Column3
response   value-1-1    value-2-1     value-3-1

get-next   value-1-1      value-2-1     value-3-1
response   value-2-1      value-2-2     value-3-2

get-next   value-1-1       value-2-2     value-3-2
response   value-2-1       value-2-3     value-3-3

get-next   value-1-1      value-2-3     value-3-3
response   value-2-1      value-3-3     value from next table

As you can see  request for    value-1-1  is done 3 times and only first
one makes sense.
This is  an issue for large tables (lot of columns and rows) with many
(Continue reading)


Gmane