Skip to main content

golang.org/x/crypto CVE-2026-42508

| EUVDEUVD-2026-31399 CRITICAL
Improper Certificate Validation (CWE-295)
2026-05-22 Go GHSA-5cgq-3rg8-m6cv
9.1
CVSS 3.1 · Vendor: Go
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Obtain host cert signed by revoked CA
  2. Delivery
    Position on network path to victim
  3. Exploit
    Intercept SSH connection attempt
  4. Install
    Present revoked-CA-signed host certificate
  5. C2
    knownhosts skips SignatureKey revocation check
  6. Execute
    Client accepts impersonated host
  7. Impact
    Capture credentials or manipulate session

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A07:2025 - Authentication Failures
ASVS 5.0
V12 - Secure Communication Certificate validation
Exploitation Conditions

Exploitation requires that the victim application links a vulnerable golang.org/x/crypto/ssh/knownhosts (<0.52.0) and uses CA-based host trust (@cert-authority entries in known_hosts) AND that the targeted CA's SignatureKey has been explicitly marked @revoked by the victim. The attacker must additionally possess a host certificate previously signed by that revoked CA and be able to intercept or redirect the victim's SSH connection (network-adjacent or on-path position). Limiting factors: deployments that pin individual host keys rather than using @cert-authority are unaffected, and victims who never issued a @revoked entry for the CA SignatureKey never reach the buggy code path. No user interaction is required (UI:N) and no authentication on the victim side is needed (PR:N) once the prerequisites are met.

Impact

The CVSS 3.1 base score is 9.1 (AV:N/AC:L/PR:N/UI:N/C:H/I:H/A:N), reflecting network-reachable, unauthenticated abuse with high confidentiality and integrity impact and no availability impact, consistent with a man-in-the-middle / host impersonation outcome rather than RCE. However, EPSS sits at 0.02% (4th percentile) and SSVC reports Exploitation: none with Automatable: yes and Technical Impact: total - meaning exploitation has not been observed but, where prerequisites are met, it scales. The vulnerability is not in CISA KEV. Practical risk is constrained: an attacker must already possess a host key that was previously signed by a CA the victim trusts AND that CA's SignatureKey must have been explicitly revoked by the victim's known_hosts - a relatively narrow precondition that explains the low EPSS despite the high CVSS. Treat as a high-severity correctness bug in trust-anchor handling rather than a mass-exploitation threat.

Exploit ScenarioDerived

An attacker who previously obtained a host certificate signed by a CA that the victim later revoked positions themselves on the network path (e.g., via DNS hijack, ARP spoofing, or rogue Wi-Fi) and answers SSH connections destined for a legitimate server. A Go-based SSH client using knownhosts < 0.52.0 validates the leaf key against revocation entries, misses the revoked SignatureKey of the CA, and accepts the impersonated host, enabling credential capture or session manipulation. No public exploit identified at time of analysis.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 28, 2026

Improper certificate revocation validation in the golang.org/x/crypto/ssh/knownhosts package allows SSH connections to succeed against hosts whose CA SignatureKey has been revoked. Versions prior to 0.52.0 only validated the leaf 'key' against revocation entries while ignoring 'key.SignatureKey', enabling attackers holding a revoked CA-signed host key to impersonate trusted servers. No public exploit identified at time of analysis, and EPSS exploitation probability is very low at 0.02%.

RemediationAI

Vendor-released patch: golang.org/x/crypto v0.52.0. Update the module in go.mod with 'go get golang.org/x/crypto@v0.52.0' and rebuild and redeploy any binaries that consume ssh/knownhosts, since the fix ships compiled into the application rather than as a runtime library. Confirm the upgrade via the Go announcement at https://groups.google.com/g/golang-announce/c/a082jnz-LvI and the advisory at https://pkg.go.dev/vuln/GO-2026-5021. If patching cannot occur immediately, compensating controls include removing @cert-authority entries from known_hosts files and pinning specific host keys directly (trade-off: loses CA-based scalability and requires manual key rotation), or rotating the trusted CA so the previously-revoked key is no longer in the trust chain (trade-off: requires re-signing all host certificates). 'govulncheck' should be run across the codebase to confirm no residual import paths remain on vulnerable versions.

Affected VersionsENISA

golang.org/x/crypto/ssh/knownhosts 0 <0.52.0

Affected Packages

go golang.org/x/crypto fix: 0.52.0
go golang.org/x/crypto/ssh/knownhosts fix: 0.52.0
euvd golang_org_x_crypto_ssh_knownhosts fix: 0.52.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 3 packages in go, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The flaw resides in golang.org/x/crypto/ssh/knownhosts, the Go standard ecosystem library used by SSH clients (including those built on golang.org/x/crypto/ssh) to validate remote host keys against a known_hosts file. The library supports @cert-authority entries that delegate trust to a CA which signs host certificates; revocation is expressed via @revoked entries. CWE-295 (Improper Certificate Validation) applies because the revocation check examined only the presented host key without recursively checking the embedded SignatureKey identifying the signing CA, so a revoked CA could still produce host certificates accepted as valid by client applications.

Know when Golang Org X Crypto Ssh Knownhosts gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (Go) PRIMARY 9.1 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
SUSE CRITICAL
Red Hat 7.4 HIGH

Primary rating from Vendor (Go).

CVSS VectorVendor: Go

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

Lifecycle Timeline

3
CVSS changed
May 28, 2026 - 15:07 NVD
9.1 (None) 9.1 (CRITICAL)
Patch available
May 22, 2026 - 04:31 EUVD
CVE Published
May 22, 2026 - 02:31 nvd
UNKNOWN (no severity yet)

DescriptionCVE.org

Previously, a revoked 'SignatureKey' belonging to a CA was not correctly checked for revocation. Now, both the 'key' and 'key.SignatureKey' are checked for @revoked.

Executive ViewAI

Why It Matters

A certificate revocation validation flaw in the Go SSH cryptography library allows attackers with revoked host keys to impersonate legitimate servers, potentially compromising SSH-based authentication across infrastructure. Any organization using golang.org/x/crypto in production SSH implementations is exposed to server impersonation attacks. Immediate patching is critical to maintain the integrity of SSH-based access controls.

Business Impact: High
Compensating Controls

Vendor-released patch: golang.org/x/crypto version 0.52.0 or later

Threat Intelligence Overview

EPSS Score
0.0%
Top 96% exploitable
Threat Intel
1
1 sources
Social Media
1
Sightings
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA MSRC Vendor CIRCL VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Total

Priority Score

46
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +46
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Vendor StatusVendor

SUSE

Severity: Critical
Product Status
openSUSE Leap 16.0 Fixed
openSUSE Tumbleweed Fixed
SLES15-SP6-CHOST-BYOS-GCE Fixed
SLES15-SP7-CHOST-BYOS-GCE Fixed
SUSE Linux Enterprise Desktop 15 SP7 Fixed

References

Advisories & patches
ADVISORY https://access.redhat.com/errata/RHSA-2026:23262 ADVISORY https://access.redhat.com/errata/RHSA-2026:23264 ADVISORY https://ubuntu.com/security/notices/USN-8447-2 ADVISORY https://vuldb.com/vuln/365134 REF https://access.redhat.com/errata/RHSA-2026:26546 REF https://access.redhat.com/errata/RHSA-2026:26547 REF https://access.redhat.com/errata/RHSA-2026:35833 REF https://access.redhat.com/errata/RHSA-2026:36648 REF https://access.redhat.com/errata/RHSA-2026:36651 REF https://access.redhat.com/errata/RHSA-2026:36796 REF https://access.redhat.com/errata/RHSA-2026:36797 REF https://access.redhat.com/errata/RHSA-2026:36808 REF https://access.redhat.com/errata/RHSA-2026:37072 REF https://access.redhat.com/errata/RHSA-2026:37123 REF https://access.redhat.com/errata/RHSA-2026:37387 REF https://access.redhat.com/errata/RHSA-2026:40118 REF https://access.redhat.com/errata/RHSA-2026:40138 REF https://access.redhat.com/errata/RHSA-2026:40262 REF https://access.redhat.com/errata/RHSA-2026:40945 REF https://access.redhat.com/errata/RHSA-2026:41019 REF https://access.redhat.com/errata/RHSA-2026:41031 REF https://access.redhat.com/errata/RHSA-2026:41036 REF https://access.redhat.com/errata/RHSA-2026:41064 REF https://access.redhat.com/errata/RHSA-2026:41066 REF https://access.redhat.com/errata/RHSA-2026:42146 REF https://access.redhat.com/errata/RHSA-2026:42796 REF https://access.redhat.com/errata/RHSA-2026:43052 REF https://access.redhat.com/errata/RHSA-2026:43692 REF https://access.redhat.com/errata/RHSA-2026:46885 REF https://access.redhat.com/errata/RHSA-2026:47735 REF https://access.redhat.com/errata/RHSA-2026:47737 REF https://access.redhat.com/errata/RHSA-2026:49944 REF https://access.redhat.com/errata/RHSA-2026:51033 REF https://access.redhat.com/errata/RHSA-2026:51288 REF https://access.redhat.com/errata/RHSA-2026:52857 REF https://access.redhat.com/errata/RHSA-2026:52910 REF https://access.redhat.com/errata/RHSA-2026:54400 REF https://access.redhat.com/errata/RHSA-2026:57194 REF https://access.redhat.com/errata/RHSA-2026:59467 REF https://access.redhat.com/errata/RHSA-2026:60520 REF https://access.redhat.com/errata/RHSA-2026:61314 REF https://access.redhat.com/errata/RHSA-2026:65126 REF https://access.redhat.com/errata/RHSA-2026:66022 REF https://access.redhat.com/errata/RHSA-2026:66521 REF https://access.redhat.com/errata/RHSA-2026:67450 REF https://access.redhat.com/security/cve/CVE-2026-42508 REF https://bugzilla.redhat.com/show_bug.cgi?id=2480688 REF https://go.dev/cl/781220 REF https://go.dev/issue/79568 REF https://groups.google.com/g/golang-announce/c/a082jnz-LvI REF https://pkg.go.dev/vuln/GO-2026-5021 REF https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-42508.json

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy