CVE-2026-58471: GNU Wget heap buffer overflow in convert_fname

CVE-2026-58471 · Severity: medium · CVSS 5.9 · Published 2026-07-07

GNU Wget, a widely used command-line tool for downloading files from the internet, contains a security flaw in how it handles file names provided by remote servers. If a user connects to a malicious server, the server can send a specially crafted file name that causes the application to crash or potentially allow unauthorized memory access. This could disrupt automated download processes or lead to further system compromise if the tool is used in sensitive environments.

Quick answers

Is CVE-2026-58471 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-58471 being exploited in the wild.
How severe is CVE-2026-58471?
Medium severity, with a CVSS score of 5.9, published 7 July 2026.
Which products and versions are affected?
GNU Wget through 1.25.0.
Is there a fix for CVE-2026-58471?
A patch was published on 2026-06-29: Fix committed to main repository Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-58471 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-58471?
Check whether anything you run is named in the advisory. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

A heap-based buffer overflow exists in GNU Wget through version 1.25.0 within the `convert_fname()` function in `src/url.c`. The vulnerability is triggered during character set conversion using `iconv` when the output buffer is insufficient (returning `E2BIG`). The reallocation logic miscalculates the remaining buffer space, leading to a heap overflow when subsequent conversion data is written. An attacker can exploit this by hosting a malicious server that returns a crafted filename requiring complex character conversion, potentially leading to memory corruption or arbitrary code execution. The issue was addressed in Git commit c2640fe.

Affected products

  • GNU Wget through 1.25.0

Timeline

  • 2026-01-13: other: Vulnerability fix authored
  • 2026-06-29: patched: Fix committed to main repository
  • 2026-07-07: disclosed: Public disclosure and CVE assignment

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.