bgpd: Fix coverity issues after 19506Fixing two coverity issues:
* In bgp_label: took address of first element of array and Coverity
gave ARRAY_VS_SINGLETON error, changed to just copying array pointer
* In bgp_zebra: though there was check for size of maximum destination
address length, there was no explicit check for size of source array,
added this check
Signed-off-by: Kyrylo Yatsenko <hedrok@gmail.com>
bfdd, ripd, ripngd: implement yang:date-and-timeThe proper implementation of yang:date-and-time was added some time ago
in yang_data_new_date_and_time. This commit updates places where the
usage was missing.
Signed-off-by: Igor Ryzhov <idryzhov@gmail.com>
zebra: avoid using freed vtep pointer in debug logUse input vtep_ip field for printing in debug log rather than
vtep pointer which is potentially freed if the VTEP is a duplicate
in the nh_list.
Signed-off-by: Rajasekar Raja <rajasekarr@nvidia.com>
bgpd: add remoteTransposedSid value in json output of vpn pathsThe transposed SID value is not visible from the VPN paths.
> r1# show bgp ipv4 vpn 10.0.0.0/24
> BGP routing table entry for 65001:20:10.0.0.0/24, version 3
> not allocated
> Paths: (1 available, best #1)
> Advertised to peers:
> 2001:db8:12::2
> Local
> 0.0.0.0 from 0.0.0.0 (192.0.2.1) vrf Vrf20(7) announce-nh-self
> Origin incomplete, metric 0, weight 32768, valid, sourced,...
bgpd: Allow proper shutdown of bgp dynamic peers in rare caseThere exists a series of events that causes dynamic peers to
accept new connections on a existing connection and leaving
everything in a weird state.
Series of events:
a) Interface down event
b) BGP places peering on queue to be cleared in the future
*note* that BGP is completely swamped and doesn't get to
this in a timely manner
c) Interface comes up
d) Peer is not loaded and attempts to rec...
tools: increase the number of FD in frr.serviceIn scale vrrp setup of 255 sessions, the current number of FD limit is
not enough. Hence increasing the FD limit 2048.
Each vrrp address family session open 2 socket(tx,rx), 4 socket per
ipv4&ipv6 session.
vrrpd process without any session have 18 FDs for various functionality
including garp and ND.
vrrpd 664325 frr 0r CHR 1,3 0t0 ...
tests: Add large community buffer limit test for 150 communitiesTest that 150 large communities with max-sized values can be
configured in a route-map, exceeding the old 4096 byte limit
and requiring the 8192 byte buffer increase.
Signed-off-by: Rajasekar Raja <rajasekarr@nvidia.com>
bgpd: adding flog_err for long cliAdding flog_err to log the error when
the cli entered by user exceeds 8k limit
We would see something like
2025/11/24 18:36:45 BGP: [VNXE7-TGXN3][EC 100663304] Command too long (XYZ bytes): 4967295:4294967031 4294967295:4294967295:4294967032 4294967295:4294967295:429496...
Signed-off-by: Manpreet Kaur <manpreetk@nvidia.com>
Signed-off-by: Rajasekar Raja <rajasekarr@nvidia.com>
tests: add test for multiple labels in BGP-LUAnnounce three routes with label stacks 777/10006, 90, 11/22/33/44/55,
check that `show bgp ipv6 PREFIX json` has proper labels in
`remoteLabels`.
Test for issue #19506
Signed-off-by: Kyrylo Yatsenko <hedrok@gmail.com>
bgpd: Support multiple labels in BGP-LUUpdated behaviour for SAFI_LABELED_UNICAST to support multiple labels:
* Change BGP_MAX_LABELS 2 -> 10 (maximum possible number of labels for
BGP-LU), previously for SAFI_LABELED_UNICAST only one label was
supported
* Save all labels when receiving an update event in
`bgp_nlri_get_labels`, send them all to zebra in
`bgp_zebra_announce_parse_nexthop`
One of uses of multiple labels is S...
zebra: fix crash due to lack of control of received number of srv6 SID from netlinkwe encounter the following crash;
(gdb) bt
at ./nptl/pthread_kill.c:44
at ./nptl/pthread_kill.c:78
at ./nptl/pthread_kill.c:89
context=0x7fffa2e82b80)
at /build/make-pkg/output/_packages/cp-routing/src/lib/sigevent.c:248
at ./nptl/pthread_kill.c:44
at ./nptl/pthread_kill.c:78
at ./nptl/pthread_kill.c:89
at ../sysdeps/posix/raise.c:26
fmt=fmt@entry=0x7a4f...
ospfd: Fix DO_NOT_AGE flag handlinglsa->data->ls_age is in network byte order, not in host order.
Ensure that endianness is taken properly into account in flag ops.
Ensure that DO_NOT_AGE bit is not lost on LS Age increment or when
maxaging.
DO_NOT_AGE flag must also be masked out when time in seconds is needed.
Signed-off-by: Ari Kauppi <kauppi@papupata.org>
tools: fix checkpatch.pl for 'FOO < BAR && ...'In the check $to gets value from $LvalOrFunc in regular expression that
ends with '\s*', so in case of check for
if (FOO < BAR && somethingelse)
$to equals 'BAR ' and check that on right side there is also a constant
fails.
Simple fix: add '\s*' to re that checks whether $to is constant.
Signed-off-by: Kyrylo Yatsenko <hedrok@gmail.com>