From aa4ba0b2ae79245c60b6cf04d666d21a18c858ab Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Mon, 23 Mar 2020 19:23:05 +0100 Subject: ifconfig: T2151: always start interface in monitoring mode --- python/vyos/ifconfig/wireless.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'python/vyos/ifconfig/wireless.py') diff --git a/python/vyos/ifconfig/wireless.py b/python/vyos/ifconfig/wireless.py index faa47358d..895e3ea09 100644 --- a/python/vyos/ifconfig/wireless.py +++ b/python/vyos/ifconfig/wireless.py @@ -26,12 +26,12 @@ class WiFiIf(VLANIf): default = { 'type': 'wifi', - 'phy': 'phy0', - 'op_mode': 'monitor' + 'phy': 'phy0' } def _create(self): - cmd = 'iw phy {phy} interface add {ifname} type {op_mode}' \ + # all interfaces will be added in monitor mode + cmd = 'iw phy {phy} interface add {ifname} type monitor' \ .format(**self.config) self._cmd(cmd) @@ -56,8 +56,6 @@ class WiFiIf(VLANIf): >> conf = WiFiIf().get_config() """ config = { - 'phy': 'phy0', - 'op_mode': 'monitor' # required for proper interface deletion, as - # _update() is called prior to remove() + 'phy': 'phy0' } return config -- cgit v1.2.3