We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 32bfd42 commit 66bf723Copy full SHA for 66bf723
snmpsim/grammar/walk.py
@@ -143,9 +143,13 @@ def _hex_string_filter(value):
143
match = re.match(r'^([0-9a-fA-F]{2}(\s+[0-9a-fA-F]{2})*)\s+\[', value)
144
if match:
145
return [int(y, 16) for y in match.group(1).split(' ')]
146
+ elif ' ' in value:
147
+ return [int(y, 16) for y in value.split(' ')]
148
+ else:
149
+ # This could be the format returned by some unknown windows snmpwalk tool:
150
+ # .1.3.6.1.2.1.2.2.1.6.1 = HEX-STRING: 00029929AE3C
151
+ return [int(value[i:i+2], 16) for i in range(0, len(value), 2)]
152
- return [int(y, 16) for y in value.split(' ')]
-
153
@staticmethod
154
def _gauge_filter(value):
155
try:
0 commit comments