Commit Graph

32927 Commits

Author SHA1 Message Date
Donatas Abraitis
7d5873cdc4 bgpd: Make sure we have enough data to read restart time and flags for GR cap
Just a safety check to avoid out of bound reading.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-30 17:29:11 +03:00
Donatas Abraitis
23fa9b4107 tests: Check if GR settings can be changed via BGP dynamic capabilities
restart-time and/or notification support.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-30 17:18:53 +03:00
Donatas Abraitis
d64a4ec490 doc: GR restart time, notifcation flag can be changed via BGP dynamic cap
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-30 17:18:53 +03:00
Donatas Abraitis
6cc60e303f bgpd: Handle Graceful-Restart capability with dynamic capability
Graceful-Restart restart time is exchanged using OPEN messages. In order to
reduce restart time before doing an actual graceful restart, it might be useful
to increase the time, but this is not possible without resetting the session.

With this change, it's possible to send dynamic capability with a new value, and
GR will respect a new reset time value.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-30 17:18:53 +03:00
Donald Sharp
15a5de185c
Merge pull request #14300 from opensourcerouting/fix/set_role_as_undefined_when_capability_unset
bgpd: Unset role when receiving UNSET action for dynamic capability
2023-08-30 09:22:12 -04:00
Mark Stapp
6ed47401a7
Merge pull request #14284 from opensourcerouting/fix/bgp_dynamic_capability_zlog
bgpd: Use zlog_err and not zlog_info when we have an error for dynamic capability
2023-08-30 08:00:45 -04:00
Donatas Abraitis
1f70ceae0a bgpd: Unset role when receiving UNSET action for dynamic capability
Capability was unset, but forgot to unset the role.

Fixes: 5ad080d37a ("bgpd: Handle Role capability via dynamic capabilities for SET/UNSET properly")

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-30 12:33:16 +03:00
Jafar Al-Gharaibeh
497584ac48
Merge pull request #14288 from opensourcerouting/fix/warn_the_user_if_keepalive_was_changed
bgpd: Add a warning for the operator that keepalive was changed
2023-08-29 22:30:03 -05:00
Chirag Shah
f80262b507
Merge pull request #14290 from opensourcerouting/fix/bgpd_encap_tunnel_handling
bgpd: Use treat-as-withdraw for tunnel encapsulation attribute
2023-08-29 16:51:53 -07:00
Donatas Abraitis
83ed05c7d3 bgpd: Use zlog_err and not zlog_info when we have an error for dynamic capability
Also change the outputs a bit to be consistent and more detailed.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-29 22:15:55 +03:00
Donatas Abraitis
bcb6b58d95 bgpd: Use treat-as-withdraw for tunnel encapsulation attribute
Before this path we used session reset method, which is discouraged by rfc7606.

Handle this as rfc requires.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-29 16:09:26 +03:00
Russ White
dccd9ab848
Merge pull request #14243 from opensourcerouting/fix/bgpd_ebgp_multihop_vty_out
bgpd: Do not explicitly print MAXTTL value for ebgp-multihop vty output
2023-08-29 08:57:51 -04:00
Donatas Abraitis
7c4ed2a719 bgpd: Add a warning for the operator that keepalive was changed
```
donatas-pc(config-router)# timers bgp 8 12
% keeplive value 8 is larger than 1/3 of the holdtime, setting to 4
donatas-pc(config-router)# do sh run | include timers bgp
 timers bgp 4 12
donatas-pc(config-router)#
```

Closes https://github.com/FRRouting/frr/issues/14287

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-29 15:14:07 +03:00
Russ White
3bd869f63b
Merge pull request #14283 from opensourcerouting/fix/dynamic_capability_role_unset
bgpd: Handle Role capability via dynamic capabilities for SET/UNSET properly
2023-08-29 08:07:18 -04:00
Russ White
2c2b16fe31
Merge pull request #14274 from opensourcerouting/fix/staticd_with_blackhole_nexthop_handling
staticd: Accept full blackhole typed keywords for ip_route_cmd
2023-08-29 08:06:49 -04:00
Russ White
6486741520
Merge pull request #14262 from Keelan10/ospfd6-memleak
ospf6d: Free Newly Created LSA when Non-Self-Originated Grace LSA is …
2023-08-29 08:06:04 -04:00
Russ White
fa0dd3d6d0
Merge pull request #14252 from LabNConsulting/ziemba-pbr-bugfix-match-dscp-numeric
pbrd: fix dscp field value computation
2023-08-29 08:05:17 -04:00
Russ White
72ff639da5
Merge pull request #14257 from Keelan10/lib-memleak
lib: Fix memory leaks in LS Update Functions
2023-08-29 08:04:01 -04:00
Donatas Abraitis
5ad080d37a bgpd: Handle Role capability via dynamic capabilities for SET/UNSET properly
It was missed to handle UNSET Role capability using dynamic capabilities.

Also move length check before actually handling Role capability.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-29 10:10:04 +03:00
Russ White
c4e030ac87
Merge pull request #14276 from donaldsharp/bgp_fsm_problemos
Bgp fsm problemos
2023-08-26 15:24:56 -04:00
Donald Sharp
4d22b41321
Merge pull request #14256 from rodecker/rt-table-id
zebra: Make main routing table (RT_TABLE_MAIN) configurable
2023-08-25 17:33:52 -04:00
Donatas Abraitis
834463a412
Merge pull request #14264 from lkClare/master_0823
bgpd: fix bug in a place about label validation
2023-08-25 18:16:50 +03:00
Donald Sharp
5160672d99 bgpd: Prevent use after free
When bgp_stop finishes and it deletes the peer it is sending
back a return code stating that the peer was deleted, but
the code was operating like it was not deleted and continued
to access the data structure.  Fix.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-08-25 10:43:56 -04:00
Donald Sharp
d4a9b103b7 bgpd: bgp_event_update switch to a switch
The return code from a event handling perspective
is an enum.  Let's intentionally make it a switch
so that all cases are ensured to be covered now
and in the future.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-08-25 10:28:02 -04:00
Donald Sharp
8dd97a7404 bgpd: bgp_event_update mixes enum's with a non-enum
Straighten out the code to not mix the two.  Especially
since bgp was assigning non enum values to the enum.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-08-25 10:03:14 -04:00
Donatas Abraitis
76b2bc97e7 staticd: Accept full blackhole typed keywords for ip_route_cmd
Before this patch we allow entering next-hop interface address as any string.

Like, we can type: `ip route 10.10.10.10/32 bla`, but this will create a blackhole
route instead of using an interface `bla`.

The same is with reject.

After the patch:

```
$ vtysh -c 'con' -c 'ip route 10.10.10.100/32 bla'
ERROR: SET_CONFIG request failed, Error: nexthop interface name must be (reject, blackhole)

$ ip link show dev bla
472: bla: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000
    link/ether fa:45:bd:f1:f8:f0 brd ff:ff:ff:ff:ff:ff

$ vtysh -c 'sh run | include ip route'
$ vtysh -c 'con' -c 'ip route 10.10.10.100/32 blac'
$ vtysh -c 'sh run | include ip route'
ip route 10.10.10.100/32 blackhole

$ vtysh -c 'con' -c 'no ip route 10.10.10.100/32 blac'
$ vtysh -c 'sh run | include ip route'
$ vtysh -c 'con' -c 'ip route 10.10.10.100/32 blackhole'
$ vtysh -c 'sh run | include ip route'
ip route 10.10.10.100/32 blackhole

$ vtysh -c 'con' -c 'no ip route 10.10.10.100/32 blackhole'
$ vtysh -c 'sh run | include ip route'
$ vtysh -c 'con' -c 'ip route 10.10.10.100/32 Null0'
$ vtysh -c 'sh run | include ip route'
ip route 10.10.10.100/32 Null0

$ vtysh -c 'con' -c 'no ip route 10.10.10.100/32 Null0'
$ vtysh -c 'sh run | include ip route'
$
```

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-25 12:00:33 +03:00
Donatas Abraitis
420b8ed540
Merge pull request #14253 from bigbanglwb/frr_master
configure.ac: fix protobuf config
2023-08-25 08:34:54 +03:00
Donald Sharp
42016422ce
Merge pull request #14260 from opensourcerouting/fix/do_not_process_nlri_if_attribute_len_is_0
bgpd: Do not process NLRIs if the attribute length is zero
2023-08-24 10:55:51 -04:00
Donald Sharp
673a11a54f
Merge pull request #14232 from opensourcerouting/fix/aigp_validation_bytes
bgpd: Make sure we have enough data to read two bytes when validating AIGP
2023-08-24 07:43:59 -04:00
Valerian_He
77f3d6e520 bgpd: fix bug in a place about label validation
Shouldn't validate the label after 'decode_label'. If we validate
the label after 'decode_label', even the 'MPLS_INVALID_LABEL' will
be valid then.

Signed-off-by: Valerian_He <1826906282@qq.com>
2023-08-24 02:17:06 +00:00
乐倚
9fbab41212 configure.ac: fix protobuf config
Bug description: frr_init load zebra_fpm.so error. Zebra can't
  find function `zfpm_protobuf_encode_route` in symbol table.

  Bug trigger condition ( CI have this set ):
    ./configure --enable-protobuf=no --enable-fpm=yes
    /usr/lib/frr/zebra -M fpm

  Cause: Macro `HAVE_PROTOBUF` and compile condition variable
  `HAVE_PROTOBUF`  in `configure.ac ` is not consistent. When
  configure `disable-protobuf`, compile condition variable
  `HAVE_PROTOBUF` is 0, but the macro is 1. It leads to zebra
  load protobuf module, but protobuf module is not linked.

  Fix: add a same condition statement to the macro define.

Signed-off-by: 乐倚 <lwb406054@alibaba-inc.com>
2023-08-23 08:43:28 +00:00
Donatas Abraitis
7090bf4307
Merge pull request #14255 from gromit1811/gromit1811-patch-1
debian: Don't install sample dplane plugin
2023-08-23 11:28:55 +03:00
Donatas Abraitis
5acbff964e
Merge pull request #14251 from donaldsharp/protodown_rc_issue
zebra: Prevent protodown_rc from going Bzonkas
2023-08-23 11:08:30 +03:00
Keelan10
4525f70737 ospf6d: Free Newly Created LSA when Non-Self-Originated Grace LSA is Discarded
The newly created LSA `new` is now properly freed to prevent memory leaks when
a non-self-originated Grace LSA which is not in LSDB is received.

The ASan leak log for reference:

```
Direct leak of 400 byte(s) in 2 object(s) allocated from:
    #0 0x7f70e984bd28 in __interceptor_calloc (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xded28)
    #1 0x7f70e92481c5 in qcalloc lib/memory.c:105
    #2 0x55b35068c975 in ospf6_lsa_alloc ospf6d/ospf6_lsa.c:710
    #3 0x55b35068c9f9 in ospf6_lsa_create ospf6d/ospf6_lsa.c:725
    #4 0x55b35065ab2c in ospf6_receive_lsa ospf6d/ospf6_flood.c:912
    #5 0x55b3506a1413 in ospf6_lsupdate_recv ospf6d/ospf6_message.c:1621
    #6 0x55b3506a1413 in ospf6_read_helper ospf6d/ospf6_message.c:1896
    #7 0x55b3506a1413 in ospf6_receive ospf6d/ospf6_message.c:1925
    #8 0x7f70e92e6ccb in event_call lib/event.c:1979
    #9 0x7f70e922b488 in frr_run lib/libfrr.c:1213
    #10 0x55b35064345e in main ospf6d/ospf6_main.c:250
    #11 0x7f70e8843c86 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21c86)

Indirect leak of 72 byte(s) in 2 object(s) allocated from:
    #0 0x7f70e984bb40 in __interceptor_malloc (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xdeb40)
    #1 0x7f70e9247ee5 in qmalloc lib/memory.c:100
    #2 0x55b35068c987 in ospf6_lsa_alloc ospf6d/ospf6_lsa.c:711
    #3 0x55b35068c9f9 in ospf6_lsa_create ospf6d/ospf6_lsa.c:725
    #4 0x55b35065ab2c in ospf6_receive_lsa ospf6d/ospf6_flood.c:912
    #5 0x55b3506a1413 in ospf6_lsupdate_recv ospf6d/ospf6_message.c:1621
    #6 0x55b3506a1413 in ospf6_read_helper ospf6d/ospf6_message.c:1896
    #7 0x55b3506a1413 in ospf6_receive ospf6d/ospf6_message.c:1925
    #8 0x7f70e92e6ccb in event_call lib/event.c:1979
    #9 0x7f70e922b488 in frr_run lib/libfrr.c:1213
    #10 0x55b35064345e in main ospf6d/ospf6_main.c:250
    #11 0x7f70e8843c86 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21c86)

SUMMARY: AddressSanitizer: 472 byte(s) leaked in 4 allocation(s).
```

Signed-off-by: Keelan Cannoo <keelan.cannoo@icloud.com>
2023-08-23 09:23:48 +04:00
Donatas Abraitis
28ccc24d38 bgpd: Do not process NLRIs if the attribute length is zero
```
3  0x00007f423aa42476 in __GI_raise (sig=sig@entry=11) at ../sysdeps/posix/raise.c:26
4  0x00007f423aef9740 in core_handler (signo=11, siginfo=0x7fffc414deb0, context=<optimized out>) at lib/sigevent.c:246
5  <signal handler called>
6  0x0000564dea2fc71e in route_set_aspath_prepend (rule=0x564debd66d50, prefix=0x7fffc414ea30, object=0x7fffc414e400)
    at bgpd/bgp_routemap.c:2258
7  0x00007f423aeec7e0 in route_map_apply_ext (map=<optimized out>, prefix=prefix@entry=0x7fffc414ea30,
    match_object=match_object@entry=0x7fffc414e400, set_object=set_object@entry=0x7fffc414e400, pref=pref@entry=0x0) at lib/routemap.c:2690
8  0x0000564dea2d277e in bgp_input_modifier (peer=peer@entry=0x7f4238f59010, p=p@entry=0x7fffc414ea30, attr=attr@entry=0x7fffc414e770,
    afi=afi@entry=AFI_IP, safi=safi@entry=SAFI_UNICAST, rmap_name=rmap_name@entry=0x0, label=0x0, num_labels=0, dest=0x564debdd5130)
    at bgpd/bgp_route.c:1772
9  0x0000564dea2df762 in bgp_update (peer=peer@entry=0x7f4238f59010, p=p@entry=0x7fffc414ea30, addpath_id=addpath_id@entry=0,
    attr=0x7fffc414eb50, afi=afi@entry=AFI_IP, safi=<optimized out>, safi@entry=SAFI_UNICAST, type=9, sub_type=0, prd=0x0, label=0x0,
    num_labels=0, soft_reconfig=0, evpn=0x0) at bgpd/bgp_route.c:4374
10 0x0000564dea2e2047 in bgp_nlri_parse_ip (peer=0x7f4238f59010, attr=attr@entry=0x7fffc414eb50, packet=0x7fffc414eaf0)
    at bgpd/bgp_route.c:6249
11 0x0000564dea2c5a58 in bgp_nlri_parse (peer=peer@entry=0x7f4238f59010, attr=attr@entry=0x7fffc414eb50,
    packet=packet@entry=0x7fffc414eaf0, mp_withdraw=mp_withdraw@entry=false) at bgpd/bgp_packet.c:339
12 0x0000564dea2c5d66 in bgp_update_receive (peer=peer@entry=0x7f4238f59010, size=size@entry=109) at bgpd/bgp_packet.c:2024
13 0x0000564dea2c901d in bgp_process_packet (thread=<optimized out>) at bgpd/bgp_packet.c:2933
14 0x00007f423af0bf71 in event_call (thread=thread@entry=0x7fffc414ee40) at lib/event.c:1995
15 0x00007f423aebb198 in frr_run (master=0x564deb73c670) at lib/libfrr.c:1213
16 0x0000564dea261b83 in main (argc=<optimized out>, argv=<optimized out>) at bgpd/bgp_main.c:505
```

With the configuration:

```
frr version 9.1-dev-MyOwnFRRVersion
frr defaults traditional
hostname ip-172-31-13-140
log file /tmp/debug.log
log syslog
service integrated-vtysh-config
!
debug bgp keepalives
debug bgp neighbor-events
debug bgp updates in
debug bgp updates out
!
router bgp 100
 bgp router-id 9.9.9.9
 no bgp ebgp-requires-policy
 bgp bestpath aigp
 neighbor 172.31.2.47 remote-as 200
 !
 address-family ipv4 unicast
  neighbor 172.31.2.47 default-originate
  neighbor 172.31.2.47 route-map RM_IN in
 exit-address-family
exit
!
route-map RM_IN permit 10
 set as-path prepend 200
exit
!
```

The issue is that we try to process NLRIs even if the attribute length is 0.

Later bgp_update() will handle route-maps and a crash occurs because all the
attributes are NULL, including aspath, where we dereference.

According to the RFC 4271:

A value of 0 indicates that neither the Network Layer
         Reachability Information field nor the Path Attribute field is
         present in this UPDATE message.

But with a fuzzed UPDATE message this can be faked. I think it's reasonable
to skip processing NLRIs if both update_len and attribute_len are 0.

Reported-by: Iggy Frankovic <iggyfran@amazon.com>
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2023-08-22 22:52:04 +03:00
Russ White
58ade1ba5d
Merge pull request #14217 from LabNConsulting/ziemba-pbr-action-drop
pbrd: add advisory flag PBR_ACTION_DROP
2023-08-22 12:16:01 -04:00
Russ White
020d8488cf
Merge pull request #14214 from opensourcerouting/fix/handle_rfc7606_attr_len_remaining_data
bgpd: Treat-as-withdraw attribute if remaining data is not enough
2023-08-22 12:15:24 -04:00
Russ White
30b0637172
Merge pull request #14142 from zays26/fix/zebra-assert
zebra: fix assert in process_subq_route
2023-08-22 10:25:59 -04:00
Russ White
8c90df0997
Merge pull request #14146 from opensourcerouting/ospfv3-auth-interop
OSPFv3 authentication trailer interop
2023-08-22 10:25:24 -04:00
Martin Pels
4d96ce1b4d zebra: Make main routing table (RT_TABLE_MAIN) configurable
Signed-off-by: Martin Pels <mpels@ripe.net>
2023-08-22 15:29:07 +02:00
Keelan10
400ec19919 lib: Fix memory leaks in LS Update Functions
Previously when updating vertices, edges and subnets, when no update was required
due to existing value matching the new one, memory associated with the new object
was not being freed leading to memory leaks. This commit fixes memory leak by
freeing memory associated with new object when update is unnecessary.

The ASan leak log for reference:

```
Direct leak of 312 byte(s) in 3 object(s) allocated from:
    #0 0x7faf3afbfa37 in __interceptor_calloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:154
    #1 0x7faf3ab5dbcf in qcalloc ../lib/memory.c:105
    #2 0x7faf3ab42e00 in ls_parse_prefix ../lib/link_state.c:1323
    #3 0x7faf3ab43c87 in ls_parse_msg ../lib/link_state.c:1373
    #4 0x7faf3ab476a5 in ls_stream2ted ../lib/link_state.c:1885
    #5 0x564e045046aa in sharp_opaque_handler ../sharpd/sharp_zebra.c:792
    #6 0x7faf3aca35a9 in zclient_read ../lib/zclient.c:4410
    #7 0x7faf3ac47474 in event_call ../lib/event.c:1979
    #8 0x7faf3ab318b4 in frr_run ../lib/libfrr.c:1213
    #9 0x564e044fdc6f in main ../sharpd/sharp_main.c:177
    #10 0x7faf3a6f4d8f in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58

SUMMARY: AddressSanitizer: 312 byte(s) leaked in 3 allocation(s).
```

Signed-off-by: Keelan Cannoo <keelan.cannoo@icloud.com>
2023-08-22 17:19:51 +04:00
Donald Sharp
9b4a9d17e2
Merge pull request #14239 from Keelan10/fix-cspf-leak
lib: Clear Computed Path Pointer to Destination on Clean
2023-08-22 07:53:57 -04:00
Martin Buck
c0008f8429
debian: Don't install sample dplane plugin
Without this, the Debian package build fails because dplane_sample_plugin.so gets compiled but not installed.

Signed-off-by: Martin Buck <mb-tmp-tvguho.pbz@gromit.dyndns.org>
2023-08-22 10:57:47 +02:00
G. Paul Ziemba
1efae6b537 pbrd: fix dscp field value computation
Signed-off-by: G. Paul Ziemba <paulz@labn.net>
2023-08-21 13:27:50 -07:00
Donald Sharp
c937582491 zebra: Prevent protodown_rc from going Bzonkas
The code that handles the protodown_rc setting for
VRRP interfaces in zebra is sending a interface
to be set into a protodown state *before* the
interface has been learned by the kernel.  Resulting
in crashes when the data plane sends the ctx back
to us saying hey man you are uncool.

Additionally change the protodown code to refuse
to send any protodown_rc codes *until* the interface
has actually been learned about from the kernel.

Ticket: 3582375
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-08-21 15:49:09 -04:00
Donatas Abraitis
451fb24b17
Merge pull request #8790 from donaldsharp/peer_connection
Peer connection
2023-08-21 20:22:53 +03:00
Donald Sharp
ff4c767a31
Merge pull request #14241 from opensourcerouting/fix/software_version_capability_handling_len
bgpd: Check the length of the rcv software version
2023-08-21 09:33:18 -04:00
Donald Sharp
c2b0d6a08f
Merge pull request #14245 from opensourcerouting/fix/check_if_the_first_byte_is_not_null_orf
bgpd: Don't read the first byte of ORF header if we are ahead of stream
2023-08-21 09:32:32 -04:00
Donatas Abraitis
ccc3c6c9db
Merge pull request #14244 from donaldsharp/static_simple
tests: static_simple gives up after 3 seconds
2023-08-21 11:53:45 +03:00
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