The FRRouting Protocol Suite
Find a file
Keelan10 0629ad01d4 lib: Clear Computed Path Pointer to Destination on Clean
This commit ensures proper cleanup by clearing the `algo->pdst` pointer if it points to a path that is being deleted.
It addresses memory leaks by freeing memory held by `algo->pdst` that might not have been released during the cleanup of processed paths.

The ASan leak log for reference:

```
Direct leak of 96 byte(s) in 1 object(s) allocated from:
    #0 0x7fbffcec9a37 in __interceptor_calloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:154
    #1 0x7fbffca67a81 in qcalloc ../lib/memory.c:105
    #2 0x7fbffc9d1a54 in cpath_new ../lib/cspf.c:44
    #3 0x7fbffc9d2829 in cspf_init ../lib/cspf.c:256
    #4 0x7fbffc9d295d in cspf_init_v4 ../lib/cspf.c:287
    #5 0x5601dcd34d3f in show_sharp_cspf_magic ../sharpd/sharp_vty.c:1262
    #6 0x5601dcd2c2be in show_sharp_cspf sharpd/sharp_vty_clippy.c:1869
    #7 0x7fbffc9afd61 in cmd_execute_command_real ../lib/command.c:993
    #8 0x7fbffc9b00ee in cmd_execute_command ../lib/command.c:1052
    #9 0x7fbffc9b0dc0 in cmd_execute ../lib/command.c:1218
    #10 0x7fbffcb611c7 in vty_command ../lib/vty.c:591
    #11 0x7fbffcb660ac in vty_execute ../lib/vty.c:1354
    #12 0x7fbffcb6c4aa in vtysh_read ../lib/vty.c:2362
    #13 0x7fbffcb51324 in event_call ../lib/event.c:1979
    #14 0x7fbffca3b872 in frr_run ../lib/libfrr.c:1213
    #15 0x5601dcd11c6f in main ../sharpd/sharp_main.c:177
    #16 0x7fbffc5ffd8f in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58

Indirect leak of 40 byte(s) in 1 object(s) allocated from:
    #0 0x7fbffcec9a37 in __interceptor_calloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:154
    #1 0x7fbffca67a81 in qcalloc ../lib/memory.c:105
    #2 0x7fbffca3c108 in list_new ../lib/linklist.c:49
    #3 0x7fbffc9d1acc in cpath_new ../lib/cspf.c:47
    #4 0x7fbffc9d2829 in cspf_init ../lib/cspf.c:256
    #5 0x7fbffc9d295d in cspf_init_v4 ../lib/cspf.c:287
    #6 0x5601dcd34d3f in show_sharp_cspf_magic ../sharpd/sharp_vty.c:1262
    #7 0x5601dcd2c2be in show_sharp_cspf sharpd/sharp_vty_clippy.c:1869
    #8 0x7fbffc9afd61 in cmd_execute_command_real ../lib/command.c:993
    #9 0x7fbffc9b00ee in cmd_execute_command ../lib/command.c:1052
    #10 0x7fbffc9b0dc0 in cmd_execute ../lib/command.c:1218
    #11 0x7fbffcb611c7 in vty_command ../lib/vty.c:591
    #12 0x7fbffcb660ac in vty_execute ../lib/vty.c:1354
    #13 0x7fbffcb6c4aa in vtysh_read ../lib/vty.c:2362
    #14 0x7fbffcb51324 in event_call ../lib/event.c:1979
    #15 0x7fbffca3b872 in frr_run ../lib/libfrr.c:1213
    #16 0x5601dcd11c6f in main ../sharpd/sharp_main.c:177
    #17 0x7fbffc5ffd8f in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58

```

Signed-off-by: Keelan Cannoo <keelan.cannoo@icloud.com>
2023-08-21 07:36:39 +04:00
.github github: Add rebase label on PR if it's > 50 commits behind 2023-05-09 09:37:23 +03:00
alpine docker: Use openssl instead of libressl 2023-07-31 11:04:30 +03:00
babeld Merge pull request #13333 from donaldsharp/vrf_bitmap_cleanup 2023-07-04 22:11:11 +03:00
bfdd bfdd: add debug flag around log 2023-07-28 12:38:02 -04:00
bgpd bgpd: Free memory in set_aspath_exclude_access_list 2023-08-19 14:00:17 +04:00
debian debian: Add missing protobuf dependency 2023-08-01 00:48:26 +02:00
doc Merge pull request #14189 from donaldsharp/do_not_use_system_calls 2023-08-13 16:02:17 -05:00
docker docker: Install the apk packages regardless of the platform 2023-07-31 11:05:15 +03:00
eigrpd * : include event ptr in event_execute api 2023-07-25 10:17:48 -04:00
fpm *: auto-convert to SPDX License IDs 2023-02-09 14:09:11 +01:00
gdb *: Rename thread.[ch] to event.[ch] 2023-03-24 08:32:16 -04:00
grpc *: manual SPDX License ID conversions 2023-02-09 14:09:07 +01:00
include Merge pull request #12780 from opensourcerouting/spdx-license-id 2023-02-17 09:43:05 -05:00
isisd isisd: update Node-SID flag dynamically 2023-07-29 14:18:39 -03:00
ldpd ldpd: Stop and free synchronous Zebra client on destroy 2023-06-27 11:47:50 +03:00
lib lib: Clear Computed Path Pointer to Destination on Clean 2023-08-21 07:36:39 +04:00
m4 build: fix sed regex in Lua macro 2022-12-08 12:39:17 +01:00
mgmtd lib: mgmtd: only clear pending for the in-progress command 2023-07-14 18:24:30 -04:00
mlag build: fix AM_LDFLAGS usage (and gcov) 2021-07-21 17:10:08 +02:00
nhrpd nhrpd: clean up locals in route zapi api 2023-07-10 16:43:53 -04:00
ospf6d * : include event ptr in event_execute api 2023-07-25 10:17:48 -04:00
ospfclient *: Convert event.h to frrevent.h 2023-03-24 08:32:17 -04:00
ospfd ospfd: Delete q_space->vertex_list on No Backup Path 2023-08-19 18:38:14 +04:00
pathd pathd: Stop and free synchronous Zebra client on pathd termination 2023-06-26 16:31:53 +03:00
pbrd pbrd: address 230815 coverity: pbr_vty.c vrf_name 2023-08-18 11:19:05 -07:00
pceplib *: auto-convert to SPDX License IDs 2023-02-09 14:09:11 +01:00
pimd Merge pull request #14193 from donaldsharp/pim_vxlan_weirdness 2023-08-15 22:26:21 +05:30
pkgsrc mgmtd: Bringup MGMTD daemon and datastore module support 2023-03-21 22:08:32 -04:00
python mgmtd: fully implement debug flags for mgmtd and clients 2023-05-01 13:47:12 -04:00
qpb mgmtd: Bringup MGMTD daemon and datastore module support 2023-03-21 22:08:32 -04:00
redhat redhat: Require libyang 2.1.80 2023-07-20 21:54:22 +03:00
ripd Revert "ripd: Cleanup memory allocations on shutdown" 2023-06-15 17:43:40 +03:00
ripngd Merge pull request #13826 from opensourcerouting/fix/ripng_match_ipv6_acls 2023-06-27 11:31:23 -04:00
sharpd sharpd: allow sharpd to install non-recursive routes 2023-07-10 16:43:53 -04:00
snapcraft snapcraft: Use libyang 2.1.80 2023-07-20 21:46:38 +03:00
staticd staticd: fix comparison of nexthop-vrf 2023-08-04 18:24:51 +03:00
tests Merge pull request #14181 from opensourcerouting/fix/bgpd_labeled_unicast_set_explicit_null 2023-08-16 09:25:49 -04:00
tools tools: fix key chain reload removal 2023-07-27 10:47:23 -03:00
vrrpd Merge pull request #13731 from cyberstorm-mauritius/cid1519841 2023-06-21 23:15:41 +05:30
vtysh vtysh: Print uniq lines when parsing no service ... 2023-08-11 18:25:43 +03:00
watchfrr *: Convert event.h to frrevent.h 2023-03-24 08:32:17 -04:00
yang zebra, yang: add an mpls leaf to interface 2023-08-10 18:13:21 +02:00
zebra Merge pull request #14223 from donaldsharp/interface_fies 2023-08-18 11:56:20 -04:00
.clang-format lib: add dynamic array type 2023-06-27 18:00:56 -04:00
.dockerignore docker: Make docker image on CentOS 7 2019-11-26 19:29:30 +00:00
.flake8 style: add format checker config that matches FRR style standards 2023-04-18 05:18:26 -04:00
.git-blame-ignore-revs tools: Ignore mass renaming of topotests for git blame 2021-05-11 14:14:26 +03:00
.gitignore doc: configure: add configure option to generate .ccls file 2023-05-18 09:32:32 -04:00
.isort.cfg style: add format checker config that matches FRR style standards 2023-04-18 05:18:26 -04:00
.pylintrc style: add format checker config that matches FRR style standards 2023-04-18 05:18:26 -04:00
.travis.yml lib: libyang2 add missed conversion 2021-05-17 22:13:59 -04:00
bootstrap.sh build: turn on automake warnings (& symlinks) 2021-04-21 15:42:37 +02:00
buildtest.sh *: manual SPDX License ID conversions 2023-02-09 14:09:07 +01:00
config.version.in build: carry --with-pkg-extra-version into tarballs 2018-10-24 15:11:50 +02:00
configure.ac build: disable warning for m$ extension use 2023-07-06 18:07:47 -04:00
COPYING *: sort out & explain licenses used in FRR 2023-02-09 12:46:13 +01:00
Makefile.am build: clean up mgmtd lib protobuf make syntax 2023-03-27 16:44:27 -04:00
README.md doc: Fix the link that points to Slack invitation in README 2022-03-24 13:13:37 +02:00
stamp-h.in Initial revision 2002-12-13 20:15:29 +00:00
version.h build: make builddir include path consistent 2021-04-21 15:42:33 +02:00

Icon

FRRouting

FRR is free software that implements and manages various IPv4 and IPv6 routing protocols. It runs on nearly all distributions of Linux and BSD and supports all modern CPU architectures.

FRR currently supports the following protocols:

  • BGP
  • OSPFv2
  • OSPFv3
  • RIPv1
  • RIPv2
  • RIPng
  • IS-IS
  • PIM-SM/MSDP
  • LDP
  • BFD
  • Babel
  • PBR
  • OpenFabric
  • VRRP
  • EIGRP (alpha)
  • NHRP (alpha)

Installation & Use

For source tarballs, see the releases page.

For Debian and its derivatives, use the APT repository at https://deb.frrouting.org/.

Instructions on building and installing from source for supported platforms may be found in the developer docs.

Once installed, please refer to the user guide for instructions on use.

Community

The FRRouting email list server is located here and offers the following public lists:

Topic List
Development dev@lists.frrouting.org
Users & Operators frog@lists.frrouting.org
Announcements announce@lists.frrouting.org

For chat, we currently use Slack. You can join by clicking the "Slack" link under the Participate section of our website.

Contributing

FRR maintains developer's documentation which contains the project workflow and expectations for contributors. Some technical documentation on project internals is also available.

We welcome and appreciate all contributions, no matter how small!

Security

To report security issues, please use our security mailing list:

security [at] lists.frrouting.org