Commit Graph

29152 Commits

Author SHA1 Message Date
Sai Gomathi N
1f2ecfe5ab pim6d: Add 'show debugging [pimv6]' CLI
Adding show debugging CLI for pimv6 debugs.

Signed-off-by: Sai Gomathi N <nsaigomathi@vmware.com>
2022-08-02 05:36:02 -07:00
Donald Sharp
ad9b47e65e
Merge pull request #11691 from mxyns/bmp-vpnv4monupd-fix
bgpd: fixed bmp vpnv4 monitoring sending withdraws instead of updates
2022-08-01 07:49:18 -04:00
Donald Sharp
102aeba008
Merge pull request #11692 from opensourcerouting/fix/bgpd_as_override
bgpd: Override ASN without checking if an entire as-path is from a single ASN
2022-08-01 07:19:11 -04:00
Donald Sharp
d758d2a9b2
Merge pull request #11712 from mobash-rasool/fixes2
pimd: Simply the code a bit, reduce code complexity
2022-08-01 07:18:10 -04:00
Mobashshera Rasool
0c7f978ec9 pimd: Simply the code a bit, reduce code complexity
Combine all the if conditions in api pim_if_addr_add_all to
reduce nested loops.

Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
2022-07-31 23:43:28 -07:00
mxyns
e7e1561fbb bgpd: fixed bmp vpnv4 monitoring are withdraws instead of updates
fixes the recent support bmp monitor of VPNv4 afi/safi
the bmp updates messages (MP_REACH_NLRI) are never sent for VPNv4 and bmp withdraws (MP_UNREACH_NRLI) are sent instead
this is caused by bgp_node_lookup which fails to find VPNv4 bgp_node in the rib which results in NULL path info attributes passed to bmp_monitor
using bgp_afi_node_lookup instead of bgp_node_lookup solves the problem

Signed-off-by: Maxence Younsi <mx.yns@outlook.fr>
2022-07-29 20:07:21 +02:00
Donatas Abraitis
9bbdb4572d bgpd: Do not check if the whole as-path has target ASN when using as-override
as-override didn't work if the entire as-path is not a single ASN (as a target).

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-29 20:43:22 +03:00
Donald Sharp
e279bfdf06
Merge pull request #11707 from kuldeepkash/pim_v6
doc: Update /doc/topotests.rst documentation
2022-07-29 10:10:26 -04:00
Donatas Abraitis
fbc3ab74ee
Merge pull request #11706 from donaldsharp/safi_hate
bgpd: Safi can be SAFI_MAX which would allow a write beyond alloced
2022-07-29 15:30:03 +03:00
Donald Sharp
84d681e6db
Merge pull request #11702 from patrasar/pim_11675
pimd: Update mroute IIF based on Nexthop received from Zebra
2022-07-29 07:05:50 -04:00
Kuldeep Kashyap
c73d2974b2 doc: Update /doc/topotests.rst documentation
Updated /doc/topotests.rst with socat details,
which is needed to run PIMv6 tests. Socat tool
is used to send PIMv6 join and traffic.

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2022-07-28 21:57:51 -07:00
mobash-rasool
1020efd501
Merge pull request #11703 from donaldsharp/blimey
isisd: Prevent leak of global_ipv6_addrs
2022-07-29 10:23:17 +05:30
Donald Sharp
f609bcd6a6 bgpd: Safi can be SAFI_MAX which would allow a write beyond alloced
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-28 18:01:09 -04:00
Sarita Patra
f789683690 pimd: Update mroute IIF based on Nexthop received from Zebra
Topology:
R1(LHR) ---- R2 ----R4(FHR)
        ---- R3 ----

R2 = RP

Steps to reproduce:
1. R1(LHR) sends IGMP join, R4(FHR) sends multicast traffic.
   Verify traffic is flowing from FHR to LHR.
2. Restart R1(LHR).
3. Below sequence of events are happening after FRR restart in R1(LHR).
4. R1(LHR) Register RP address to Zebra.
5. R1(LHR) Receive update from Zebra that R2(RP) is reachable via R3.
6. R1(LHR) Receive IGMP join for group 225.1.1.1, will create pim upstream
   and (*,G) mroute with IIF towards R3.
7. R1(LHR) Receive update from Zebra that RP is reachable via R2(RP).
8. R1(LHR) Update the PIM upstream IIF, but not updating the (*,G) IIF
   even there is RPF change.
9. R1(LHR) receives IGMP join for group 225.1.1.2, will create (*,G) with
   IIF towards R2(RP), both upstream and (,G) created with IIF towards R2(RP).

Root Cause:
Mroute IIF is not getting updated when better route update
received. It is still pointing to the older nexthop.

Fix:
Update the mroute IIF when there is change in nexthop.

Fixing Issue #11675

Signed-off-by: Sarita Patra <saritap@vmware.com>
2022-07-28 13:03:46 -07:00
Donald Sharp
27383c1c8e isisd: Prevent leak of global_ipv6_addrs
adj->global_ipv6_addrs was not being freed on deletion
of the adjacency.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-28 13:58:14 -04:00
Jafar Al-Gharaibeh
b5e08672ea
Merge pull request #11685 from sri-mohan1/sri-ospf
ospfclient: condition optimization
2022-07-28 11:59:53 -05:00
Donatas Abraitis
8ff746efcb
Merge pull request #11695 from donaldsharp/afi_max
bgpd: Ensure we are not using AFI_MAX
2022-07-28 18:32:24 +03:00
Donald Sharp
dda5a082af
Merge pull request #11693 from opensourcerouting/fix/unlock_bgp_dest
bgpd: Unlock bgp_node after bgp_node_lookup
2022-07-28 11:30:11 -04:00
mobash-rasool
9982282d41
Merge pull request #11697 from donaldsharp/bgp_work
two things
2022-07-28 17:07:06 +05:30
Donatas Abraitis
a25ae82fd4 bgpd: Unlock bgp_node after bgp_node_lookup
bgp_node_lookup increments lock, we should decrement it after use.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-28 14:36:38 +03:00
Donatas Abraitis
e8e28f4f4c
Merge pull request #11701 from kuldeepkash/pim_v6
tests: [PIMv6] Updated topology for static rp suite
2022-07-28 14:33:04 +03:00
Kuldeep Kashyap
855995e505 tests: [PIMv6] Update topology for static rp suite
Updated topology for static rp suite as per testcase.

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2022-07-27 19:51:43 -07:00
Mark Stapp
11f9f70c9d
Merge pull request #11696 from sri-mohan1/sri-debug
ospf6d: corrected the debug string
2022-07-27 15:17:23 -04:00
sri-mohan1
abc14fa02b ospf6d: corrected the debug string
Corrected the gramatical error for debug string

Signed-off-by: sri-mohan1 <sri.mohan@samsung.com>
2022-07-27 22:29:02 +05:30
Donald Sharp
c33e80d5f7 ospfd: Coverity warns that we could possibly use unininted data
In ospf_handle_exnl_lsa_lsId_chg there is a code path
where that we may be using uninitialized data for decisions.
Doubtful that this happens but let's make it less likely to
even more.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-27 12:17:50 -04:00
Donald Sharp
7622259e3c bgpd: Improve indentation in bgp_updgrp_adv.c
This file was hard to read due to heavy indentation.
Let's fix it up some.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-27 12:17:16 -04:00
Donald Sharp
d335feeff8
Merge pull request #11682 from opensourcerouting/frr-format-gcc-12
tools/gcc-plugins: make GCC 12 compatible
2022-07-27 11:44:39 -04:00
Donald Sharp
528d3d87bf
Merge pull request #11689 from opensourcerouting/fix/port_for_unnumbered
bgpd: Allow setting custom port for unnumbered sessions
2022-07-27 11:42:09 -04:00
Donald Sharp
d880a643d7 bgpd: Ensure we are not using AFI_MAX
When using bgp_vty_afi_from_str it can
return AFI_MAX( but in practice never will with
our cli ).  In bgp_default_afi_safi_cmd the code
directly references:
	bgp->default_afi[afi][safi] = TRUE;

and if afi is AFI_MAX FRRR would be accessing
memory where it should not be.

Let's just provide some assurances for coverity
that this never happens.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-27 09:36:17 -04:00
Donatas Abraitis
ada423318a tests: Check if BGP as-override works correctly
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-27 13:33:11 +03:00
sri-mohan1
ac62d9fdca ospfclient: condition optimization
Its better to check the length and then the type of the LSA

Signed-off-by: sri-mohan1 <sri.mohan@samsung.com>
2022-07-27 14:59:53 +05:30
Donatas Abraitis
c41e93720a bgpd: Reset BGP sessions when changing the port
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-27 11:44:07 +03:00
Donatas Abraitis
a3aecc99d5 bgpd: Allow setting custom port for BGP unnumbered peers
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-27 11:36:15 +03:00
Martin Winter
8d4abfc9b9
Merge pull request #11164 from kuldeepkash/pim_v6 2022-07-27 10:05:25 +02:00
Donatas Abraitis
6310965c21
Merge pull request #11681 from donaldsharp/valgrind_issues
pimd: Fix a couple coverity issues with mtracebis_netlink.c
2022-07-27 10:51:25 +03:00
Donatas Abraitis
4a16d62977
Merge pull request #11678 from donaldsharp/valgrind_me
Valgrind me
2022-07-27 10:29:29 +03:00
David Lamparter
3d3ed1afb2 tools/gcc-plugins: make GCC 12 compatible
check_function_arguments_recurse() has received a new function argument
in GCC 12.  Fill it in and add a compatibility wrapper.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2022-07-26 15:38:16 -04:00
Donald Sharp
3816a65da3 pimd: Fix a couple coverity issues with mtracebis_netlink.c
Coverity is complaining that buf has not been initialized.
It has and coverity appears to be confused so let's help it
find the initialization.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-26 13:45:27 -04:00
Christian Hopps
594936dd0a
Merge pull request #11679 from donaldsharp/fix_compilation_bgp_vty
bgpd: Remove newlines from zlog, they are not allowed
2022-07-26 12:48:40 -04:00
Donald Sharp
cbdecd685c tests: Fixup more missing pytestmark annotations
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-26 12:41:53 -04:00
Donald Sharp
1cf42d6a00 zebra: Fix lost memory on lsp free
When cleaning up memory associated with a lsp the
nhlfe is lost in some cases.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-26 12:41:11 -04:00
Donald Sharp
62bf6b4200 bgpd: Fixup pbr rule changes that were missed
In commit: d70a31a3ef

the Zapi ZEBRA_RULE_ADD message was modified but
the bgp version was not updated appropriately and
when zebra received the message it did not properly
read it.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-26 12:41:11 -04:00
Donald Sharp
1af6e82b81 bgpd: Remove newlines from zlog, they are not allowed
commit: a486300b26
introduced newlines in zlog_XX messaging.  Not allowed.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-26 10:06:38 -04:00
Russ White
2ade1c0059
Merge pull request #11582 from liwg06/master
bgpd: Fixup some MAC address token cli syntax
2022-07-26 09:20:45 -04:00
Russ White
3bf3144517
Merge pull request #11523 from pguibert6WIND/bgp_no_retain
Bgp no retain
2022-07-26 08:50:59 -04:00
Donald Sharp
749cf3c23d
Merge pull request #11674 from opensourcerouting/fix/cleanup_subgrpoup_hash_on_update_group_delete
bgpd: Cleanup subgroup hash when we delete/merge a subgroup
2022-07-25 16:50:03 -04:00
Donatas Abraitis
4d28080cb1 bgpd: Rename baa_new/baa_free/etc functions to be human-readable
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-25 16:45:06 +03:00
Donatas Abraitis
e92cf867a6 bgpd: Cleanup subgroup hash when we delete/merge a subgroup
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-07-25 10:20:28 +03:00
Kuldeep Kashyap
dab5ff0030 tests: [PIMv6] Add test_multicast_pimv6_static_rp suite
Adding supporting multicast PIMv6 static rp test
suite.

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2022-07-23 21:28:40 -07:00
Kuldeep Kashyap
e13f9c4f31 tests: [PIMv6] APIs for multicast PIMv6 config
Enhanced few exsiting PIM APIs to support both
IPv4 and IPv6 configuration. Added few new APIs
for PIMv6. Tested all existing tests with new
API changes.

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2022-07-23 21:28:35 -07:00