This script is a tool designed for replaying 802.11 wireless packets from a provided PCAP file.
It utilizes the Scapy library and requires a wireless card that supports promiscuous mode.
- Reads packets from a PCAP file.
- Allows the user to select a wireless interface and channel.
- Sends 802.11 packets contain in the pcap on the selected channel with a customizable delay between each packet.
- Python 3.x
- Scapy Library
Install it usingpip install scapy
. - Linux Environment
The script requires Linux with tools likeiwconfig
andairmon-ng
. - Root Privileges
The script must be run as root (e.g., usingsudo
).
Ensure your wireless interface is in promiscuous mode:
sudo airmon-ng start wlan0
Replace wlan0
with the name of your wireless interface.
Execute the script with root privileges:
sudo python3 replay_packets.py
- Provide the path to the PCAP file containing the packets to replay.
- Select the network interface to use for packet transmission.
- Specify the channel number for the wireless interface.
- Define the delay between packet transmissions (in seconds).
Enter the path to the PCAP file: captured_packets.pcap
Available network interfaces:
1. wlan0
2. eth0
Enter the number corresponding to the network interface (e.g., 1): 1
Enter the channel number to set (e.g., 6): 6
Enter the delay (in seconds) between each packet (e.g., 0.1): 0.2
Packet replay completed.
- Check for Root Privileges
The script ensures it is run withsudo
. - Load PCAP File
It attempts to read the provided PCAP file. If the file does not exist, it exits with an error. - Select Network Interface
Lists available interfaces and lets the user select one for packet transmission. - Set Wireless Channel
Usesiwconfig
to configure the channel for the selected interface. - Replay Packets
Replays 802.11 packets on the selected channel with a user-defined delay.
This project is licensed under the MIT License. See the LICENSE
file for more details.
This tool is for educational and ethical purposes only.
Unauthorized use of this script to interfere with wireless networks is illegal and unethical. Always ensure you have proper authorization before conducting any wireless testing.
Developed by 7h30th3r0n3.