This returns the MAC Address of the target_ip and stores it inside the target_mac variable. The first line, inside the spoof(target_ip, spoof_ip) function definition, is where we make use of the get_mac(ip) function that we wrote in step 3. The spoof(target_ip, spoof_ip) accepts two IP Addresses as an input, the target_ip is the IP Address of the machine that we want to fool and the spoof_ip is the IP Address of the machine whose IP Address we’ll use to fool the other (target) machine. Now, there’s a lot going on in this function so let’s break it down line by line so that we understand it completely. The attacker can also relay the requests and responses to and from the victim and the access point without any changes.Īfter this, the communication between the victim and the access point happens through the attacker’s machine just as it is shown in Figure 4.Īt this moment, I assume that you have understood how ARP Spoofing is carried out, so let’s jump on to the coding part. This gives a chance to the attacker to intercept, modify, or stop the data transit. Now, as the only way to access the resources on the internet is through the Access Point itself, the victim’s requests now pass through the attacker’s machine instead of the actual access point. This means that any message intended for the access point is now being sent to the attacker. This fools the victim and the attacker successfully pretends to be the access point. This ARP Response is received by the victim and thinks that this was sent by the Access point, and thus, updates the MAC Address of the access point’s IP Address with the attacker’s MAC Address in its ARP table. Similarly, to pretend as the Access Point in front of the victim, the attacker again uses ARP Response and sends it to the victim machine using the following information in it: With this, any message intended for 10.0.2.15 will now be sent to the attacker’s machine. Due to this, the access point updates the MAC Address of the IP Address 10.0.2.15 to the MAC Address of the attacker in its ARP table and therefore linking the attacker’s machine with a legitimate IP Address. The attacker also sets its own machine’s MAC Address as the Sender MAC Address. This fools the access point in thinking that the ARP Response was sent by the victim (a legitimate device), however, in reality, it was sent by the attacker. This shows that the attacker is forging an ARP Response message by setting the victim’s IP Address as the Sender’s IP Address.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |