[Winpcap-users] Getting Adapters Mac Address

Gianluca Varenni gianluca.varenni at cacetech.com
Wed Apr 12 05:21:28 GMT 2006


  ----- Original Message ----- 
  From: Vasily Borovyak 
  To: winpcap-users at winpcap.org 
  Sent: Tuesday, April 11, 2006 7:08 AM
  Subject: Re: [Winpcap-users] Getting Adapters Mac Address


    PPACKET_OID_DATA    pOidData;
    CHAR *pStr;
    pStr = new CHAR[sizeof(PACKET_OID_DATA)+128];
    ZeroMemory(pStr, sizeof(PACKET_OID_DATA)+128);
    pOidData = (PPACKET_OID_DATA) pStr;
    pOidData->Oid = OID_802_3_CURRENT_ADDRESS;
    pOidData->Length = 6;
    result = PacketRequest(lpAdapter, FALSE, pOidData);
    /* pOidData->Data[0], pOidData->Data[1], ...- this is MAC*/


  I don't know if it work with current 3.1 version.

Yes, it still works.

Have a nice day
GV



Bhuvanes V wrote: 
    Hi All,
               Can anyone please guide me how to get the mac address of
    Adapters connected in a local machine. I know we have APIs to get the 
    device list.
    1) What is the API to get Mac Addresses of those device list? 
    2) Usage of those APIs.

    Thanks in Advance :)

    Bhuvan



----------------------------------------------------------------------------
_______________________________________________
Winpcap-users mailing list
Winpcap-users at winpcap.org
https://www.winpcap.org/mailman/listinfo/winpcap-users
  

-- 
Best regards. Vasily Borovyak <vbor at isd.dp.ua>

------------------------------------------------------------------------------


  _______________________________________________
  Winpcap-users mailing list
  Winpcap-users at winpcap.org
  https://www.winpcap.org/mailman/listinfo/winpcap-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.winpcap.org/pipermail/winpcap-users/attachments/20060411/314c08f2/attachment.htm


More information about the Winpcap-users mailing list