From: Peter Marko <[email protected]>

Although the patch was not merged yet, Debian already took it ([1]).
Since busybox CVE handling is slow, follow Debian decision.

[1] 
https://sources.debian.org/src/busybox/1%3A1.37.0-10/debian/patches/wget-disallow-control-chars-in-URLs-CVE-2025-60876.patch

Signed-off-by: Peter Marko <[email protected]>
---
 .../busybox/busybox/CVE-2025-60876.patch      | 38 +++++++++++++++++++
 meta/recipes-core/busybox/busybox_1.35.0.bb   |  1 +
 2 files changed, 39 insertions(+)
 create mode 100644 meta/recipes-core/busybox/busybox/CVE-2025-60876.patch

diff --git a/meta/recipes-core/busybox/busybox/CVE-2025-60876.patch 
b/meta/recipes-core/busybox/busybox/CVE-2025-60876.patch
new file mode 100644
index 00000000000..72d7020f625
--- /dev/null
+++ b/meta/recipes-core/busybox/busybox/CVE-2025-60876.patch
@@ -0,0 +1,38 @@
+From 32c0f6f240fcb041ae7df44a9bbf958d627a8212 Mon Sep 17 00:00:00 2001
+From: Radoslav Kolev <[email protected]>
+Date: Fri, 21 Nov 2025 11:21:18 +0200
+Subject: [PATCH] wget: don't allow control characters or spaces in the URL
+
+Fixes CVE-2025-60876 malicious URL can be used to inject
+HTTP headers in the request.
+
+Signed-off-by: Radoslav Kolev <[email protected]>
+Reviewed-by: Emmanuel Deloget <[email protected]>
+
+CVE: CVE-2025-60876
+Upstream-Status: Submitted 
[https://lists.busybox.net/pipermail/busybox/2025-November/091840.html]
+Signed-off-by: Peter Marko <[email protected]>
+---
+ networking/wget.c | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/networking/wget.c b/networking/wget.c
+index 9ec0e67..7602563 100644
+--- a/networking/wget.c
++++ b/networking/wget.c
+@@ -536,6 +536,15 @@ static void parse_url(const char *src_url, struct 
host_info *h)
+ {
+       char *url, *p, *sp;
+ 
++      /* Fix for CVE-2025-60876 - don't allow control characters or spaces in 
the URL */
++      /* otherwise a malicious URL can be used to inject HTTP headers in the 
request */
++      const unsigned char *u = (void *) src_url;
++      while (*u) {
++              if (*u <= ' ')
++                      bb_simple_error_msg_and_die("Unencoded control 
character found in the URL!");
++              u++;
++      }
++
+       free(h->allocated);
+       h->allocated = url = xstrdup(src_url);
+ 
diff --git a/meta/recipes-core/busybox/busybox_1.35.0.bb 
b/meta/recipes-core/busybox/busybox_1.35.0.bb
index 57a5747a489..0b5ac220f5f 100644
--- a/meta/recipes-core/busybox/busybox_1.35.0.bb
+++ b/meta/recipes-core/busybox/busybox_1.35.0.bb
@@ -61,6 +61,7 @@ SRC_URI = 
"https://busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \
            file://CVE-2023-39810.patch \
            file://CVE-2025-46394-01.patch \
            file://CVE-2025-46394-02.patch \
+           file://CVE-2025-60876.patch \
            "
 SRC_URI:append:libc-musl = " file://musl.cfg "
 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#232522): 
https://lists.openembedded.org/g/openembedded-core/message/232522
Mute This Topic: https://lists.openembedded.org/mt/118160389/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to