diff options
Diffstat (limited to 'python')
| -rw-r--r-- | python/vyos/configverify.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/python/vyos/configverify.py b/python/vyos/configverify.py index 5ff8dda2c..6e2fd1618 100644 --- a/python/vyos/configverify.py +++ b/python/vyos/configverify.py @@ -180,9 +180,14 @@ def verify_mirror_redirect(config): It makes no sense to mirror traffic back at yourself! """ - if {'mirror', 'redirect'} <= set(config): + if 'mirror' in config and 'redirect' in config: raise ConfigError('Mirror and redirect can not be enabled at the same time!') + if 'mirror' in config and 'qos' in config: + # XXX: support combination of limiting and mirror - this is an artificial + # limitation from the past + raise ConfigError('Can not use QoS together with mirror!') + if 'mirror' in config: for direction, mirror_interface in config['mirror'].items(): if not interface_exists(mirror_interface): @@ -199,11 +204,6 @@ def verify_mirror_redirect(config): raise ConfigError(f'Requested redirect interface "{redirect_ifname}" '\ 'does not exist!') - if 'qos' in config and ('mirror' in config or 'redirect' in config): - # XXX: support combination of limiting and redirect/mirror - this is an - # artificial limitation - raise ConfigError('Can not use QoS together with mirror/redirect!') - def verify_authentication(config): """ Common helper function used by interface implementations to perform |
