summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-03-23 19:23:05 +0100
committerChristian Poessinger <christian@poessinger.com>2020-03-23 19:23:29 +0100
commitaa4ba0b2ae79245c60b6cf04d666d21a18c858ab (patch)
treedab014d67d097cc699199c94d3bf0a52d9e2c26d /python
parentc8964f9564c5b6c29c7e381280d17004343749b2 (diff)
downloadvyos-1x-aa4ba0b2ae79245c60b6cf04d666d21a18c858ab.tar.gz
vyos-1x-aa4ba0b2ae79245c60b6cf04d666d21a18c858ab.zip
ifconfig: T2151: always start interface in monitoring mode
Diffstat (limited to 'python')
-rw-r--r--python/vyos/ifconfig/wireless.py10
1 files changed, 4 insertions, 6 deletions
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