summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-02-04 13:24:24 +0100
committerGitHub <noreply@github.com>2023-02-04 13:24:24 +0100
commit3329943339ce7f5b8dc108ad4528fb9d48ef70fa (patch)
tree6fbc3419a56d0334e910f51dad81a7e5c69f70f0 /src
parent182da4fa10c1a5f45e52a3d7949acb3a3d2eb266 (diff)
parent55bf752570019e1b3b756b25f500cd9bf17efb01 (diff)
downloadvyos-1x-3329943339ce7f5b8dc108ad4528fb9d48ef70fa.tar.gz
vyos-1x-3329943339ce7f5b8dc108ad4528fb9d48ef70fa.zip
Merge pull request #1797 from ServerForge/current
bgp: T4817: add support for RFC9234
Diffstat (limited to 'src')
-rwxr-xr-xsrc/conf_mode/protocols_bgp.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/conf_mode/protocols_bgp.py b/src/conf_mode/protocols_bgp.py
index c410258ee..4f05957fa 100755
--- a/src/conf_mode/protocols_bgp.py
+++ b/src/conf_mode/protocols_bgp.py
@@ -235,6 +235,11 @@ def verify(bgp):
raise ConfigError(f'Specified peer-group "{peer_group}" for '\
f'neighbor "{neighbor}" does not exist!')
+ if 'local_role' in peer_config:
+ #Ensure Local Role has only one value.
+ if len(peer_config['local_role']) > 1:
+ raise ConfigError(f'Only one local role can be specified for peer "{peer}"!')
+
if 'local_as' in peer_config:
if len(peer_config['local_as']) > 1:
raise ConfigError(f'Only one local-as number can be specified for peer "{peer}"!')