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.
References10
- go.dev/cl/783621
- go.dev/issue/79694
- groups.google.com/g/golang-announce/c/tKs3rmcBcKw
- pkg.go.dev/vuln/GO-2026-5037
- access.redhat.com/errata/RHSA-2026:23262
- access.redhat.com/errata/RHSA-2026:23264
- access.redhat.com/errata/RHSA-2026:29980
- access.redhat.com/errata/RHSA-2026:29981
- access.redhat.com/errata/RHSA-2026:33574
- access.redhat.com/errata/RHSA-2026:34357
Metrics
- CVSS 3.1
-
6.5
MEDIUM
Score source: CNA
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H - EPSS — exploit probability
- 1% percentile: 49 · as of 15 November 2026
- CWE
- CWE-606
Could this be exploited in your environment?
A patch closes the known hole. A penetration test shows what an attacker can still reach — with proof.