diff options
| author | Ankur Tyagi <ankur.tyagi85@gmail.com> | 2025-10-15 09:39:01 +1300 |
|---|---|---|
| committer | Anuj Mittal <anuj.mittal@intel.com> | 2025-10-30 14:43:33 +0800 |
| commit | 4bb1da31d59992cfe936417d52e38832ba957bc8 (patch) | |
| tree | a5558e2fd8d1ff5464e43adfd7c6bbe80f91dd57 | |
| parent | 393bb3e0a532edb917928fbb72eb0d3e521f73b3 (diff) | |
| download | meta-openembedded-4bb1da31d59992cfe936417d52e38832ba957bc8.tar.gz | |
frr: patch CVE-2024-44070
Details https://nvd.nist.gov/vuln/detail/CVE-2024-44070
Signed-off-by: Ankur Tyagi <ankur.tyagi85@gmail.com>
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
| -rw-r--r-- | meta-networking/recipes-protocols/frr/frr/CVE-2024-44070.patch | 54 | ||||
| -rw-r--r-- | meta-networking/recipes-protocols/frr/frr_9.1.bb | 1 |
2 files changed, 55 insertions, 0 deletions
diff --git a/meta-networking/recipes-protocols/frr/frr/CVE-2024-44070.patch b/meta-networking/recipes-protocols/frr/frr/CVE-2024-44070.patch new file mode 100644 index 0000000000..87bd16efa6 --- /dev/null +++ b/meta-networking/recipes-protocols/frr/frr/CVE-2024-44070.patch | |||
| @@ -0,0 +1,54 @@ | |||
| 1 | From 335dc7f0421dc5b59a50795f21f28bd92ed4ef12 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Donatas Abraitis <donatas@opensourcerouting.org> | ||
| 3 | Date: Wed, 31 Jul 2024 08:35:14 +0300 | ||
| 4 | Subject: [PATCH] bgpd: Check the actual remaining stream length before taking | ||
| 5 | TLV value | ||
| 6 | |||
| 7 | ``` | ||
| 8 | 0 0xb50b9f898028 in __sanitizer_print_stack_trace (/home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/.libs/bgpd+0x368028) (BuildId: 3292703ed7958b20076550c967f879db8dc27ca7) | ||
| 9 | 1 0xb50b9f7ed8e4 in fuzzer::PrintStackTrace() (/home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/.libs/bgpd+0x2bd8e4) (BuildId: 3292703ed7958b20076550c967f879db8dc27ca7) | ||
| 10 | 2 0xb50b9f7d4d9c in fuzzer::Fuzzer::CrashCallback() (/home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/.libs/bgpd+0x2a4d9c) (BuildId: 3292703ed7958b20076550c967f879db8dc27ca7) | ||
| 11 | 3 0xe0d12d7469cc (linux-vdso.so.1+0x9cc) (BuildId: 1a77697e9d723fe22246cfd7641b140c427b7e11) | ||
| 12 | 4 0xe0d12c88f1fc in __pthread_kill_implementation nptl/pthread_kill.c:43:17 | ||
| 13 | 5 0xe0d12c84a678 in gsignal signal/../sysdeps/posix/raise.c:26:13 | ||
| 14 | 6 0xe0d12c83712c in abort stdlib/abort.c:79:7 | ||
| 15 | 7 0xe0d12d214724 in _zlog_assert_failed /home/ubuntu/frr-public/frr_public_private-libfuzzer/lib/zlog.c:789:2 | ||
| 16 | 8 0xe0d12d1285e4 in stream_get /home/ubuntu/frr-public/frr_public_private-libfuzzer/lib/stream.c:324:3 | ||
| 17 | 9 0xb50b9f8e47c4 in bgp_attr_encap /home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/bgp_attr.c:2758:3 | ||
| 18 | 10 0xb50b9f8dcd38 in bgp_attr_parse /home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/bgp_attr.c:3783:10 | ||
| 19 | 11 0xb50b9faf74b4 in bgp_update_receive /home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/bgp_packet.c:2383:20 | ||
| 20 | 12 0xb50b9faf1dcc in bgp_process_packet /home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/bgp_packet.c:4075:11 | ||
| 21 | 13 0xb50b9f8c90d0 in LLVMFuzzerTestOneInput /home/ubuntu/frr-public/frr_public_private-libfuzzer/bgpd/bgp_main.c:582:3 | ||
| 22 | ``` | ||
| 23 | |||
| 24 | CVE: CVE-2024-44070 | ||
| 25 | Upstream-Status: Backport [https://github.com/FRRouting/frr/commit/21cd931a5f9303e12104c72ce31ca383c0c57514] | ||
| 26 | |||
| 27 | Reported-by: Iggy Frankovic <iggyfran@amazon.com> | ||
| 28 | Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org> | ||
| 29 | (cherry picked from commit 0998b38e4d61179441f90dd7e7fd6a3a8b7bd8c5) | ||
| 30 | (cherry picked from commit 21cd931a5f9303e12104c72ce31ca383c0c57514) | ||
| 31 | Signed-off-by: Ankur Tyagi <ankur.tyagi85@gmail.com> | ||
| 32 | --- | ||
| 33 | bgpd/bgp_attr.c | 8 ++++++++ | ||
| 34 | 1 file changed, 8 insertions(+) | ||
| 35 | |||
| 36 | diff --git a/bgpd/bgp_attr.c b/bgpd/bgp_attr.c | ||
| 37 | index 797f05d606..cc63251cc8 100644 | ||
| 38 | --- a/bgpd/bgp_attr.c | ||
| 39 | +++ b/bgpd/bgp_attr.c | ||
| 40 | @@ -2718,6 +2718,14 @@ static int bgp_attr_encap(struct bgp_attr_parser_args *args) | ||
| 41 | args->total); | ||
| 42 | } | ||
| 43 | |||
| 44 | + if (STREAM_READABLE(BGP_INPUT(peer)) < sublength) { | ||
| 45 | + zlog_err("Tunnel Encap attribute sub-tlv length %d exceeds remaining stream length %zu", | ||
| 46 | + sublength, STREAM_READABLE(BGP_INPUT(peer))); | ||
| 47 | + return bgp_attr_malformed(args, | ||
| 48 | + BGP_NOTIFY_UPDATE_OPT_ATTR_ERR, | ||
| 49 | + args->total); | ||
| 50 | + } | ||
| 51 | + | ||
| 52 | /* alloc and copy sub-tlv */ | ||
| 53 | /* TBD make sure these are freed when attributes are released */ | ||
| 54 | tlv = XCALLOC(MTYPE_ENCAP_TLV, | ||
diff --git a/meta-networking/recipes-protocols/frr/frr_9.1.bb b/meta-networking/recipes-protocols/frr/frr_9.1.bb index 7c1691259d..ce9876c79f 100644 --- a/meta-networking/recipes-protocols/frr/frr_9.1.bb +++ b/meta-networking/recipes-protocols/frr/frr_9.1.bb | |||
| @@ -18,6 +18,7 @@ SRC_URI = "git://github.com/FRRouting/frr.git;protocol=https;branch=stable/9.1 \ | |||
| 18 | file://CVE-2024-31951.patch \ | 18 | file://CVE-2024-31951.patch \ |
| 19 | file://CVE-2024-31948.patch \ | 19 | file://CVE-2024-31948.patch \ |
| 20 | file://CVE-2024-31949.patch \ | 20 | file://CVE-2024-31949.patch \ |
| 21 | file://CVE-2024-44070.patch \ | ||
| 21 | " | 22 | " |
| 22 | 23 | ||
| 23 | SRCREV = "ca2d6f0f1e000951224a18973cc1827f7f5215b5" | 24 | SRCREV = "ca2d6f0f1e000951224a18973cc1827f7f5215b5" |
