Inefficient candidate hostname parsing in crypto/x509
Summary
| CVE | CVE-2026-27145 |
|---|---|
| State | PUBLISHED |
| Assigner | Go |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-06-02 23:16:35 UTC |
| Updated | 2026-06-04 16:15:50 UTC |
| 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. |
Risk And Classification
Primary CVSS: v3.1 6.5 MEDIUM from ADP
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H
EPSS: 0.000110000 probability, percentile 0.015380000 (date 2026-06-09)
Problem Types: CWE-407: Inefficient Algorithmic Complexity
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | ADP | DECLARED | 6.5 | MEDIUM | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H |
| 3.1 | 134c704f-9b21-4f2e-91b3-4a467353bcc0 | Secondary | 6.5 | MEDIUM | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H |
CVSS v3.1 Breakdown
Attack Vector
NetworkAttack Complexity
HighPrivileges Required
NoneUser Interaction
NoneScope
UnchangedConfidentiality
NoneIntegrity
LowAvailability
HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | Go Standard Library | Crypto/x509 | affected 1.25.11 semver | Not specified |
| CNA | Go Standard Library | Crypto/x509 | affected 1.26.0-0 1.26.4 semver | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| go.dev/cl/783621 | [email protected] | go.dev | |
| pkg.go.dev/vuln/GO-2026-5037 | [email protected] | pkg.go.dev | |
| go.dev/issue/79694 | [email protected] | go.dev | |
| groups.google.com/g/golang-announce/c/tKs3rmcBcKw | [email protected] | groups.google.com | |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
Vendor Comments And Credit
Discovery Credit
CNA: Jakub Ciolek - https://ciolek.dev/ (en)
There are currently no legacy QID mappings associated with this CVE.