Hi Steve,
Ahh, brilliant!
>>the SnmpOctetString class in the JoeSnmp implementation is treating the IP Address
>String as a list of bytes, so what I get in the trap is the ascii values of my String
>IP Address.<<
Yes, this had been reported before, but the report was not specific enough for me to
reproduce it here. Interestingly, the bug seems to be variable, depending on the NMS
software one uses to receive the trap. Some receivers pick up the JoeSNMP string
okay, and some don't.
The fix is something like this, to replace the current line 257:
<code>
InetAddress tmpAddress = InetAddress.getByName(this.localIPAddress);
addr.setString(tmpAddress.getAddress());
</code>
This stuffs a properly filled byte array into the SnmpOctetString, and should do the
trick without resorting to a "roll-your-own" parser.
I'll release a fixed version of the appender in the next couple of days. Thanks for
the bug report!
Cheers,
Mark