fix: skipping open access points (fixes #463)

This commit is contained in:
Simone Margaritelli 2019-10-30 17:50:56 +01:00
parent 965416483d
commit 1600d8cbd1

View File

@ -170,7 +170,9 @@ class Agent(Client, Automata, AsyncAdvertiser, AsyncTrainer):
s = self.session()
plugins.on("unfiltered_ap_list", self, s['wifi']['aps'])
for ap in s['wifi']['aps']:
if ap['hostname'] not in whitelist:
if ap['encryption'] == '' or ap['encryption'] == 'OPEN':
continue
elif ap['hostname'] not in whitelist:
if self._filter_included(ap):
aps.append(ap)
except Exception as e: