You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
I experienced the following issue. When I send this command:
snmpset -t 5 -v 3 -m NTCIP1218-v01 -l authPriv -u snmpPrivateTestUser -a SHA1 -A passWord2024Priv -x AES128 -X passWord2024Priv udp:192.168.11.97:161 rsuXmitMsgFwdingPsid.1 x 0020 rsuXmitMsgFwdingDestIpAddr.1 s "192.168.9.178" rsuXmitMsgFwdingDestPort.1 i 60001 rsuXmitMsgFwdingProtocol.1 i 2 rsuXmitMsgFwdingDeliveryStart.1 x 07E5031916010000 rsuXmitMsgFwdingDeliveryStop.1 x 07EE031916010000 rsuXmitMsgFwdingSecure.1 i 0 rsuXmitMsgFwdingStatus.1 i 4
Everything works fine, the following lines are received by my pass persist script:
set
.1.3.6.1.4.1.1206.4.2.18.20.2.1.2.1
octet "00 20"
But when I use 20 instead of 0020:
snmpset -t 5 -v 3 -m NTCIP1218-v01 -l authPriv -u snmpPrivateTestUser -a SHA1 -A passWord2024Priv -x AES128 -X passWord2024Priv udp:192.168.11.97:161 rsuXmitMsgFwdingPsid.1 x 20 rsuXmitMsgFwdingDestIpAddr.1 s "192.168.9.178" rsuXmitMsgFwdingDestPort.1 i 60001 rsuXmitMsgFwdingProtocol.1 i 2 rsuXmitMsgFwdingDeliveryStart.1 x 07E5031916010000 rsuXmitMsgFwdingDeliveryStop.1 x 07EE031916010000 rsuXmitMsgFwdingSecure.1 i 0 rsuXmitMsgFwdingStatus.1 i 4
Something goes wrong, the following lines are received by my pass persist script.
set
.1.3.6.1.4.1.1206.4.2.18.20.2.1.2.1
string " "
The root cause is that 20 is considered hexadecimal and it is converted to ASCII by net-snmp. ASCII 32 is the space character.
The text was updated successfully, but these errors were encountered:
The pass infrastructure does not read the MIB to know the types of objects; it just passes along what was received on the wire. As you identified, there's ambiguity when the underlying type is an OCTET STRING, and so, net-snmp applies a heuristic: if the input is composed of all printable characters, then it uses string, otherwise it uses octet, to pass the data to the subprocess.
A pass-persist script should be prepared to receive either representation.
Hello,
I experienced the following issue. When I send this command:
snmpset -t 5 -v 3 -m NTCIP1218-v01 -l authPriv -u snmpPrivateTestUser -a SHA1 -A passWord2024Priv -x AES128 -X passWord2024Priv udp:192.168.11.97:161 rsuXmitMsgFwdingPsid.1 x 0020 rsuXmitMsgFwdingDestIpAddr.1 s "192.168.9.178" rsuXmitMsgFwdingDestPort.1 i 60001 rsuXmitMsgFwdingProtocol.1 i 2 rsuXmitMsgFwdingDeliveryStart.1 x 07E5031916010000 rsuXmitMsgFwdingDeliveryStop.1 x 07EE031916010000 rsuXmitMsgFwdingSecure.1 i 0 rsuXmitMsgFwdingStatus.1 i 4
Everything works fine, the following lines are received by my pass persist script:
set
.1.3.6.1.4.1.1206.4.2.18.20.2.1.2.1
octet "00 20"
But when I use 20 instead of 0020:
snmpset -t 5 -v 3 -m NTCIP1218-v01 -l authPriv -u snmpPrivateTestUser -a SHA1 -A passWord2024Priv -x AES128 -X passWord2024Priv udp:192.168.11.97:161 rsuXmitMsgFwdingPsid.1 x 20 rsuXmitMsgFwdingDestIpAddr.1 s "192.168.9.178" rsuXmitMsgFwdingDestPort.1 i 60001 rsuXmitMsgFwdingProtocol.1 i 2 rsuXmitMsgFwdingDeliveryStart.1 x 07E5031916010000 rsuXmitMsgFwdingDeliveryStop.1 x 07EE031916010000 rsuXmitMsgFwdingSecure.1 i 0 rsuXmitMsgFwdingStatus.1 i 4
Something goes wrong, the following lines are received by my pass persist script.
set
.1.3.6.1.4.1.1206.4.2.18.20.2.1.2.1
string " "
The root cause is that 20 is considered hexadecimal and it is converted to ASCII by net-snmp. ASCII 32 is the space character.
The text was updated successfully, but these errors were encountered: