CVE-2026-27145 Inefficient candidate hostname parsing in crypto/x509
An attacker can cause excessive CPU consumption during certificate hostname verification by providing a certificate with many DNS Subject Alternative Names.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2026-27145?
CVE-2026-27145 is a medium-severity denial of service vulnerability in Go standard library crypto/x509, published on 2 Jun 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
(*x509.Certificate).VerifyHostname previously called matchHostnames in a loop over all DNS Subject Alternative Name (SAN) entries. This caused strings.Split(host, ".") to execute repeatedly on the same input hostname. With a large DNS SAN list, verification costs scaled quadratically based on the number of SAN entries multiplied by the hostname's label count. Because x509.Verify validates hostnames before building the certificate chain, this overhead occurred even for untrusted certificates.
Weakness: CWE-606
Which versions are affected by CVE-2026-27145?
2 open source packages ship an affected version, including golang and stdlib.
| Package | Affected | Fixed in |
|---|---|---|
golang Bitnami | All versions | 1.25.11, 1.26.4 |
stdlib Go | All versions | 1.25.11, 1.26.4 |
Linux distribution packages (9)
go-fdo-client AlmaLinux:10 | All versions | 1.0.0-4.el10_2.5 |
go-fdo-client Red Hat:enterprise_linux:10.2 | All versions | 0:1.0.0-4.el10_2.5 |
go-fdo-client-debuginfo Red Hat:enterprise_linux:10.2 | All versions | 0:1.0.0-4.el10_2.5 |
go-fdo-client-debugsource Red Hat:enterprise_linux:10.2 | All versions | 0:1.0.0-4.el10_2.5 |
host-metering Red Hat:rhel_els:7 | All versions | 0:1.4.0-8.el7_9 |
host-metering-debuginfo Red Hat:rhel_els:7 | All versions | 0:1.4.0-8.el7_9 |
host-metering-debugsource Red Hat:rhel_els:7 | All versions | 0:1.4.0-8.el7_9 |
host-metering-selinux Red Hat:rhel_els:7 | All versions | 0:1.4.0-8.el7_9 |
go-fdo-client Rocky Linux:10 | All versions | 0:1.0.0-4.el10_2.5 |
How do I fix CVE-2026-27145?
Upgrade golang to a fixed version for your release line: 1.25.11 or 1.26.4.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2026-27145 being exploited?
There is no known exploitation of CVE-2026-27145 in the wild and no public exploit code.
Public exploit code: 1 proofs of concept on GitHub.
Sources
Also known as ALSA-2026:46394, AZL-89381, AZL-89384, AZL-98601, BELL-CVE-2026-27145, BIT-golang-2026-27145 and 989 more.