Commit Graph

36907 Commits

Author SHA1 Message Date
Donald Sharp
c9975e1525
Merge pull request #17488 from FRRouting/mergify/bp/stable/10.2/pr-17487
bgpd: Do not reset peers on suppress-fib toggling (backport #17487)
2024-11-22 18:33:59 -05:00
Donatas Abraitis
f62baf6ca9 bgpd: Do not reset peers on suppress-fib toggling
If the desired state is the same - do nothing instead of resetting once again.

Fixes: bdb5ae8bce ("bgpd: Make suppress-fib-pending clear peering")

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 7fb4c03f5b)
2024-11-22 15:17:28 +00:00
Jafar Al-Gharaibeh
a414010917
Merge pull request #17470 from FRRouting/mergify/bp/stable/10.2/pr-17464
bfdd: retain remote dplane client socket (backport #17464)
2024-11-20 21:53:47 -06:00
Mark Stapp
be09cbaf86 bfdd: retain remote dplane client socket
When using bfd in remote-dataplane client mode, don't close
a new client socket if we're going to try to use it.

Signed-off-by: Mark Stapp <mjs@cisco.com>
(cherry picked from commit f511530788)
2024-11-20 19:06:18 +00:00
Jafar Al-Gharaibeh
60982c4e48
Merge pull request #17446 from opensourcerouting/fix/backport_65a43b57efd60c4fdf80c935750046ba861ec79f_10.2
bgpd: Validate both nexthop information (NEXTHOP and NLRI) (backport)
2024-11-19 23:27:54 -06:00
Donatas Abraitis
91f482a854
Merge pull request #17437 from FRRouting/mergify/bp/stable/10.2/pr-17432
bgpd : backpressure - Fix to pop items off zebra_announce FIFO for few EVPN triggers (backport #17432)
2024-11-19 22:47:55 +01:00
Donatas Abraitis
863d1ddc21 bgpd: Validate both nexthop information (NEXTHOP and NLRI)
If we receive an IPv6 prefix e.g.: 2001:db8:100::/64 with nextop: 0.0.0.0, and
mp_nexthop: fc00::2, we should not treat this with an invalid nexthop because
of 0.0.0.0. We MUST check for MP_REACH attribute also and decide later if we
have at least one a valid nexthop.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit a0d2734e87)
2024-11-17 11:16:05 +02:00
Rajasekar Raja
a7aae788ec bgpd : backpressure - Fix to pop items off zebra_announce FIFO for few EVPN triggers
In cases such as 'no advertise-all-vni' and L2 VNI DELETE, we need to
pop all the VPN routes present in the bgp_zebra_announce FIFO yet to
be processed regardless of VNI is configured or not.

NOTE: NO need to pop the VPN routes in two cases
 1) In free_vni_entry
   - Called by bgp_free()->bgp_evpn_cleanup().
   - Since bgp_delete is called before bgp_free and we pop all the dest
     pertaining to bgp under delete.
 2) evpn_delete_vni() when user configures "no vni" since the withdraw
    of all routes happen in normal cycle.

Fixes: a07df6f754
("bgpd : backpressure - Handle BGP-Zebra(EPVN) Install evt Creation")

Ticket :#4163611

Signed-off-by: Rajasekar Raja <rajasekarr@nvidia.com>
(cherry picked from commit 898852f269)
2024-11-16 10:53:01 +00:00
Jafar Al-Gharaibeh
22746b8d59 FRR Release 10.2
New Features Highlight:

- PIM candidate BSR/RP [#16438]
- Static IGMP join without an IGMP report [1#6450]
- PIM AutoRP discovery/announcements [#16634]
- IGMP proxy [#16861]
- SRv6 SID Manager [#15604]
- Add `bgp ipv6-auto-ra` command [#16354]
- Implement `neighbor x remote-as auto` for BGP [#16345]
- Implement `bgp dual-as` for BGP [#16816]
- Implement BGP-wide configuration for graceful restart [#16099]
- Handle kernel routes appropriately (should fix recent NOPREFIXROUTE issue) [#16300]
- Add `cisco-authentication` password support for NHRP [#16172]

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2024-11-12 10:20:46 -06:00
Jafar Al-Gharaibeh
2badb569be debian, redhat: updating changelog for 10.2 release
Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2024-11-12 10:20:37 -06:00
Russ White
b96421690c
Merge pull request #17411 from FRRouting/mergify/bp/stable/10.2/pr-17409
bgpd: fix resolvedPrefix in show nexthop json output (backport #17409)
2024-11-12 10:03:45 -05:00
Krishnasamy R
ffc5f32789 bgpd: fix resolvedPrefix in show nexthop json output
While populating  the nexthop info for "show bgp nexthop json", resolvedPrefix
is added in parent json object instead of json_nexthop object.
This results in displaying wrong resolvedPrefix for nexthops.
Fixing the same by adding resolvedPrefix to json_nexthop object, so that
the proper resolvedPrefix would be displayed for the respective nexthop

Signed-off-by: Krishnasamy R <krishnasamyr@nvidia.com>
(cherry picked from commit 95c08e082c)
2024-11-11 15:11:12 +00:00
Donatas Abraitis
026f0ddb69
Merge pull request #17397 from FRRouting/mergify/bp/stable/10.2/pr-17362
bgpd: Fix for match source-protocol in route-map for redistribute cmd (backport #17362)
2024-11-10 19:13:14 +02:00
Rajasekar Raja
031d427101 bgpd: Fix for match source-protocol in route-map for redistribute cmd
A redistribute cmd can have a route-map attached to it and adding the
match source-protocol to that route-map means BGP to filter which
protocol routes to accept among the bunch of routes zebra is sending.

Fixing this since this wasnt implemented earlier.

Ticket :#4119692

Signed-off-by: Donald Sharp <sharpd@nvidia.com>

Signed-off-by: Rajasekar Raja <rajasekarr@nvidia.com>
(cherry picked from commit 68358c0f92)
2024-11-09 20:02:57 +00:00
Donald Sharp
6afff0c17f
Merge pull request #17387 from FRRouting/mergify/bp/dev/10.2/pr-17341
bgpd:support tcp-mss for neighbor group (backport #17341)
2024-11-08 11:14:03 -05:00
hanyu.zly
0c1564d1d9 bgpd:support tcp-mss for neighbor group
Signed-off-by: hanyu.zly <hanyu.zly@alibaba-inc.com>
(cherry picked from commit 9fa56a03c7)
2024-11-08 07:12:55 +00:00
Donald Sharp
d0ccf0c9fd
Merge pull request #17378 from FRRouting/mergify/bp/dev/10.2/pr-17376
bgpd: Clear stale routes with multiple paths (backport #17376)
2024-11-07 14:12:32 -05:00
Donatas Abraitis
0b1bb84242 tests: Check if stale routes with addpath are marked with LLGR community
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 2e5e3b4bd0)
2024-11-07 16:07:12 +00:00
Donatas Abraitis
86532b3dc2 tests: Check if routes with addpath are cleared if they are stale
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 444bdc4cc0)
2024-11-07 16:07:12 +00:00
Donatas Abraitis
89801c2905 bgpd: Set LLGR stale routes for all the paths including addpath
Without this patch we set only the first path for the route (if multiple exist)
as LLGR stale and stop doing that for the rest of the paths, which is wrong.

Fixes: 1479ed2fb3 ("bgpd: Implement LLGR helper mode")

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 895d586a5f)
2024-11-07 16:07:12 +00:00
Donatas Abraitis
f1454d95aa bgpd: Clear all paths including addpath once GR expires
We iterated over all bgp_path_info's, but once we remove the path, we didn't
check for other paths under the same bgp_dest.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 7de464b00f)
2024-11-07 16:07:12 +00:00
Donald Sharp
f640f0714c
Merge pull request #17345 from FRRouting/mergify/bp/dev/10.2/pr-17115
nhrpd: fix passphrase handling, add topotest for resolution request (backport #17115)
2024-11-05 14:28:10 -05:00
Donald Sharp
0533efc5e4
Merge pull request #17357 from FRRouting/mergify/bp/dev/10.2/pr-17326
zebra: fix missing kernel routes (backport #17326)
2024-11-05 14:27:53 -05:00
Donald Sharp
4f823efd63
Merge pull request #17352 from FRRouting/mergify/bp/dev/10.2/pr-17319
ospfd: Use router_id what Zebra has if we remove a static router_id (backport #17319)
2024-11-05 14:26:20 -05:00
Jafar Al-Gharaibeh
530b71b0ac
Merge pull request #17347 from FRRouting/mergify/bp/dev/10.2/pr-17305
bgpd: Treat numbered community-list only if it's in a range 1-500 (backport #17305)
2024-11-05 12:14:02 -06:00
anlan_cs
ac1bd83312 test: add test case for kernel blackhole routes
The test verifies that a kernel blackhole route is not affected by
interface's link change.

Signed-off-by: anlan_cs <anlan_cs@126.com>
(cherry picked from commit 0073a870d1)
2024-11-05 15:22:24 +00:00
anlan_cs
3cb4dcda5c zebra: fix missing kernel routes
The `rib_update_handle_kernel_route_down_possibility()` didn't consider
the kernel routes ( blackhole )  without interface.  When some other
interfaces are down, these kernel routes will be wrongly removed.

Signed-off-by: anlan_cs <anlan_cs@126.com>
(cherry picked from commit 44a82da405)
2024-11-05 15:22:23 +00:00
Donatas Abraitis
efb2f7c080 ospfd: Use router_id what Zebra has if we remove a static router_id
If we set router-id, e.g. `router-id x.x.x.x`, then we have:

```
pc.donatas.net# show ip ospf | include Router ID
 OSPF Routing Process, Router ID: x.x.x.x
```

But once we remove it (`no router-id x.x.x.x`), the old router-id remains.

This is kinda OK, but to be consistent with OSPFv3 we should use what Zebra
already has, instead of retaining the old one.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 1073e0f9b3)
2024-11-05 15:20:52 +00:00
Donatas Abraitis
4e65bbc825 ospfd: Add a hidden command for old no router-id
A new command is `ospf router-id ...`, but the old one is also valid. Just a no
form was missed.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 80bfe6784f)
2024-11-05 15:20:52 +00:00
Donatas Abraitis
8d1ade44be bgpd: Treat numbered community-list only if it's in a range 1-500
Before this patch, if we set something like:

```
bgp extcommunity-list expanded 1234 permit admin
```

In running config we have:

```
bgp extcommunity-list 1234 seq 5 permit admin
```

That leads to incorrect rendering, even more the line can't be deleted.

With this fix we treat numbered community-list only if it's inside the range
1-500, otherwise it's a non-numbered clist.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 4c1ee29116)
2024-11-05 15:17:25 +00:00
Joshua Muthii
a5c5a2fd24 nhrpd: Modify NHRP authentication feature logging
Modified nhrp_connection_authorized(). Initially, when writing debug
information about incoming NHRP packets with authentication enabled,
the nhrp_connection_authorized() function would print the
passphrase of the incoming packet as if it were a null terminated
string. This meant that if the passphrase on the incoming packet
had non ASCII-complient bytes in it, it would attempt to print those
bytes anyway. There was also no check that the size of the passphrase in
the incoming packet matched the size of the passphrase on the interface.
The changes in this commit log the passphrase on the incoming packet as
well as the passphrase on interface in HEX to avoid issues with ASCII.
It also performs a check that accounts for the sizes of the two different
passphrases

Moved CISCO_PASS_LENGTH_LEN from nhrp_vty.c to nhrp_protocol.h
for easier access  to the macro in other files

Signed-off-by: Joshua Muthii <jmuthii@labn.net>
(cherry picked from commit 5718ee37c7)
2024-11-05 15:11:07 +00:00
Joshua Muthii
e127b7f464 nhrpd: Add topotest for retrying resolution request
Modified nhrp_topo topotest to test for newly added resolution
request retry feature. Changes to the topotest include adding a spoke to the
existing nhrp_topo topotest so that a topology with two spokes and hub
can be used to create shortcuts and test the sending/resending of
resolution requests and responses between spoke and hub. The resolution
request retry feature was tested by blocking incoming resolution requests on a
receiving nodes to stop the creation of a successful shortcut - which
then triggered the sending spoke to retry sending resolution requests

Signed-off-by: Joshua Muthii <jmuthii@labn.net>
(cherry picked from commit d599aa1da6)
2024-11-05 15:11:07 +00:00
Jafar Al-Gharaibeh
02f4fef5ff
Merge pull request #17325 from FRRouting/mergify/bp/dev/10.2/pr-17317
tests: Add an ability to specify daemon params with unified config (backport #17317)
2024-11-01 09:03:27 -05:00
Mark Stapp
6fbc39904b
Merge pull request #17321 from FRRouting/mergify/bp/dev/10.2/pr-17318
zebra: Add missing new line for help string (backport #17318)
2024-10-31 12:00:42 -04:00
Donatas Abraitis
9474e8677e tests: Add an ability to specify daemon params with unified config
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 879466731b)
2024-10-31 13:55:51 +00:00
Donatas Abraitis
c8341f265f
Merge pull request #17300 from FRRouting/mergify/bp/dev/10.2/pr-17250
isisd: fix change flex-algorithm number from uint32 to uint8 (backport #17250)
2024-10-31 15:17:02 +02:00
Donatas Abraitis
644211270f zebra: Add missing new line for help string
```
  -A, --asic-offload        FRR is interacting with an asic underneath the linux kernel
      --v6-with-v4-nexthops Underlying dataplane supports v6 routes with v4 nexthops  -s, --nl-bufsize          Set netlink receive buffer size
```

Fixes: 1f5611c06d ("zebra: Allow zebra cli to accept v6 routes with v4 nexthops")

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit 25ae643996)
2024-10-31 13:14:40 +00:00
Jafar Al-Gharaibeh
4e23ebed1e
Merge pull request #17315 from FRRouting/mergify/bp/dev/10.2/pr-17310
doc: Create html_context before setting READTHEDOCS (backport #17310)
2024-10-30 16:16:25 -05:00
Jafar Al-Gharaibeh
01be55aa5c
Merge pull request #17309 from donaldsharp/backport_17254_10.2
Mrib nht wonky (backport #17254)
2024-10-30 14:36:56 -05:00
Donatas Abraitis
410b406afe doc: Create html_context before setting READTHEDOCS
Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/frrouting/envs/latest/lib/python3.11/site-packages/sphinx/config.py", line 529, in eval_config_file
    exec(code, namespace)  # NoQA: S102
    ^^^^^^^^^^^^^^^^^^^^^
  File "/home/docs/checkouts/readthedocs.org/user_builds/frrouting/checkouts/latest/doc/user/conf.py", line 77, in <module>
    html_context["READTHEDOCS"] = True
    ^^^^^^^^^^^^
NameError: name 'html_context' is not defined

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit ef9f698e04)
2024-10-30 18:14:56 +00:00
Donald Sharp
7ddbadd7f7 zebra: When installing a mroute, allow it to flow
Currently the mroute code was not allowing the mroute
to be sent to the dataplane.  This leaves us with a
situation where the routes being installed where never
being set as installed and additionally nht against
the mrib would not work if the route came into existence
after the nexthop tracking was asked for.

Turns out all the pieces where there to let this work.
Modify the code to pass it to the dplane and to send
it back up as having worked.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2024-10-30 07:47:32 -04:00
Donald Sharp
fb08f08ebb zebra: Add safi to some debugs
Trying to figure out what safi we are talking about is fun when
it is not put into the debugs.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
(cherry picked from commit 811168ecc3)
2024-10-30 07:45:08 -04:00
Donald Sharp
d48fab2707 sharpd: Allow sharpd to watch nexthops in the mrib
Nothing special here, just allow sharpd to ask to watch
nexthops in the mrib.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
(cherry picked from commit aff8eaa4a2)
2024-10-30 07:45:02 -04:00
Philippe Guibert
909e6dd621 isisd: fix change flex-algorithm number from uint32 to uint8
The algorithm number is encoded on 8 bits and does not require
an unsigned 32 bit value to store the value.

Fixes: cc4926c128 ("isisd,yang: add algorithm-prefix-sid configuration tree")

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
(cherry picked from commit 8e861a75e8)
2024-10-30 08:43:56 +00:00
Russ White
0aacf8f93a
Merge pull request #17291 from FRRouting/mergify/bp/dev/10.2/pr-17245
bgpd:  fix crash when polling bgp4v2PathAttrTable (backport #17245)
2024-10-29 10:22:54 -04:00
Francois Dumontet
2432b6481e bgpd: fix crash when polling bgp4v2PathAttrTable
we have

(gdb) p *path->attr->aspath
$1 = {refcnt = 3, segments = 0x0, json = 0x0, str = 0x55723d0b7470 "", str_len = 0, asnotation = ASNOTATION_PLAIN}

It looks like this aspath is empty, resulting in a size 0 and NULL pointer for path->attr->aspath->segments which leads to the SIGSEGV

fixe: return 0 when segments is null.

Signed-off-by: Francois Dumontet <francois.dumontet@6wind.com>
(cherry picked from commit ee2f1b85cf)
2024-10-29 12:12:51 +00:00
Donatas Abraitis
dbda55017c
Merge pull request #17282 from FRRouting/mergify/bp/dev/10.2/pr-17278
bgpd: fix blank line in running-config with bmp listener cmd (backport #17278)
2024-10-29 13:17:07 +02:00
Philippe Guibert
a6cda19865 bgpd: fix blank line in running-config with bmp listener cmd
An extra blank line is added in show running-config with BMP:

> ubuntu2204hwe(config)# router bgp 65500
> ubuntu2204hwe(config-router)# bmp targets tgt
> ubuntu2204hwe(config-bgp-bmp)# bmp monitor ipv4 unicast pre-policy
> ubuntu2204hwe(config-bgp-bmp)# bmp listener 192.0.2.100 port 44
> ubuntu2204hwe(config-bgp-bmp)# do show running-config
>
> router bgp 65500
> [..]
>  bmp targets tgt
>   bmp monitor ipv4 unicast pre-policy
>                                       <-- blank line
>   bmp listener 192.0.2.100 port 44
>  exit

Remove the blank line.

Fixes: ed18356f1f ("bgpd/bmp: BMP implementation")
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
(cherry picked from commit 9a33ee18bf)
2024-10-29 08:58:17 +00:00
Jafar Al-Gharaibeh
354537aa8d
Merge pull request #17277 from FRRouting/mergify/bp/dev/10.2/pr-17157
tests: logger masked in topotest.py (backport #17157)
2024-10-28 13:21:17 -05:00
Jafar Al-Gharaibeh
e144cc3ea7
Merge pull request #17265 from FRRouting/mergify/bp/dev/10.2/pr-16354
bgpd: add bgp ipv6-auto-ra command (backport #16354)
2024-10-28 12:53:35 -05:00