Open arezazadeh opened 3 years ago
You shouldn't use str(varBind[1])
as the returned data are raw bytes for adapter physical address. prettyPrint
might be used to print it out or you manually process the bytes. Converting to str
without proper encoding only leads to useless output.
The actual definition of the physcal address is as below (from RFC1213-MIB or other valid source),
PhysAddress ::=
OCTET STRING
-- This data type is used to model media addresses. For many
-- types of media, this will be in a binary representation.
-- For example, an ethernet address would be represented as
-- a string of 6 octets.
ipNetToMediaPhysAddress OBJECT-TYPE
SYNTAX PhysAddress
ACCESS read-write
STATUS mandatory
DESCRIPTION
"The media-dependent `physical' address."
::= { ipNetToMediaEntry 2 }
Hi All,
I am using cmdBulk function to pull arp table, but it returns below
i am not sure what format is the MAC address. can anyone help me on this? my code is below