This commit is contained in:
n3wtype 2026-05-25 09:41:10 +08:00 committed by GitHub
commit a38e6ee2df
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 2 deletions

View file

@ -70,7 +70,7 @@
<label>Local Initiater IP</label>
<type>text</type>
<advanced>true</advanced>
<help>Specify the local IP address used to establish connections with the neighbor. Only relevant for MD5 authentication.</help>
<help>Specify the local IP address used to establish connections with the neighbor. Affects BGP session source ip selection and MD5 authentication. Takes precedense before an "updatesource" option.</help>
<grid_view>
<visible>false</visible>
</grid_view>

View file

@ -138,7 +138,10 @@ router bgp {{ OPNsense.quagga.bgp.asnumber }}
{% if 'disable_connected_check' in neighbor and neighbor.disable_connected_check == '1' %}
neighbor {{ neighbor.address }} disable-connected-check
{% endif %}
{% if ':' not in neighbor.address and 'updatesource' in neighbor and neighbor.updatesource != '' %}
{% if 'localip' in neighbor and neighbor.localip != '' %}
neighbor {{ neighbor.address }} update-source {{ neighbor.localip }}
%}
{% elif ':' not in neighbor.address and 'updatesource' in neighbor and neighbor.updatesource != '' %}
neighbor {{ neighbor.address }} update-source {{ physical_interface(neighbor.updatesource) }}
{% endif %}
{% if ':' in neighbor.address and 'linklocalinterface' in neighbor and neighbor.linklocalinterface != '' %}