OPNsense Forum

English Forums => Development and Code Review => Topic started by: skacem on August 13, 2024, 08:48:11 PM

Title: BGP neighbor range (request)
Post by: skacem on August 13, 2024, 08:48:11 PM
hello

instead of having to configure bgp neighbor per neighbor, it is more interesting to configure a bgp neighbor range
FRRouting has already this functionality

https://docs.frrouting.org/en/stable-10.0/bgp.html#clicmd-bgp-listen-range-A.B.C.D-M-X-X-X-X-M-peer-group-PGNAME (https://docs.frrouting.org/en/stable-10.0/bgp.html#clicmd-bgp-listen-range-A.B.C.D-M-X-X-X-X-M-peer-group-PGNAME)

the syntax is
bgp listen range <A.B.C.D/M|X:X::X:X/M> peer-group PGNAME

but it seems the FRR plugin for OPNsense doest include it yet
there is nowhere to enter the (listen range) in the Routing--BGP menu

Thanks

Title: Re: BGP neighbor range (request)
Post by: arichtman on August 20, 2024, 09:06:10 PM
Thanks for this post! Exactly what I was looking for! I want to essentially accept any peers on a given internal interface, maybe limit the AS number but that can be done with filtering or whatnot. I might poke about the back end and see if it's configurable at system level, though ideally, yes have it in the plugin/GUI, if for no other reason than it doesn't get wiped on updates/reconfigurations
Title: Re: BGP neighbor range (request)
Post by: arichtman on April 26, 2025, 03:08:46 AM
Hi - did you find a way to safely and consistently set `listen range` in `frr.conf` to get this to work?
Title: Re: BGP neighbor range (request)
Post by: arichtman on May 11, 2025, 11:33:51 AM
Sooo looks like the front-end/plugin don't support listen range but if you jam your config into FRR it works fine.
I'm working out which autorun to place a script in that just overwrites the generated `frr.conf`

https://docs.opnsense.org/development/backend/autorun.html
Title: Re: BGP neighbor range (request)
Post by: Monviech (Cedrik) on May 11, 2025, 11:56:33 AM
Why arent you just opening a feature request instead? They do get worked on and implemented.

https://github.com/opnsense/plugins/issues?q=is%3Aissue%20state%3Aclosed%20frr
Title: Re: BGP neighbor range (request)
Post by: arichtman on May 11, 2025, 12:26:44 PM
There was one, https://github.com/opnsense/plugins/issues/4015

Shall I request it reopened?
Title: Re: BGP neighbor range (request)
Post by: Monviech (Cedrik) on May 11, 2025, 12:45:58 PM
I took the issue.