Hi, 
My agent is a proxy agent.
I am little bit confused that the value i am getting from the agent is
in Hex format after setting this value in snmp_set_var_typed_value  the
result is in ASCII format.

snmp_set_var_typed_value(var, ASN_OCTET_STR,
                        (u_char *) cVal,
                         strlen(cVal)*sizeof(u_char)
                         );

There are two entries one in RFC1213 and another one in BRIDGE-MIB
1.ipNetToMediaPhysAddress  syntax is PhyAddress
2.dot1dBaseBridgeAddress   syntax is MacAddress


snmpget or snmpgetnext on the first entry is giving the result in ASCII
format but snmpget or snmpgetnext on the second entry is giving the
result in the Hex format.

Another important thing is in both the cases the cVal contains the Hex
value of the result which i got from the agent in the card.

The version I am using is net-snmp 5.1.2 my agent is a proxy agent
The version of the agent in the card is UCD-snmp 4.2.3


On Fri, 2004-11-05 at 14:40, Thomas Anders wrote:
> Robert Story (Users) wrote:
> > SB> IP-MIB::ipNetToMediaPhysAddress.33.10.0.25.1 = STRING:
> > SB> 30:30:20:30:32:20:41:35:20:32:43:20:31:32:20:37:45
> > 
> > Hmm.. that's obviously the ASCII version of the address. It should be raw 
> > hex.
> > What this query to a net-snmp agent, or another device? 
> 
> FWIW, in an Net-SNMP-5.1.2-talking-to-Net-SNMP-5.1.2 environment on Linux
> this works fine and displays a HEX-STRING as expected.
> 
> 
> +Thomas



-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
_______________________________________________
Net-snmp-users mailing list
[EMAIL PROTECTED]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to