Donald Sharp
3d55a4ef29
lib, zebra: Use defines for distance
...
Use the defines for distance that are in zebra.h. We could
easily have a cluster where we don't agree with ourselves. So
let's convert zebra to use the defines in zebra.h
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:47 -05:00
Donald Sharp
8f4ea1fc5d
lib, zebra: Move ZEBRA_ON_RIB_PROCESS_HOOK_CALL
...
The define of ZEBRA_ON_RIB_PROCESS_HOOK_CALL was in zebra.h
which exposes it to everyone, except zebra is the only daemon
to use this define. This does not beling in zebra.h
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:47 -05:00
Donald Sharp
af01a87b3d
lib: Remove include of asm/types.h
...
We do not use this, nor should we. So let's remove it.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:47 -05:00
Donald Sharp
09339809a0
lib: Remove include of linux specific version.h
...
We apparently do not use it and looking at what this
file actually includes, we should not be including this
at all.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:47 -05:00
Donald Sharp
e1f5ddd0b7
bgpd: Remove extraneous include of version.h
...
It's not needed in these compiles. So let's remove it.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:47 -05:00
Donald Sharp
eea0ea3801
pimd: Remove extraneous include of version.h
...
It's not needed in these compiles. So let's remove it.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:46 -05:00
Donald Sharp
8974060760
pathd: Remove extraneous include of version.h
...
It's not needed in these compiles. So let's remove it.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:46 -05:00
Donald Sharp
988638bd8d
bgpd: Remove extraneous include of version.h
...
It's not needed in these compiles. So let's remove it.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-10 09:07:46 -05:00
Donald Sharp
7809df2064
Merge pull request #12776 from patrasar/Issue_12755
...
pim6d: Modify "show ipv6 mld join json" o/p
2023-02-10 08:07:32 -05:00
Donald Sharp
0e7864be7b
Merge pull request #12757 from opensourcerouting/fix/advance_versions_for_packages
...
tools: Bump versions for Redhat and Debian packages in changelogs
2023-02-09 19:36:54 -05:00
Donald Sharp
bda32ba92a
Merge pull request #12762 from sri-mohan1/sri-bable
...
babeld: changes for code maintainability
2023-02-09 19:36:08 -05:00
Donald Sharp
787b4fe469
Merge pull request #12782 from opensourcerouting/fix/bgpd_aspath_str_crash
...
bgpd: Intern default-originate attributes to avoid use-after-free
2023-02-09 19:25:19 -05:00
Donald Sharp
041554dc00
Merge pull request #12781 from opensourcerouting/fix/memory_leak
...
lib: Release memory of YANG translation module on error
2023-02-09 19:25:05 -05:00
Donatas Abraitis
ecf82aa41e
lib: Free dnode before returning if YANG translator model is already loaded
...
Seems just a missed one because at `goto error` we release dnode.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-09 23:14:46 +02:00
Donatas Abraitis
35b7ce08a8
tests: Check if BGP default-originate withdraw works correctly
...
And also do not crash when we do `clear ip bgp ...`.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-09 22:57:42 +02:00
Donatas Abraitis
e9340ff429
bgpd: Intern default-originate attributes to avoid use-after-free
...
When we receive a default route from a peer and we originate default route
using `neighbor default-originate`, we do not track of struct attr we use,
and when we do `no neighbor default-originate` we withdraw our generated
default route, but we announce default-route from the peer.
After we do this, we unintern aspath (which was used for default-originate),
BUT it was used also for peer's default route we received.
And here we have a use-after-free crash, because bgp_process_main_one()
reaps old paths that are marked as BGP_PATH_REMOVED with aspath->refcnt > 0,
but here it's 0.
```
0 0x55c24bbcd022 in aspath_key_make bgpd/bgp_aspath.c:2070
1 0x55c24b8f1140 in attrhash_key_make bgpd/bgp_attr.c:777
2 0x7f52322e66c9 in hash_release lib/hash.c:220
3 0x55c24b8f6017 in bgp_attr_unintern bgpd/bgp_attr.c:1271
4 0x55c24ba0acaa in bgp_path_info_free_with_caller bgpd/bgp_route.c:283
5 0x55c24ba0a7de in bgp_path_info_unlock bgpd/bgp_route.c:309
6 0x55c24ba0af6d in bgp_path_info_reap bgpd/bgp_route.c:426
7 0x55c24ba17b9a in bgp_process_main_one bgpd/bgp_route.c:3333
8 0x55c24ba18a1d in bgp_process_wq bgpd/bgp_route.c:3425
9 0x7f52323c2cd5 in work_queue_run lib/workqueue.c:282
10 0x7f52323aab92 in thread_call lib/thread.c:2006
11 0x7f5232300dc7 in frr_run lib/libfrr.c:1198
12 0x55c24b8ea792 in main bgpd/bgp_main.c:520
13 0x7f5231c3a082 in __libc_start_main ../csu/libc-start.c:308
14 0x55c24b8ef0bd in _start (/usr/lib/frr/bgpd+0x2c90bd)
```
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-09 22:29:25 +02:00
Donatas Abraitis
b9941b3fec
lib: Release memory of YANG translation module on error
...
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-09 18:01:17 +02:00
Olivier Dugeon
ad1327b3d4
Merge pull request #12730 from louis-6wind/fix-ext-te-metrics
...
Fix for Extended TE metrics
2023-02-09 15:12:41 +01:00
mobash-rasool
3e5da1fbae
Merge pull request #12773 from donaldsharp/pbr_table_values
...
pbrd: fix large tableids displayed as negative
2023-02-09 16:17:54 +05:30
Donatas Abraitis
f83956c06d
Merge pull request #12738 from taspelund/adj-rib-specific
...
Improvements to advertised/received/bestpath-routes commands
2023-02-09 11:02:11 +02:00
Sarita Patra
58971e1574
pim6d: Modify "show ipv6 mld join json" o/p
...
Currently "show ipv6 mld join json" o/p is
frr# show ipv6 mld joins json
{
"default":{
"ens192":{
"ff02:2":{
"::":{
"state":"JOIN",
"created":"00:01:50.595",
"lastSeen":"00:00:38.403",
}
}
}
}
}
Here, I modified the o/p as below for better understanding.
frr# show ipv6 mld joins json
{
"default":{
"vrf":"default",
"ens192":{
"ff02::2":{
"*":{
"state":"JOIN",
"created":"00:00:42.766",
"lastSeen":"00:00:05.266"
}
}
}
}
}
Issue: #12755
Signed-off-by: Sarita Patra <saritap@vmware.com>
2023-02-09 00:14:24 -08:00
Wesley Coakley
8dc2001c91
pbrd: fix large tableids displayed as negative
...
Ticket: 2699411
Signed-off-by: Wesley Coakley <wcoakley@nvidia.com>
2023-02-08 16:28:27 -05:00
Trey Aspelund
200631aa65
doc: optional keyword info for bestpath-routes
...
Adds information about the optional keywords for the bestpath-routes
bgp show command.
Signed-off-by: Trey Aspelund <taspelund@nvidia.com>
2023-02-08 21:07:02 +00:00
Trey Aspelund
bda4a61288
doc: prefix match for advertised/received-routes
...
Doc changes for new prefix matching.
Signed-off-by: Trey Aspelund <taspelund@nvidia.com>
2023-02-08 21:07:02 +00:00
Trey Aspelund
3880b4ece4
bgpd: prefix match for advertised/received-routes
...
This introduces the option for a user to lookup one specific prefix in
the advertised-routes or received-routes table of a peer.
Signed-off-by: Trey Aspelund <taspelund@nvidia.com>
2023-02-08 21:06:10 +00:00
Trey Aspelund
aa9bf57eb8
bgpd: add 'detail' option to bestpath-routes
...
Introduce 'detail' keyword for 'show bgp <afi> <safi> bestpath-routes'.
Signed-off-by: Trey Aspelund <taspelund@nvidia.com>
2023-02-08 20:55:00 +00:00
Donatas Abraitis
5a77b9d61d
Merge pull request #12769 from donaldsharp/missing_syslog
...
tools: Fix missing pbrd in rsyslog.d 45-frr.conf file
2023-02-08 22:40:32 +02:00
Donatas Abraitis
b9f352f0ab
Merge pull request #12768 from louis-6wind/fix-grep-vpnv4-noretain
...
tests: do not use exclude grep
2023-02-08 21:53:19 +02:00
Donald Sharp
7386031781
tools: Fix missing pbrd in rsyslog.d 45-frr.conf file
...
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-02-08 13:04:01 -05:00
Louis Scalbert
a8d6faa986
tests: do not use exclude grep
...
Filter out keys in JSON output with "grep -v" does not work when JSON
does not use the pretty format.
Use native python code to filter out keys.
Fixes: 6c13bd5744
("topotests: fix bgp_vpnv4_noretain")
Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-02-08 12:05:15 +01:00
Donatas Abraitis
e7765b81ce
Merge pull request #12761 from anlancs/fix/bgpd-crash-evpn-vni-both-rts
...
bgpd: fix use-after-free crash for evpn
2023-02-08 10:07:07 +02:00
Donatas Abraitis
197c3a768c
Merge pull request #12654 from Pdoijode/evpn-evi-detail-json-changes
...
zebra: fix JSON fields for show evpn vni detail
2023-02-07 23:31:53 +02:00
Donatas Abraitis
96475dfde9
Merge pull request #12707 from donaldsharp/missed_enums
...
Missed enums
2023-02-07 22:22:27 +02:00
Donatas Abraitis
6f5808a305
tools: Bump versions for Redhat and Debian packages in changelogs
...
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-07 22:17:49 +02:00
Donald Sharp
bbdbc828b3
Merge pull request #12759 from opensourcerouting/fix/revalidate_commit_on_pr_update
...
tools: Revalidate commits when PR is updated
2023-02-07 15:13:50 -05:00
Donatas Abraitis
8428482abb
tools: Fetch more commits for commitlint to validate the commit
...
Note: It's necessary that you specify the fetch-depth argument to
actions/checkout@v2 step. By default they fetch only latest commit of the
branch, but we need more commits since we validate a range of commit messages.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-07 22:03:42 +02:00
Donatas Abraitis
0a18c855fd
tools: Revalidate commits when PR is updated
...
Trigger GH action also if labeled, unlabeled.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-07 21:55:31 +02:00
Donald Sharp
48d4629d1b
Merge pull request #12756 from opensourcerouting/fix/add_build_to_commits
...
tools: Add `build` as a valid prefix for commit messages
2023-02-07 14:50:00 -05:00
Donatas Abraitis
5e66e742d7
tools: Add build
as a valid prefix for commit messages
...
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-07 21:41:20 +02:00
Donatas Abraitis
16c38045b1
build: FRR 9.0 development version
...
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-07 21:25:42 +02:00
Jafar Al-Gharaibeh
2285f5aca8
Merge pull request #12722 from opensourcerouting/vim-xref
...
tools: add `GotoXref` vim script
2023-02-07 10:43:27 -06:00
Jafar Al-Gharaibeh
6e1ae0137d
Merge pull request #12715 from opensourcerouting/fix/contribution_guid_squash_random_commits
...
Commits hygiene
2023-02-07 10:42:53 -06:00
Russ White
0b1a6ca322
Merge pull request #12748 from opensourcerouting/fix/route_map_vpn_import
...
tests: Check if route-map vpn import basic funtionality works fine
2023-02-07 11:40:03 -05:00
Russ White
24caf3069b
Merge pull request #12720 from opensourcerouting/fix/ecommunity_ipv6_missing_token
...
bgpd: ecommunity_token_rt6 is not handled
2023-02-07 09:21:07 -05:00
Donatas Abraitis
b313408c01
Merge pull request #12741 from thesamesam/missing-time
...
pceplib: add <time.h> include for time_t
2023-02-07 11:05:46 +02:00
sri-mohan1
44fab24d25
babeld: changes for code maintainability
...
these changes are for improving the code maintainability and readability
Signed-off-by: sri-mohan1 <sri.mohan@samsung.com>
2023-02-07 13:35:04 +05:30
Sam James
3c8c112df4
pceplib: add <time.h> include for time_t
...
Fixes build on musl. Used for time_t in the header.
Bug: https://bugs.gentoo.org/862558
Signed-off-by: Sam James <sam@gentoo.org>
2023-02-06 20:31:22 +00:00
Donatas Abraitis
4ee5265aa7
bgpd: Add more context in logs about from where to where routes are leaked
...
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-06 18:44:11 +02:00
Donatas Abraitis
1aa2c93e2c
bgpd: Drop struct bgp from vpn_leak_to_vrf_withdraw()
...
Not used at all, just drop it.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-06 18:44:11 +02:00
Donatas Abraitis
1c2ba4a23f
tests: Check if route-map vpn import
basic funtionality works fine
...
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-02-06 18:44:10 +02:00