From patchwork Fri Oct 16 03:37:24 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hetvi Thakar -X (hthakar - E INFOCHIPS PRIVATE LIMITED at Cisco)" X-Patchwork-Id: 100943 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6F079CC6B2D for ; Fri, 16 Oct 2026 03:37:44 +0000 (UTC) Received: from rcdn-iport-4.cisco.com (rcdn-iport-4.cisco.com [173.37.86.75]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.13985.1792121859155516438 for ; Thu, 15 Oct 2026 20:37:39 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: message contains an insecure body length tag" header.i=@cisco.com header.s=iport01 header.b=VYJ0LpFD; spf=pass (domain: cisco.com, ip: 173.37.86.75, mailfrom: hthakar@cisco.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cisco.com; i=@cisco.com; l=8766; q=dns/txt; s=iport01; t=1792121859; x=1793331459; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=V7kBbMYt+97o5Xhnfmm4eO0MGWfwMK42Kf7vVBGcEJA=; b=VYJ0LpFDymd2o8vPR0vfCilP85lyGSN4M6utEFF5hrUVMQuxnin+lGwd Gav/Nwiu2ahRhahujP+/pUDKpB5zb6fMUXAquDg8nYPSoiy1SZVkr9QFZ /3GNkXJCcUtjgwdolQ0FmnevCbIozwFQi8wy5glbiBa7XGdcuhYeIPDYr VuW0ZErvK8K6G88kDB6PGDKloMx7j1z4QILgDyYtNbWexKoHXehxjAUA/ TmIkTmQywkWvUwRUMSLAmrjAmK33wgZ8kDzPeZIZ5dT0NAggsvM0LpXFU Xpgl/hQ1WbNsX/elLXOnvalC9W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Fc4ooOdaCkNEz vYJFmhWVSDA28WRwpvuH4GAhux7RCXqFJkUtnclyXTSCuwrBMiZBa7L/tRfmjw3g6iiH96HO JFfMmUpNkmdJUQUaz/7C7pm9AusrnnjczRboUi9rqss6G+Vxwt0uFToGIeOJIXbGJkJxy50o Eqeo3bWHQwTaeePwDOc7GCTu/GRow7kDdd6+LqQs6QCbEeo7msLBRsbUFG2rfW0hgu1XMhSA 0gV4TY1668q+UqmS9PwUxG1rDiDpBF0ZjZLO/cx5AfIzu/f5ByUQzBeCDVAc9ch8sQxQFTGy 2O0oj8gPhQ32JX9dJ5X3u78Qe+aUcTNEVI/WA== IronPort-HdrOrdr: A9a23:yZn3kKsHeSOFSd6xAVswGbbG7skDWtV00zEX/kB9WHVpmwKj+P xG+85rsCMc5wxxZJhNo7290cq7MBHhHOBOgbX5VI3KNGKNhILCFu9fBOXZrwEIMheOktK1rZ 0QEJRWOZnXEUVwi9r87U2TFtYtx8TCzYWT7N2uqEuEiWpRGthdB8ATMHf8LnFL X-Talos-CUID: 9a23:+RyNPGAFmejX4bb6E2pXrk85EeIvSXfM8i+LGH/7VUFOSpTAHA== X-Talos-MUID: 9a23:4UOmcg/E/VbWp4rjohteG2CQf5808YuxFUlQqoUPstCaJxNNJWmjoSviFw== X-IronPort-Anti-Spam-Filtered: true X-IronPort-AV: E=Sophos;i="6.27,161,1787011200"; d="scan'208";a="536195441" Received: from rcdn-l-core-02.cisco.com ([173.37.255.139]) by rcdn-iport-4.cisco.com with ESMTP/TLS/TLS_AES_256_GCM_SHA384; 16 Oct 2026 03:37:26 +0000 Received: from sjc-ads-5245.cisco.com (sjc-ads-5245.cisco.com [10.28.23.9]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by rcdn-l-core-02.cisco.com (Postfix) with ESMTPS id BB667180000F5; Fri, 16 Oct 2026 03:37:26 +0000 (GMT) Received: by sjc-ads-5245.cisco.com (Postfix, from userid 1887505) id 6316DCC1611; Thu, 15 Oct 2026 20:37:26 -0700 (PDT) From: "Hetvi Thakar -X (hthakar - E INFOCHIPS PRIVATE LIMITED at Cisco)" To: openembedded-core@lists.openembedded.org Cc: xe-linux-external@cisco.com Subject: [OE-core][wrynose][PATCH 1/3] lrzsz: fix CVE-2026-105841 Date: Thu, 15 Oct 2026 20:37:24 -0700 Message-Id: <20261016033726.426908-1-hthakar@cisco.com> X-Mailer: git-send-email 2.35.6 MIME-Version: 1.0 X-Auto-Response-Suppress: DR, OOF, AutoReply X-Outbound-Client-TLS: ANONYMOUS;sjc-ads-5245.cisco.com [10.28.23.9];TLSv1.3;TLS_AES_256_GCM_SHA384;256 X-Outbound-SMTP-Client: 10.28.23.9, sjc-ads-5245.cisco.com X-Outbound-Node: rcdn-l-core-02.cisco.com List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 16 Oct 2026 03:37:44 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/247906 From: Hetvi Thakar This patch applies the upstream fix as referenced in [2], using the commit shown in [1]. [1] https://github.com/UweOhse/lrzsz/commit/9eef71ce20fda2b345ef8431359aec96121215bd [2] https://www.vulncheck.com/advisories/lrzsz-before-0.13.0-os-command-injection-via-lrz-pipe-mode Signed-off-by: Hetvi Thakar --- .../lrzsz/lrzsz-0.12.20/CVE-2026-105841.patch | 267 ++++++++++++++++++ meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb | 1 + 2 files changed, 268 insertions(+) create mode 100644 meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105841.patch diff --git a/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105841.patch b/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105841.patch new file mode 100644 index 00000000000..268218fb8a6 --- /dev/null +++ b/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105841.patch @@ -0,0 +1,267 @@ +From 9eef71ce20fda2b345ef8431359aec96121215bd Mon Sep 17 00:00:00 2001 +From: Uwe Ohse at akiar +Date: Mon, 10 Aug 2026 17:55:28 +0200 +Subject: [PATCH] remove topipe 'feature' + +CVE: CVE-2026-105841 +Upstream-Status: Backport [https://github.com/UweOhse/lrzsz/commit/9eef71ce20fda2b345ef8431359aec96121215bd] + +Backport Changes: +- Retained sys2() and exec2() and their declarations because 0.12.20 + still calls them in its separate, opt-in ZCOMMAND handling. Removing + them as upstream does causes undefined references when linking lrz. +- Omitted NEWS because its 0.13.0 release-note hunk conflicts with the + 0.12.20 release history and is not needed for the security fix. + +(cherry picked from commit 9eef71ce20fda2b345ef8431359aec96121215bd) +Signed-off-by: Hetvi Thakar +--- + src/lrz.c | 193 ++++++++++++++++++++++-------------------------------- + 1 file changed, 79 insertions(+), 114 deletions(-) + +diff --git a/src/lrz.c b/src/lrz.c +index ae3c62d..9c08a3d 100644 +--- a/src/lrz.c ++++ b/src/lrz.c +@@ -76,7 +76,6 @@ int skip_if_not_found; + char *Pathname; + const char *program_name; /* the name by which we were called */ + +-int Topipe=0; + int MakeLCPathname=TRUE; /* make received pathname lower case */ + int Verbose=0; + int Quiet=0; /* overrides logic that would otherwise set verbose */ +@@ -803,9 +802,6 @@ fubar: + shortname ? shortname : "no.name", protname()); + #endif + canit(STDOUT_FILENO); +- if (Topipe && fout) { +- pclose(fout); return ERROR; +- } + if (fout) + fclose(fout); + +@@ -1286,111 +1282,89 @@ procheader(char *name, struct zm_fileinfo *zi) + if (!zmodem_requested && MakeLCPathname && !IsAnyLower(name_static) + && !(zi->mode&UNIXFILE)) + uncaps(name_static); +- if (Topipe > 0) { +- if (Pathname) +- free(Pathname); +- Pathname=malloc((PATH_MAX)*2); +- if (!Pathname) +- error(1,0,_("out of memory")); +- sprintf(Pathname, "%s %s", program_name+2, name_static); +- if (Verbose) { +- vstringf("%s: %s %s\n", +- _("Topipe"), +- Pathname, Thisbinary?"BIN":"ASCII"); +- } +- if ((fout=popen(Pathname, "w")) == NULL) +- return ERROR; +- } else { +- if (protocol==ZM_XMODEM) +- /* we don't have the filename yet */ +- return OK; /* dummy */ +- if (Pathname) +- free(Pathname); +- Pathname=malloc((PATH_MAX)*2); +- if (!Pathname) +- error(1,0,_("out of memory")); +- strcpy(Pathname, name_static); +- if (Verbose) { +- /* overwrite the "waiting to receive" line */ +- vstring("\r \r"); +- vstringf(_("Receiving: %s\n"), name_static); +- } +- checkpath(name_static); +- if (Nflag) +- { +- /* cast because we might not have a prototyp for strdup :-/ */ +- free(name_static); +- name_static=(char *) strdup("/dev/null"); +- if (!name_static) +- { +- fprintf(stderr,"%s: %s\n", program_name, _("out of memory")); +- exit(1); +- } +- } +-#ifdef OMEN +- /* looks like a security hole -- uwe */ +- if (name_static[0] == '!' || name_static[0] == '|') { +- if ( !(fout = popen(name_static+1, "w"))) { +- return ERROR; +- } +- Topipe = -1; return(OK); +- } +-#endif +- if (Thisbinary && zconv==ZCRESUM) { +- struct stat st; +- fout = fopen(name_static, "r+"); +- if (fout && 0==fstat(fileno(fout),&st)) +- { +- int can_resume=TRUE; +- if (zmanag==ZF1_ZMCRC) { +- int r=do_crc_check(fout,zi->bytes_total,st.st_size); +- if (r==ERROR) { +- fclose(fout); +- return ZFERR; +- } +- if (r==ZCRC_DIFFERS) { +- can_resume=FALSE; +- } +- } +- if ((unsigned long)st.st_size > zi->bytes_total) { +- can_resume=FALSE; +- } +- /* retransfer whole blocks */ +- zi->bytes_skipped = st.st_size & ~(1023); +- if (can_resume) { +- if (fseek(fout, (long) zi->bytes_skipped, SEEK_SET)) { +- fclose(fout); +- return ZFERR; +- } +- } +- else +- zi->bytes_skipped=0; /* resume impossible, file has changed */ +- goto buffer_it; +- } +- zi->bytes_skipped=0; +- if (fout) +- fclose(fout); +- } +- fout = fopen(name_static, openmode); ++ ++ if (protocol==ZM_XMODEM) ++ /* we don't have the filename yet */ ++ return OK; /* dummy */ ++ if (Pathname) ++ free(Pathname); ++ Pathname=malloc((PATH_MAX)*2); ++ if (!Pathname) ++ error(1,0,_("out of memory")); ++ strcpy(Pathname, name_static); ++ if (Verbose) { ++ /* overwrite the "waiting to receive" line */ ++ vstring("\r \r"); ++ vstringf(_("Receiving: %s\n"), name_static); ++ } ++ checkpath(name_static); ++ if (Nflag) ++ { ++ /* cast because we might not have a prototyp for strdup :-/ */ ++ free(name_static); ++ name_static=(char *) strdup("/dev/null"); ++ if (!name_static) ++ { ++ fprintf(stderr,"%s: %s\n", program_name, _("out of memory")); ++ exit(1); ++ } ++ } ++ ++ if (Thisbinary && zconv==ZCRESUM) { ++ struct stat st; ++ fout = fopen(name_static, "r+"); ++ if (fout && 0==fstat(fileno(fout),&st)) ++ { ++ int can_resume=TRUE; ++ if (zmanag==ZF1_ZMCRC) { ++ int r=do_crc_check(fout,zi->bytes_total,st.st_size); ++ if (r==ERROR) { ++ fclose(fout); ++ return ZFERR; ++ } ++ if (r==ZCRC_DIFFERS) { ++ can_resume=FALSE; ++ } ++ } ++ if ((unsigned long)st.st_size > zi->bytes_total) { ++ can_resume=FALSE; ++ } ++ /* retransfer whole blocks */ ++ zi->bytes_skipped = st.st_size & ~(1023); ++ if (can_resume) { ++ if (fseek(fout, (long) zi->bytes_skipped, SEEK_SET)) { ++ fclose(fout); ++ return ZFERR; ++ } ++ } ++ else ++ zi->bytes_skipped=0; /* resume impossible, file has changed */ ++ goto buffer_it; ++ } ++ zi->bytes_skipped=0; ++ if (fout) ++ fclose(fout); ++ } ++ fout = fopen(name_static, openmode); + #ifdef ENABLE_MKDIR +- if ( !fout && Restricted < 2) { +- if (make_dirs(name_static)) +- fout = fopen(name_static, openmode); +- } ++ if ( !fout && Restricted < 2) { ++ if (make_dirs(name_static)) ++ fout = fopen(name_static, openmode); ++ } + #endif +- if ( !fout) +- { ++ if ( !fout) ++ { + #ifdef ENABLE_SYSLOG +- int e=errno; ++ int e=errno; + #endif +- zpfatal(_("cannot open %s"), name_static); +- DO_SYSLOG((LOG_ERR,"%s: cannot open: %s", +- protname(),strerror(e))); +- return ERROR; +- } +- } ++ zpfatal(_("cannot open %s"), name_static); ++ DO_SYSLOG((LOG_ERR,"%s: cannot open: %s", ++ protname(),strerror(e))); ++ return ERROR; ++ } ++ + buffer_it: +- if (Topipe == 0) { ++ { + static char *s=NULL; + static size_t last_length=0; + #if defined(F_GETFD) && defined(F_SETFD) && defined(O_SYNC) +@@ -1550,8 +1524,7 @@ report(int sct) + } + + /* +- * If called as [-][dir/../]vrzCOMMAND set Verbose to 1 +- * If called as [-][dir/../]rzCOMMAND set the pipe flag ++ * If called as [-][dir/../]vrz set Verbose to 1 + * If called as rb use YMODEM protocol + */ + static void +@@ -1576,8 +1549,6 @@ chkinvok(const char *s) + protocol=ZM_XMODEM; + if (s[0]=='r' && (s[1]=='b' || s[1]=='y')) + protocol=ZM_YMODEM; +- if (s[2] && protocol!=ZM_XMODEM) +- Topipe = 1; + } + + /* +@@ -2207,12 +2178,6 @@ static int + closeit(struct zm_fileinfo *zi) + { + int ret; +- if (Topipe) { +- if (pclose(fout)) { +- return ERROR; +- } +- return OK; +- } + if (in_tcpsync) { + rewind(fout); + if (!fgets(tcp_buf,sizeof(tcp_buf),fout)) { +-- +2.35.6 diff --git a/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb b/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb index 042cf7fbaca..403266743e0 100644 --- a/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb +++ b/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb @@ -21,6 +21,7 @@ SRC_URI = "https://www.ohse.de/uwe/releases/lrzsz-${PV}.tar.gz \ file://0001-Fix-cross-compilation-using-autoconf-detected-AR.patch \ file://0001-Fix-build-with-GCC-15.patch \ file://0001-lrzsz-convert-K-R-function-definitions-to-ANSI-C-pro.patch \ + file://CVE-2026-105841.patch \ " SRC_URI[sha256sum] = "c28b36b14bddb014d9e9c97c52459852f97bd405f89113f30bee45ed92728ff1" From patchwork Fri Oct 16 03:37:25 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hetvi Thakar -X (hthakar - E INFOCHIPS PRIVATE LIMITED at Cisco)" X-Patchwork-Id: 100941 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 82D01CC6B38 for ; Fri, 16 Oct 2026 03:37:34 +0000 (UTC) Received: from rcdn-iport-9.cisco.com (rcdn-iport-9.cisco.com [173.37.86.80]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.14209.1792121847719051683 for ; Thu, 15 Oct 2026 20:37:27 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: message contains an insecure body length tag" header.i=@cisco.com header.s=iport01 header.b=NwfLdXoV; spf=pass (domain: cisco.com, ip: 173.37.86.80, mailfrom: hthakar@cisco.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cisco.com; i=@cisco.com; l=4851; q=dns/txt; s=iport01; t=1792121847; x=1793331447; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=5psA1zkdgA75MOTdRmx+2AqFxFPNNKFxh5/4/OiD/k0=; b=NwfLdXoVa3ObXL9BoGe0kQp3xRKzM+XW+3RNRmxrS/odKevhd8pGUtuZ GJPEhYe6egwVwR1ETGE8wddAgyGRuJw+6lrH0G7FItTiY8/ZFMmyOWWLU ERqSDIx922oZArS5M49beioohcIsMFu4mpg35irFmUgy3kAcdXjH6Fmlc zAD9pauNsN46i1n7goozC0rnZ/GyXTRig6hRR2pUsdD4TLJ/AqCNkj5fZ rCU7oMQ1g1LuvsD0ihFGwupcC1ZRmnliFjZeCfTTR2O+tQ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SEPpqHLWyOE/hlgMK05FYMg59RQLFlMz K1bGW4BVQGAuPi22b3uH4GAhux7RCXqFJkUtnclyXTSCuwrBMiYBa7L/tRfmjw3g6iiH96HO JFfMmUpNkmdJUQTYj/7C7pm9AusrnnjczRboUi9rqss6G+Vxwt0uFToGIeOJ4baGJkPxC50o Er871+6LUgoE+CF0Gag+0+0hP7GgRLkDdd6+LqQs6QCbEeo7msLBRsbUFG2rfW0hgu1XMhSA 0gV4TY1668q+UqmS9PwUxG1rDiDpBF0ZjZLO/cx5AfIzu/f5ByUQzBfCDVAc9ch8sQxQFTGy 2O0oj8gPhQ32JX9dJ5X3u78Qe+aUcTNEVI/WA== IronPort-HdrOrdr: A9a23:EwnqJq50luZjAgIHbQPXwBDXdLJyesId70hD6qm+c3Nom6uj5q eTdZsgtCMc5Ax9ZJhko6HjBEDiewK5yXcK2+ks1N6ZNWGM0ldAbrsSiLcKqAePJ8SRzIJgPI 5bAs5D4aXLfDtHpPe/xhWkGNA9x9TC2qWpieDCi0pJd2hRGthdB8MTMHfhLqWwLzM2faYEKA == X-Talos-CUID: 9a23:8qnd22vku3FafmCdwI0qdBYf6IsrSmDv61roIXbpSlc3RIaESmCK+Lprxp8= X-Talos-MUID: 9a23:Xgr4IwXqV1uUjLfq/AX8v3JNbfVP3763VGUErI0EqsCYBDMlbg== X-IronPort-Anti-Spam-Filtered: true X-IronPort-AV: E=Sophos;i="6.27,161,1787011200"; d="scan'208";a="535285422" Received: from rcdn-l-core-03.cisco.com ([173.37.255.140]) by rcdn-iport-9.cisco.com with ESMTP/TLS/TLS_AES_256_GCM_SHA384; 16 Oct 2026 03:37:26 +0000 Received: from sjc-ads-5245.cisco.com (sjc-ads-5245.cisco.com [10.28.23.9]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by rcdn-l-core-03.cisco.com (Postfix) with ESMTPS id BDE7118000624; Fri, 16 Oct 2026 03:37:26 +0000 (GMT) Received: by sjc-ads-5245.cisco.com (Postfix, from userid 1887505) id 663E8CBF201; Thu, 15 Oct 2026 20:37:26 -0700 (PDT) From: "Hetvi Thakar -X (hthakar - E INFOCHIPS PRIVATE LIMITED at Cisco)" To: openembedded-core@lists.openembedded.org Cc: xe-linux-external@cisco.com Subject: [OE-core][wrynose][PATCH 2/3] lrzsz: fix CVE-2026-105840 Date: Thu, 15 Oct 2026 20:37:25 -0700 Message-Id: <20261016033726.426908-2-hthakar@cisco.com> X-Mailer: git-send-email 2.35.6 In-Reply-To: <20261016033726.426908-1-hthakar@cisco.com> References: <20261016033726.426908-1-hthakar@cisco.com> MIME-Version: 1.0 X-Auto-Response-Suppress: DR, OOF, AutoReply X-Outbound-Client-TLS: ANONYMOUS;sjc-ads-5245.cisco.com [10.28.23.9];TLSv1.3;TLS_AES_256_GCM_SHA384;256 X-Outbound-SMTP-Client: 10.28.23.9, sjc-ads-5245.cisco.com X-Outbound-Node: rcdn-l-core-03.cisco.com List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 16 Oct 2026 03:37:34 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/247904 From: Hetvi Thakar This patch applies the upstream fix as referenced in [2], using the commit shown in [1]. [1] https://github.com/UweOhse/lrzsz/commit/b1fc8a01e3a074f8462a29dca45ed7c8fd2ef665 [2] https://www.vulncheck.com/advisories/lrzsz-before-0.13.0-path-traversal-via-lrz-restricted-mode-checkpath Signed-off-by: Hetvi Thakar --- .../lrzsz/lrzsz-0.12.20/CVE-2026-105840.patch | 106 ++++++++++++++++++ meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb | 1 + 2 files changed, 107 insertions(+) create mode 100644 meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105840.patch diff --git a/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105840.patch b/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105840.patch new file mode 100644 index 00000000000..1bf5eae803c --- /dev/null +++ b/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105840.patch @@ -0,0 +1,106 @@ +From b1fc8a01e3a074f8462a29dca45ed7c8fd2ef665 Mon Sep 17 00:00:00 2001 +From: Uwe Ohse at akiar +Date: Mon, 10 Aug 2026 18:09:20 +0200 +Subject: [PATCH] remove PUBDIR, fix the 2nd security hole found by + tristaninsec + +CVE: CVE-2026-105840 +Upstream-Status: Backport [https://github.com/UweOhse/lrzsz/commit/b1fc8a01e3a074f8462a29dca45ed7c8fd2ef665] + +Backport Changes: +- Applied the configure.ac change to configure.in, which is the build + configuration filename used by lrzsz 0.12.20. +- Omitted NEWS because its 0.13.0 release-note hunk conflicts with the + 0.12.20 release history and is not needed for the security fix. + +(cherry picked from commit b1fc8a01e3a074f8462a29dca45ed7c8fd2ef665) +Signed-off-by: Hetvi Thakar +--- + configure.in | 7 ------- + src/lrz.c | 16 +++++----------- + src/lsz.c | 9 ++------- + 3 files changed, 7 insertions(+), 25 deletions(-) + +diff --git a/configure.in b/configure.in +index b7c3c31..504bd32 100644 +--- a/configure.in ++++ b/configure.in +@@ -37,13 +37,6 @@ AC_ARG_ENABLE(timesync, + fi], + [AC_DEFINE(ENABLE_TIMESYNC)]) + AC_SUBST(ENABLE_TIMESYNC) +-AC_ARG_ENABLE(pubdir, +- [--enable-pubdir=/path include support for a public writeable directory], +- [if test "$enableval" = "no" ; then +- : +- else +- AC_DEFINE_UNQUOTED(PUBDIR,"$enableval") +- fi]) + AC_ARG_ENABLE(mkdir, + [--disable-mkdir disable support for creating directories (lrz)], + [if test "$enableval" = "no" ; then +diff --git a/src/lrz.c b/src/lrz.c +index 9c08a3d..168636e 100644 +--- a/src/lrz.c ++++ b/src/lrz.c +@@ -1553,12 +1553,10 @@ chkinvok(const char *s) + } + +-/* +- * Totalitarian Communist pathname processing +- */ + static void + checkpath(const char *name) + { + if (Restricted) { ++ FILE *noleak = NULL; + const char *p; + p=strrchr(name,'/'); + if (p) +@@ -1595,20 +1593,16 @@ checkpath(const char *name) + p=name; + /* don't overwrite any file in very restricted mode. + * don't overwrite hidden files in restricted mode */ +- if ((Restricted==2 || *name=='.') && fopen(name, "r") != NULL) { ++ if ((Restricted==2 || *name=='.') && (noleak = fopen(name, "r")) != NULL) { ++ fclose(noleak); + canit(STDOUT_FILENO); + vstring("\r\n"); + vstringf(_("%s: %s exists\n"), + program_name, name); + bibi(-1); + } +- /* restrict pathnames to current tree or uucppublic */ +- if ( strstr(name, "../") +-#ifdef PUBDIR +- || (name[0]== '/' && strncmp(name, PUBDIR, +- strlen(PUBDIR))) +-#endif +- ) { ++ /* restrict pathnames to the current tree */ ++ if ( strstr(name, "../") || name[0] == '/') { + canit(STDOUT_FILENO); + vstring("\r\n"); + vstringf(_("%s:\tSecurity Violation"),program_name); +diff --git a/src/lsz.c b/src/lsz.c +index 69f4fb8..3dd91b1 100644 +--- a/src/lsz.c ++++ b/src/lsz.c +@@ -1009,13 +1009,8 @@ wcs(const char *oname, const char *remotename) + + + if (Restricted) { +- /* restrict pathnames to current tree or uucppublic */ +- if ( strstr(oname, "../") +-#ifdef PUBDIR +- || (oname[0]== '/' && strncmp(oname, MK_STRING(PUBDIR), +- strlen(MK_STRING(PUBDIR)))) +-#endif +- ) { ++ /* restrict pathnames to current tree */ ++ if ( strstr(oname, "../") || oname[0] == '/') { + canit(STDOUT_FILENO); + vchar('\r'); + error(1,0, +-- +2.35.6 diff --git a/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb b/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb index 403266743e0..ec98f690153 100644 --- a/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb +++ b/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb @@ -22,6 +22,7 @@ SRC_URI = "https://www.ohse.de/uwe/releases/lrzsz-${PV}.tar.gz \ file://0001-Fix-build-with-GCC-15.patch \ file://0001-lrzsz-convert-K-R-function-definitions-to-ANSI-C-pro.patch \ file://CVE-2026-105841.patch \ + file://CVE-2026-105840.patch \ " SRC_URI[sha256sum] = "c28b36b14bddb014d9e9c97c52459852f97bd405f89113f30bee45ed92728ff1" From patchwork Fri Oct 16 03:37:26 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hetvi Thakar -X (hthakar - E INFOCHIPS PRIVATE LIMITED at Cisco)" X-Patchwork-Id: 100942 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 63084CC6B38 for ; Fri, 16 Oct 2026 03:37:44 +0000 (UTC) Received: from rcdn-iport-4.cisco.com (rcdn-iport-4.cisco.com [173.37.86.75]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.13985.1792121859155516438 for ; Thu, 15 Oct 2026 20:37:39 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: message contains an insecure body length tag" header.i=@cisco.com header.s=iport01 header.b=hRfcn10W; spf=pass (domain: cisco.com, ip: 173.37.86.75, mailfrom: hthakar@cisco.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cisco.com; i=@cisco.com; l=3197; q=dns/txt; s=iport01; t=1792121859; x=1793331459; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=+WrBvyS2uX+pEC7bRWdl+NEB/HNKODjkZaCJhp9zk3Q=; b=hRfcn10W3vfaWqQUQONqbRhwQQcaHKkt3nf/o5sdfXeqX4F+/jp3x0yK mBgbpPrdqXzCYgfscAIWNm3YxQWSefyzuiZTJ4hllvzjbvtUcVn9nl0g7 GwzSdAoKPs0LgyUwoMc2PD8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jTSWtgT1LPuvyF9JI4SI6i3M0z5TuF8dsamR /zOxa2O5WjQ+REgELuNyt4XpWVTH9Y+lSDX4pZnc/DKbipq/0Te4Y5nXBYoUnq7vh3S9zxHJ HqhgrTrIeshFvWkdO3wyHC0GQkmVUFN0OevzXRSLaV/wmWeG0YAzcmCA2kYI5UTyv1rDFgX8 M5faxc9Tky83t+PlefTpulE3qzPLeHxN48Z/3UlxjbDALN+GNbIQr7B4plT2zJYasJmRKmFI ZFGL2AyMVKZOE0n1lQ/UPrSmM+omnn2cDRCgFmUvqEwpWPUyWSd1ZCwa4SMK4HWGZ89ckCw+ 2bJzlaoBw8gNNGf4gaVz0mCt97ignauMG4VPPjinhJwu3WU3mEVBRgcWFe3rPX8gUmkVvpbK lcI4WwptaU0+UmhQ9XxUhH+p2SL1iPwQPJKGOE8rQXIwa3O7kPBXy4PTyVKb5ots8peqSEW6 2JlVujBXVRH2IB5g1rHnltIhVte4RQoEFI= IronPort-HdrOrdr: A9a23:1TIIP6O0HyYZfsBcThmjsMiBIKoaSvp037Dk7S9MoHtuA6ulfq +V/cjzuSWYtN9VYgBDpTniAtjlfZqjz/5ICOAqVN/INjUO+lHYSb2KhrGN/9SPIUHDH8dmpM FdmtBFeb7NJGk/q9rm6w+lFNtl6tyG/Ke0wdr69R5WPHhXg2UK1XYDNu5deXcGPDV7OQ== X-Talos-CUID: 9a23:yvlXJm3b/5SZAKHMJVBrUbxfNN49eU3G0HrpekqKTiVOeJ3JdgatwfYx X-Talos-MUID: 9a23:4Ojdxgaf2FhFt+BT6jvjtQMzMdlS46muI3wdrK4oivipKnkl X-IronPort-Anti-Spam-Filtered: true X-IronPort-AV: E=Sophos;i="6.27,161,1787011200"; d="scan'208";a="536195442" Received: from rcdn-l-core-01.cisco.com ([173.37.255.138]) by rcdn-iport-4.cisco.com with ESMTP/TLS/TLS_AES_256_GCM_SHA384; 16 Oct 2026 03:37:26 +0000 Received: from sjc-ads-5245.cisco.com (sjc-ads-5245.cisco.com [10.28.23.9]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by rcdn-l-core-01.cisco.com (Postfix) with ESMTPS id C3A4918000312; Fri, 16 Oct 2026 03:37:26 +0000 (GMT) Received: by sjc-ads-5245.cisco.com (Postfix, from userid 1887505) id 6A71ECBF202; Thu, 15 Oct 2026 20:37:26 -0700 (PDT) From: "Hetvi Thakar -X (hthakar - E INFOCHIPS PRIVATE LIMITED at Cisco)" To: openembedded-core@lists.openembedded.org Cc: xe-linux-external@cisco.com Subject: [OE-core][wrynose][PATCH 3/3] lrzsz: fix CVE-2026-105842 Date: Thu, 15 Oct 2026 20:37:26 -0700 Message-Id: <20261016033726.426908-3-hthakar@cisco.com> X-Mailer: git-send-email 2.35.6 In-Reply-To: <20261016033726.426908-1-hthakar@cisco.com> References: <20261016033726.426908-1-hthakar@cisco.com> MIME-Version: 1.0 X-Auto-Response-Suppress: DR, OOF, AutoReply X-Outbound-Client-TLS: ANONYMOUS;sjc-ads-5245.cisco.com [10.28.23.9];TLSv1.3;TLS_AES_256_GCM_SHA384;256 X-Outbound-SMTP-Client: 10.28.23.9, sjc-ads-5245.cisco.com X-Outbound-Node: rcdn-l-core-01.cisco.com List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 16 Oct 2026 03:37:44 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/247905 From: Hetvi Thakar This patch applies the upstream fix as referenced in [2], using the commit shown in [1]. [1] https://github.com/UweOhse/lrzsz/commit/f8caa7b1b1a3a1bb50cf08677b15be7b17c2956f [2] https://www.vulncheck.com/advisories/lrzsz-before-0.13.0-heap-buffer-overflow-via-lrz-procheader-pathname Signed-off-by: Hetvi Thakar --- .../lrzsz/lrzsz-0.12.20/CVE-2026-105842.patch | 57 +++++++++++++++++++ meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb | 1 + 2 files changed, 58 insertions(+) create mode 100644 meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105842.patch diff --git a/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105842.patch b/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105842.patch new file mode 100644 index 00000000000..afa6a8ab3b4 --- /dev/null +++ b/meta/recipes-bsp/lrzsz/lrzsz-0.12.20/CVE-2026-105842.patch @@ -0,0 +1,57 @@ +From f8caa7b1b1a3a1bb50cf08677b15be7b17c2956f Mon Sep 17 00:00:00 2001 +From: Uwe Ohse at akiar +Date: Mon, 10 Aug 2026 18:40:36 +0200 +Subject: [PATCH] avoid buffer overflows by strdup instead of + malloc(PATH_MAX+...). + +CVE: CVE-2026-105842 +Upstream-Status: Backport [https://github.com/UweOhse/lrzsz/commit/f8caa7b1b1a3a1bb50cf08677b15be7b17c2956f] + +Backport Changes: +- Omitted NEWS because its 0.13.0 release-note hunk conflicts with the + 0.12.20 release history and is not needed for the security fix. + +(cherry picked from commit f8caa7b1b1a3a1bb50cf08677b15be7b17c2956f) +Signed-off-by: Hetvi Thakar +--- + src/lrz.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/src/lrz.c b/src/lrz.c +index 168636e..e11f909 100644 +--- a/src/lrz.c ++++ b/src/lrz.c +@@ -743,11 +743,10 @@ wcreceive(int argc, char **argp) + if (Pathname) + free(Pathname); + errno=0; +- Pathname=malloc(PATH_MAX+1); ++ Pathname=strdup(*argp); + if (!Pathname) + error(1,0,_("out of memory")); + +- strcpy(Pathname, *argp); + checkpath(Pathname); + #ifdef ENABLE_SYSLOG + shortname=strrchr(*argp,'/'); +@@ -1288,15 +1287,16 @@ procheader(char *name, struct zm_fileinfo *zi) + return OK; /* dummy */ + if (Pathname) + free(Pathname); +- Pathname=malloc((PATH_MAX)*2); ++ ++ Pathname=strdup(name_static); + if (!Pathname) + error(1,0,_("out of memory")); +- strcpy(Pathname, name_static); + if (Verbose) { + /* overwrite the "waiting to receive" line */ + vstring("\r \r"); + vstringf(_("Receiving: %s\n"), name_static); + } ++ + checkpath(name_static); + if (Nflag) + { +-- +2.35.6 diff --git a/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb b/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb index ec98f690153..a6d1f62c61e 100644 --- a/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb +++ b/meta/recipes-bsp/lrzsz/lrzsz_0.12.20.bb @@ -23,6 +23,7 @@ SRC_URI = "https://www.ohse.de/uwe/releases/lrzsz-${PV}.tar.gz \ file://0001-lrzsz-convert-K-R-function-definitions-to-ANSI-C-pro.patch \ file://CVE-2026-105841.patch \ file://CVE-2026-105840.patch \ + file://CVE-2026-105842.patch \ " SRC_URI[sha256sum] = "c28b36b14bddb014d9e9c97c52459852f97bd405f89113f30bee45ed92728ff1"