lextudio / sharpsnmplib

Sharp SNMP Library- Open Source SNMP for .NET
https://sharpsnmp.com
MIT License
356 stars 152 forks source link

Convert OctetString to Readable Decimal Value #376

Open lextudio-support opened 4 hours ago

lextudio-support commented 4 hours ago

Hi,

I am struggling to convert an OctetString Value to readable decimal value. For example, I receive
(Raw Value [OctetString]: HEX: 00 80 00 00 ) over SNMP using SharpSnmpLib and don't know how to convert it to decimal value 9.

When I use an standard MIB Browser Tool I do see the translation of 00 80 00 00 to 9, but just don't get it how its done. I appreciate if someone can help me to solve this problem.

Best regards

Yeasin Habib

Original Reported Date: 2013-11-06T00:55:56.44-08:00 Original CodePlex Discussion Thread ID: 466226

lextudio-support commented 4 hours ago

Copied from CodePlex without authors:

Hi,

The value itself is impossible to convert from the raw bytes to the value you want.

The MIB Browser tool you use, can only do the conversion when it loads the corresponding MIB documents. #SNMP Pro is going to support that, but the open source edition of #SNMP won't.

Regards,

Lex

Original Posted Date: 2013-11-06T19:29:16.163-08:00