up:: [[Deauthentication attack]] # How to Exploit Deauthentication Attacks A [[Deauthentication attack]] is a type of Denial of Service (DoS) attack where wireless devices are forcibly disconnected from a network by constantly sending deauthentication frames from the router to the client. While this attack can be instrumental for network testing and educational purposes, it's illegal to perform on networks without explicit permission. Ensure you have the appropriate authorization before proceeding with the following steps on a live network. ### Prerequisites 1. **[[Kali Linux]]**: Installed and updated. 2. **Wireless Network Adapter**: Supports [[Change MAC from Managed to Monitor Mode|monitor mode]] and packet injection. 3. **[[Aireplay-ng]]**: Part of the [[Aircrack-ng]] suite, usually pre-installed in [[Kali Linux]]. ### Steps to Perform a Deauthentication Attack #### Step 1: Install Aircrack-ng Ensure [[Aircrack-ng]] is installed. You can install it via terminal if it's not already installed: ```bash sudo apt-get update sudo apt-get install aircrack-ng ``` #### Step 2: Enable Monitor Mode First, identify your wireless card (usually `wlan0` or `wlan1`): ```bash iwconfig ``` Then, enable monitor mode on the wireless card: ```bash sudo airmon-ng start wlan0 ``` The interface will typically be renamed to something like `wlan0mon` or `mon0`. #### Step 3: Find the Target Network Use `airodump-ng` to list all available WiFi networks: ```bash sudo airodump-ng wlan0mon ``` Note the BSSID (MAC address of the access point) and the channel (CH) of the network you want to target. #### Step 4: Target the Network for the Attack Focus on the specific network by using `airodump-ng` on its channel and BSSID: ```bash sudo airodump-ng --bssid [Target BSSID] -c [Channel] wlan0mon ``` Keep this terminal open as it needs to capture the handshakes. #### Step 5: Deauthenticate a Client Open a new terminal window and use `aireplay-ng` to send deauthentication packets: ```bash sudo aireplay-ng --deauth 0 -a [Target BSSID] -c [Client MAC Address] wlan0mon ``` Here, `-a [Target BSSID]` is the MAC address of the target network, `-c [Client MAC Address]` is the MAC address of the client to deauthenticate (optional, if not specified, it will deauth all clients on the network), and `0` in `--deauth 0` means an infinite number of deauth packets will be sent. If you don't specify a client MAC address, it will deauthenticate all clients connected to the network, causing them all to disconnect. ### Important Considerations - **Legal Implications**: Performing a [[deauthentication attack]] on a network without permission is illegal and unethical. - **Security Awareness**: Understanding how deauthentication works is crucial for securing wireless networks against such attacks. - **Protecting Networks**: Use encrypted protocols like WPA3, regularly update firmware, and employ MAC filtering to mitigate the risk of [[Deauthentication attack|deauthentication attacks]]. Always use this knowledge responsibly to test networks you own or have explicit permission to test. This guide is intended for educational purposes only.