Fix bug when airodump output for clients is unexpected/unparsable
This commit is contained in:
@@ -195,7 +195,7 @@ class Airodump(object):
|
||||
# The current row corresponds to a "Client" (computer)
|
||||
try:
|
||||
client = Client(row)
|
||||
except IndexError:
|
||||
except IndexError, ValueError:
|
||||
# Skip if we can't parse the client row
|
||||
continue
|
||||
|
||||
|
||||
@@ -170,6 +170,12 @@ class Bully(Attack):
|
||||
if pixie_re:
|
||||
self.state = "{R}Failed{W}"
|
||||
|
||||
|
||||
# [+] Running pixiewps with the information, wait ...
|
||||
pixie_re = re.compile(r".*Running pixiewps with the information").match(line)
|
||||
if pixie_re:
|
||||
self.state = "{G}Running pixiewps...{W}"
|
||||
|
||||
# [*] Pin is '80246213', key is 'password'
|
||||
pin_key_re = re.compile(r"^\s*Pin is '(\d*)', key is '(.*)'\s*$").match(line)
|
||||
if pin_key_re:
|
||||
|
||||
@@ -22,8 +22,8 @@ class Client(object):
|
||||
6 Probed ESSIDs
|
||||
'''
|
||||
self.station = fields[0].strip()
|
||||
self.power = int(fields[3].strip()) if fields[3].strip().isdigit() else 0
|
||||
self.packets = int(fields[4].strip()) if fields[4].strip().isdigit() else 0
|
||||
self.power = int(fields[3].strip())
|
||||
self.packets = int(fields[4].strip())
|
||||
self.bssid = fields[5].strip()
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user