ARP packets do need the source IP address in them, as well as the MAC address.

Packets wouldn't even show up in WireShark without the source IP in it.
This commit is contained in:
Grant Limberg 2015-11-21 19:14:59 -08:00
parent ac09c3569a
commit 764dd1c3d9
2 changed files with 9 additions and 7 deletions

View file

@ -129,13 +129,14 @@ public:
* MAC returned is non-null.
*
* @param localMac Local MAC address of host interface
* @param ip IP to look up
* @param localIp Local IP address of host interface
* @param targetIp IP to look up
* @param query Buffer for generated query -- MUST be a minimum of ZT_ARP_BUF_LENGTH in size
* @param queryLen Length of generated query, or set to 0 if no query generated
* @param queryDest Destination of query, or set to null if no query generated
* @return MAC or 0 if no cached entry for this IP
*/
MAC query(const MAC &localMac,uint32_t ip,void *query,unsigned int &queryLen,MAC &queryDest);
MAC query(const MAC &localMac,uint32_t localIp,uint32_t targetIp,void *query,unsigned int &queryLen,MAC &queryDest);
private:
struct _ArpEntry