diff options
author | Christian Poessinger <christian@poessinger.com> | 2022-03-03 20:23:09 +0100 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2022-03-03 20:23:09 +0100 |
commit | bb78f3a9ad28f62896a536719783011794deb64c (patch) | |
tree | 8dfe129772c4ce94744f24c984e720bf94c98b6f /src/conf_mode | |
parent | e3f86ce0d65fe8fe0c5eebebdfd3ab3723e2e539 (diff) | |
download | vyos-1x-bb78f3a9ad28f62896a536719783011794deb64c.tar.gz vyos-1x-bb78f3a9ad28f62896a536719783011794deb64c.zip |
static: T4283: support "reject" routes - emit an ICMP unreachable when matched
Diffstat (limited to 'src/conf_mode')
-rwxr-xr-x | src/conf_mode/protocols_static.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/conf_mode/protocols_static.py b/src/conf_mode/protocols_static.py index c1e427b16..f0ec48de4 100755 --- a/src/conf_mode/protocols_static.py +++ b/src/conf_mode/protocols_static.py @@ -82,6 +82,10 @@ def verify(static): for interface, interface_config in prefix_options[type].items(): verify_vrf(interface_config) + if {'blackhole', 'reject'} <= set(prefix_options): + raise ConfigError(f'Can not use both blackhole and reject for '\ + 'prefix "{prefix}"!') + return None def generate(static): |