arp_mitm function

This commit is contained in:
Dimitri Lozeve 2016-06-04 09:54:56 +02:00
parent 0c33590349
commit 0d66824635
2 changed files with 80 additions and 0 deletions

15
arp.h
View file

@ -75,4 +75,19 @@ int listen_arp_frame(int sockfd, struct ether_arp *result);
int arp_scan(int sockfd, int ifindex, struct sockaddr_in *ipaddr, unsigned char *macaddr, struct sockaddr_in *netmask);
/* ARP man-in-the-middle attack.
sockfd: socket file descriptor
ifindex: index of the interface
ipaddr: local IP address
macaddr: local hardware address
target1_ip: IP address of the first target
target2_ip: IP address of the second target
Never returns, has to be killed by the user.
*/
int arp_mitm(int sockfd, int ifindex, struct sockaddr_in *ipaddr, unsigned char *macaddr, struct in_addr *target1_ip, struct in_addr *target2_ip);
#endif /* ARP_H_ */