We can create fake Wi-Fi access points by injecting beacon frames with Scapy.
Fake access points with Scapy
How to do it...
Let's try creating a fake SSID with the following steps:
- Create a new fake-access-point.py file and open it in the editor.
- Load the required modules for the script:
from scapy.all import * import random
Here we use the scapy and random modules for creating random MAC IDs
- Then define the access point name and the interface to broadcast:
ssid = "fakeap" iface = "en0"
- Now we can craft the packet with the beacon frame as follows:
dot11 = Dot11(type=0, subtype=8, addr1='ff:ff:ff:ff:ff:ff', addr2=str(RandMAC()), addr3=str(RandMAC())) dot11beacon = Dot11Beacon(cap...