문제

I'm trying to send OctetString in SNMP trap. I'm using SNMP4J to do so.

The problem is that I need to put colon (':') in my string. Since the OctetString use colon as a separator my string is cut in the middle (where the colon is).

Is there a way to escape my message?

Thanks

도움이 되었습니까?

해결책

You may capture network packets to see at which spot the packet becomes corrupt. OCTET STRING type does not use colon as separator, and this is according to SNMP protocols.

다른 팁

With SNMP4J's OctetString you do not have to put a colon in your string. This is only the case when you create an OctetString instance form a HEX string using the default format. If you have an UTF-8 string, simply use new OctetString("myString").

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top