WiFi Exploitation Framework (WEF)

repository·main·Indexed 25 days ago

https://github.com/d3ext/wef

A tool for security researchers and penetration testers to analyze and exploit vulnerabilities in WPA/WPA2, WPS, and WEP networks. It supports 2.4 GHz and 5 GHz frequencies and provides automated and manual attack modes, including DoS, WPS Pixie Dust, WEP ARP Replay, Rogue AP/Evil Twin attacks, and WPA3 dictionary attacks via the Wacker class.

Tokens
1.9K
Snippets
8
Records
17
Agent score
84%

What's inside WEF

  1. Overview of supported WiFi attacks in WEF

    main

    WEF supports a wide range of automated and manual attack techniques across different protocols:

    • DoS (optional handshake capture): Deauthentication/Disassociation, WIDS Confusion, Authentication, Beacon Flood, and TKIP (Michael Shutdown Exploitation).
    • WPS: Pixie Dust, PIN Bruteforce, and Null Pin attacks.
    • WEP: ARP Replay, HIRTE, Caffe Latte, and Fake Authentication attacks.
    • Handshake: WPA handshake, PMKID handshake, and Pwnagotchi mode.
    • Rogue AP: Evil Twin attacks (including BSSID spoofing, Karma mode, Enterprise WPA support, and Deauth support).
    • Other: Automatic attack mode (Auto PWN) and WPA3 dictionary attacks.
  2. Split a network interface into multiple virtual interfaces

    main

    If you are using a single adapter for both hosting the AP and performing attacks in monitor mode, you must split the interface. Replace wlan0 with your actual interface name and f2:11:56:8c:1a:68 with your desired MAC address.

    interface="wlan0"
    rand_mac="f2:11:56:8c:1a:68"
    
    ip link set "$interface" down
    iw "$interface" set monitor control
    ip link set "$interface" up
    
    iw "$interface" interface add "mon${interface}" type monitor addr ${rand_mac}
  3. Install the WiFi Exploitation Framework (WEF)

    main

    To install WEF, clone the repository and run the wef script. This must be performed with root privileges.

    Note: For more detailed information, refer to the official Installation Wiki.

    # As root
    git clone --depth 1 https://github.com/D3Ext/WEF
    cd WEF
    bash wef
  4. Manage virtual interfaces and monitor mode with create_vif.sh and restore_vif.sh

    main
    To enable monitor mode on an interface, use create_vif.sh to create a virtual interface (VIF). To revert these changes and set the interface back to managed mode, use restore_vif.sh.
  5. Revert interface splitting changes

    main

    To remove the virtual monitor interface and return your primary interface to managed mode, use the following commands (replace wlan0 with your interface name):

    interface="wlan0"
    iw "mon${interface}" del
    
    ifconfig "$interface" down
    iwconfig "$interface" mode managed
    ifconfig "$interface" up
  6. Check if network adapter supports Virtual Interfaces (VIF)

    main

    Before splitting a single network card into multiple interfaces (one for the AP and one for monitor mode), verify that your adapter supports Virtual Interfaces (VIF) by checking for AP/VLAN in the supported interface modes.

    iw list | grep "Supported interface modes" -A 8 | grep "AP/VLAN"
  7. Launch a fake WEP Access Point

    main

    To launch the WEP AP, you need hostapd-wpe and dnsmasq. You must first configure hostapd.conf and dnsmasq.conf specifically for your environment.

    1. Start the access point:
    hostapd-wpe hostapd.conf
    1. In a separate terminal, start the DNS/DHCP service:
    dnsmasq -C dnsmasq.conf
    hostapd-wpe hostapd.conf
    dnsmasq -C dnsmasq.conf
  8. Generate WiFi Enterprise hostapd configs with apd_launchpad.py

    main
    The apd_launchpad.py Python script generates hostapd configuration files specifically for WiFi Enterprise networks. It includes the necessary certificates, keys, and other required files, making it useful for EvilTwin attacks against Enterprise networks.