CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-39835

CVE-2026-39835: Remote Denial of Service via Null Pointer Dereference in Go SSH CertChecker

Amit Schendel
Amit Schendel
Senior Security Researcher

Jun 26, 2026·7 min read·38 visits

Executive Summary (TL;DR)

An unauthenticated remote attacker can crash Go SSH servers using CertChecker by presenting certificates during the handshake, exploiting uninitialized function pointers.

A Denial of Service (DoS) vulnerability exists in the Go SSH implementation package (golang.org/x/crypto/ssh). The vulnerability is caused by a null pointer dereference (runtime panic) when CertChecker is utilized as a public key callback but its validation fields, IsUserAuthority or IsHostAuthority, are uninitialized.

Vulnerability Overview and Technical Context

The Go programming language provides a standard library subrepository golang.org/x/crypto/ssh for building custom secure shell (SSH) servers and clients. In enterprise ecosystems, custom Go-based SSH endpoints are widely deployed to handle automated tasks, secure file transfer interfaces, developer gateways, and infrastructure control planes. The cryptographic library relies on modular structures and callback functions to delegate authority verification to application-level logic.

One such critical structure is the CertChecker utility, which implements standard SSH certificate validation rules. It contains specific field hooks for validating user authorities and host authorities, namely the IsUserAuthority and IsHostAuthority callback functions. When an incoming client presents a certificate to a server or host validation occurs, the server relies on these hooks to decide whether the signing entity is trusted.

The vulnerability designated as CVE-2026-39835 is a classic null pointer dereference weakness (CWE-476) residing in the core certificate verification routines. Because Go allows partial structure initialization, applications can instantiate CertChecker without defining these function variables, leaving them with default nil values. When a remote, unauthenticated connection attempts to perform certificate authentication, the package dereferences the nil variable, causing an unhandled panic that terminates the entire host program.

Root Cause Analysis and Code Path Execution

To understand the root cause, one must examine the behavior of structure allocation and zero-values in Go. In the ssh package, CertChecker is designed as a modular validator. It defines function fields such as IsUserAuthority which returns a boolean. If an application developer initializes CertChecker as part of an SSH server's public key callback configuration but fails to populate the callback fields, Go sets these pointers to nil.

The library lacks prior defensive validation before invoking these callback functions. During the handshake sequence, when a user presents an SSH certificate, the execution flow is routed into the CertChecker.Authenticate method. This method extracts the signature key of the certificate and immediately attempts to call c.IsUserAuthority(cert.SignatureKey).

In Go, invoking a function variable that contains a nil address initiates an immediate runtime panic. While normal errors are returned as values, a panic is an exceptional control flow event. Because individual SSH connections are executed inside separate, concurrent background goroutines managed by the Go runtime, an unrecovered panic in any single goroutine is not isolated. Instead, it propagates upwards and crashes the entire application process, leading to immediate denial of service.

Code Analysis

The vulnerable implementation inside ssh/certs.go failed to perform guard checks prior to dispatching validation parameters to application-defined function pointers. The functions CheckHostKey and Authenticate directly invoke c.IsHostAuthority and c.IsUserAuthority respectively. Below is a conceptual representation of the vulnerable pathways:

// Vulnerable implementation in ssh/certs.go
func (c *CertChecker) CheckHostKey(addr string, remote net.Addr, key PublicKey) error {
    // ... cert type validation checks ...
    // The following call is executed without a nil safety guard
    if !c.IsHostAuthority(cert.SignatureKey, addr) {
        return fmt.Errorf("ssh: no authorities for hostname: %v", addr)
    }
    // ... rest of validation ...
}

The following patch introduces structural safety guards within ssh/certs.go under CL 781660. The modification checks the validity of the function pointers before execution and returns standard error objects:

// Patched implementation in ssh/certs.go
if cert.CertType != HostCert {
    return fmt.Errorf("ssh: certificate presented as a host key has type %d", cert.CertType)
}
// Explicit safety check added to prevent null pointer dereference
if c.IsHostAuthority == nil {
    return errors.New("ssh: cannot verify certificate, IsHostAuthority not set")
}
if !c.IsHostAuthority(cert.SignatureKey, addr) {
    return fmt.Errorf("ssh: no authorities for hostname: %v", addr)
}

A parallel guard block was introduced within CertChecker.Authenticate to secure the IsUserAuthority callback. These checks successfully transform an unhandled runtime crash vector into a manageable, loggable error state. The patch is considered highly complete as it thoroughly resolves both vulnerable execution pathways inside the package.

Exploitation Methodology

Exploitation of CVE-2026-39835 requires minimal sophistication and can be initiated by a remote, unauthenticated attacker. The target server must be configured to use CertChecker within its SSH server configuration, and the fields must be left uninitialized. This scenario occurs when developers assume that leaving fields blank acts as a default rejection rather than an unhandled code path.

An attacker begins by establishing a raw TCP connection to the exposed SSH listener port of the target. Once the TCP socket is open, the client sends an SSH identification string to negotiate the protocol version. After completing the initial key exchange, the client transitions to the user authentication phase by sending an SSH_MSG_USERAUTH_REQUEST message specifying public key authentication.

Instead of offering a traditional RSA or Ed25519 public key, the attacker offers an SSH certificate. When the server processes this certificate, it delegates verification to CertChecker.Authenticate. The Go runtime immediately attempts to execute the nil pointer, generating a fatal panic on the server console and terminating the process. No state changes, file writes, or memory corruption occur; the attack is purely focused on service disruption.

Impact Assessment and Downstream Exposure

The severity of CVE-2026-39835 is classified as Medium, with a CVSS v3.1 base score of 5.3. The impact is limited strictly to system availability, with no risk of confidentiality breach or unauthorized modifications. However, in modern cloud-native environments, the actual operational impact can be severe depending on application monitoring and restart configurations.

Because many critical operations rely on Go-based infrastructure utilities like HashiCorp Vault, Docker registries, or Gitea code servers, crashing the service disrupts dependent continuous integration and deployment pipelines. If the target application lacks a reliable container orchestrator or process supervisor to restart the crashed binary, the denial of service remains permanent until manual administrator intervention.

Even if an automated system restarts the service, repeated exploitation attempts can generate a continuous loop of process restarts. This continuous loop degrades hardware performance, floods log streams with unhandled core dumps, and prevents legitimate connections. The ease of remote execution makes it a high-priority target for automated denial of service scripts.

Detection and Remediation

The primary and recommended solution is to upgrade the golang.org/x/crypto package to version v0.52.0 or higher. Developers can execute the standard dependency update commands to pull the latest version of the subrepository. This update integrates the safety verification guards into the application compilation tree automatically.

In environments where upgrading the library is not immediately possible, application-level workarounds can prevent the panic. Developers must audit their SSH configurations to guarantee that CertChecker instances never contain nil fields. Even if certificate verification is not supported, the fields should be explicitly defined with safe fallback functions that reject all inputs.

// Application-level safety workaround
checker := &ssh.CertChecker{
    IsUserAuthority: func(auth ssh.PublicKey) bool {
        return false
    },
    IsHostAuthority: func(auth ssh.PublicKey, address string) bool {
        return false
    },
}

Additionally, integration of automated detection tooling such as govulncheck helps security teams locate vulnerable references during compilation or automated continuous integration builds. Network-level controls, such as rate limiting and IP access lists, should be deployed to restrict SSH port exposure to trusted actors.

Official Patches

GoGerrit Change CL 781660

Technical Appendix

CVSS Score
5.3/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
EPSS Probability
0.21%
Top 89% most exploited

Affected Systems

Docker / MobyHashiCorp VaultPrometheusGiteacontainerdPodmanTrivyAmazon CloudWatch AgentAWS Systems Manager Agent (SSM)SOPSAtlantisCloudflaredSplunk OpenTelemetry Collector

Affected Versions Detail

Product
Affected Versions
Fixed Version
golang.org/x/crypto
Go
< 0.52.00.52.0
AttributeDetail
CWE IDCWE-476
Attack VectorNetwork
CVSS Severity5.3 (Medium)
Exploit StatusProof of Concept
Affected Packagegolang.org/x/crypto/ssh
Fixed Versionv0.52.0

MITRE ATT&CK Mapping

T1499.003Endpoint Denial of Service: Application Denial of Service
Impact
CWE-476
NULL Pointer Dereference

The application attempts to dereference a pointer that it expects to be valid, but is NULL, typically causing a crash or exit.

Vulnerability Timeline

Security patch authored and submitted to Gerrit
2026-01-25
Private issue tracking completed under case b/503003289
2026-05-21
Public announcement and CVE disclosure
2026-05-22

References & Sources

  • [1]Go Issue 79563
  • [2]Go Announce Mailing List
  • [3]Go VulnDB Entry GO-2026-5015

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•2 days ago•CVE-2026-71556
7.1

CVE-2026-71556: Symbolic Link Directory Traversal in go-git

A symbolic link directory traversal vulnerability was identified in go-git, a pure Go implementation of the Git specification. This vulnerability allows an attacker to construct a repository that, when checked out or processed, bypasses directory boundaries to write or overwrite arbitrary files on the host filesystem.

Amit Schendel
Amit Schendel
11 views•5 min read
•2 days ago•CVE-2026-71557
6.3

CVE-2026-71557: Path Traversal and Configuration Overwrite in go-git Filesystem Storage Engine

CVE-2026-71557 is a path traversal vulnerability in go-git, a pure-Go implementation of Git. In vulnerable versions, the filesystem-backed storage engine fails to validate reference names before mapping them to on-disk paths. An attacker hosting a malicious Git server can advertise references containing directory traversal sequences, such as 'refs/heads/../../config', to write or overwrite files outside the intended reference storage directory.

Amit Schendel
Amit Schendel
8 views•7 min read
•2 days ago•GHSA-7C4V-FWGW-9RF7
5.3

GHSA-7c4v-fwgw-9rf7: Nuxt Dev Server Discloses Project Root and Workspace UUID via Chrome DevTools Endpoint

An information disclosure vulnerability in the Nuxt development server allows adjacent network attackers to retrieve the absolute project root directory and a persistent workspace UUID by querying the unprotected Chrome DevTools workspace endpoint. This occurs when the development server is bound to a network-reachable interface, allowing requests that bypass the header-based security verification checks.

Alon Barad
Alon Barad
10 views•7 min read
•2 days ago•CVE-2026-66062
5.3

CVE-2026-66062: Regular Expression Denial of Service (ReDoS) in SvelteKit Content Negotiation

A Regular Expression Denial of Service (ReDoS) vulnerability exists in SvelteKit's content negotiation header parser prior to version 2.70.2. An unauthenticated remote attacker can exploit this vulnerability by sending a crafted Accept header with highly repetitive malformed values. This triggers catastrophic backtracking on the single-threaded Node.js/Bun event loop, leading to CPU exhaustion and full denial of service.

Alon Barad
Alon Barad
7 views•6 min read
•2 days ago•CVE-2026-15895
8.4

CVE-2026-15895: OS Command Injection in AWS jsii-diff CLI

An OS command injection vulnerability exists in the npm package loading component of the jsii-diff CLI tool within the AWS jsii framework. Prior to version 1.131.0, when parsing package specifiers prefixed with `npm:`, the tool concatenated user-controlled inputs directly into a shell execution string via child_process.exec. This allows attackers to execute arbitrary shell commands under the context of the running Node.js process.

Amit Schendel
Amit Schendel
7 views•7 min read
•2 days ago•CVE-2026-63220
4.8

CVE-2026-63220: Trust of Untrusted Reverse Proxy Headers in CodeIgniter4

CodeIgniter4 versions prior to v4.7.4 contain a protocol-spoofing vulnerability due to improper verification of upstream reverse proxy forwarding headers. Remote, unauthenticated attackers can inject headers like X-Forwarded-Proto to deceive the framework into identifying an insecure HTTP request as a secure HTTPS connection.

Alon Barad
Alon Barad
13 views•7 min read