def get_scanning_result(self, iface):
indent = ' ' * 1
flagExec = self.exec_iwlist(iface)
if flagExec:
header = indent + 'Scanning WiFi networks using interface \'' + iface + '\'\n'
network_table = [['SSID', 'AP Address', 'Channel', 'Encryption', 'Quality']]
for dict_network in self.parsed_cells:
network_table.append([
dict_network['Name'],
dict_network['Address'],
dict_network['Channel'],
dict_network['Encryption'],
dict_network['Quality']
])
table = AsciiTable(network_table)
print (Fore.YELLOW + Style.DIM + header + table.table)
return True
else:
return False
评论列表
文章目录