Skip to content

Commit

Permalink
improve the debug mode
Browse files Browse the repository at this point in the history
  • Loading branch information
SkypLabs committed Feb 18, 2018
1 parent 77b49c5 commit 57e0898
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion sniff-probe-req
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,9 @@ class ProbeRequestSniffer:
self.frame_filters = "type mgt subtype probe-req"
self.socket = None
self.stop_sniffer = Event()

self.exception = None
self.debug = debug

if mac_exclusions is not None:
self.frame_filters += " and not ("
Expand All @@ -149,7 +151,7 @@ class ProbeRequestSniffer:

self.frame_filters += ")"

if debug:
if self.debug:
print("[!] Frame filters: " + self.frame_filters)

def run(self):
Expand All @@ -169,6 +171,9 @@ class ProbeRequestSniffer:
except Exception as e:
self.exception = e

if self.debug:
print("[!] Exception: " + str(e))

def join(self, timeout=None):
"""
Stops the packet sniffer.
Expand Down

0 comments on commit 57e0898

Please sign in to comment.