CVE-2016-15059 Net::IDN::Punycode versions before 2.301 for Perl allow a heap buffer overflow via unchecked writes past the output buffer in encode_punycode.
Heap buffer overflow in Net::IDN::Punycode XS backend allows attackers to corrupt memory and potentially execute code via crafted input.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2016-15059?
CVE-2016-15059 is a critical memory corruption vulnerability, published on 22 Sep 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
Net::IDN::Punycode versions before 2.301 for Perl allow a heap buffer overflow via unchecked writes past the output buffer in encode_punycode.
The XS backend builds the encoded label in the string buffer of the scalar it returns, sized from the input length. The loop that emits the digits of each code point checks for room before every write, but the write of the last digit of each round and the write of the terminating NUL do not, so an input whose encoded form fills the buffer writes past its end.
Only the XS backend is affected.
Encoding an attacker-supplied string corrupts the heap.
Weakness: CWE-122
Which versions are affected by CVE-2016-15059?
How do I fix CVE-2016-15059?
Upgrade to a fixed version.
Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.
Is CVE-2016-15059 being exploited?
There is no known exploitation of CVE-2016-15059 in the wild and no public exploit code.
Sources
Also known as DEBIAN-CVE-2016-15059, GHSA-6764-w6g6-m249, UBUNTU-CVE-2016-15059.