Jump to content
Sign in to follow this  

How to use the DllCall to adjust the function of use the IP Helper API?

Recommended Posts

GetIpNetTable The function can withdraw originally on board all ARP form item of.Use its method and previous articles in the usage of function is very similar, you also must use it twice, acquire the size of buffer for the first time, but acquire the actual ARP form for the second time.This reflects to shoot the form to point out in several way.Its structure is as follows:

typedef struct _MIB_IPNETTABLE {

DWORD dwNumEntries; //Several size

MIB_IPNETROW table[ANY_SIZE]; //Several oneself


But MIB_IPNETROW Of definition:

typedef struct _MIB_IPNETROW {

DWORD dwIndex; // The network connects the oscular index number

DWORD dwPhysAddrLen; // Physics address length

BYTE bPhysAddr[MAXLEN_PHYSADDR]; // Physics address

DWORD dwAddr; // Address of IP

DWORD dwType; // ARP type


How does this function of the top use the au3 dllcall to adjust to use?

Use the dllcall adjusts the address of Mac that obtains this machine and the long range host with the function of SendArp

DllCall ("iphlpapi.dll", "int", "SendARP","int", $iIP,"int", 0,"ptr", DllStructGetPtr($LMAC),"ptr", DllStructGetPtr($LMACSize))

According to adjust of top with prototype of SendARP of method and underneath according to my comprehension I always at try to adjust to use to other functions of iphlpapi.dll

如 GetIpNetTable,DeleteIpNetEntry,SetIpNetEntry,CreateIpNetEntry The heads were all tired to fry, the bitterness is to can not find the method...

Hope the superior give help


IPAddr DestIP, // Purpose IP address

IPAddr SrcIP, // The source IP address, the eligibility parameter, fills it 0 will not have problems

PULONG pMacAddr, // Physics address of return

PULONG PhyAddrLen // The length of the physics address


Share this post

Link to post
Share on other sites

I've asked people this before and I'm very curious, however they never answer...

- Why did you choose to post your question here in Scripts and Scraps ?

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...