Avoiding needless mac_address lookup, empty interfaces, banner tweak.

mac_address lookup & empty iface for #112.
Banner tweak for #92
This commit is contained in:
derv82
2018-08-16 01:10:34 -07:00
parent d7120bca50
commit f76c339bb7
3 changed files with 17 additions and 10 deletions

View File

@@ -19,7 +19,6 @@ class AirmonIface(object):
self.interface = interface
self.driver = driver
self.chipset = chipset
self.mac_address = Ifconfig.get_mac(interface)
# Max length of fields.
# Used for printing a table of interfaces.
@@ -101,6 +100,9 @@ class Airmon(Dependency):
if phy == 'PHY' or phy == 'Interface':
continue # Header
if len(interface.strip()) == 0:
continue
interfaces.append(AirmonIface(phy, interface, driver, chipset))
return interfaces