Jun 26, 2026·7 min read·134 visits
Unsolicited global or channel responses fill bounded internal Go channels, deadlocking the connection's read loop and leaking goroutines even after the connection is closed.
A denial-of-service (DoS) and resource leak vulnerability in the Go SSH package (golang.org/x/crypto/ssh) allows a malicious peer to permanently deadlock connection processing loops and leak memory. This issue stems from improper handling of unsolicited responses at the global and channel layers, which saturate internal bounded channel buffers and block the main multiplexer loop. The vulnerability is fully resolved in version 0.52.0.
The Go sub-repository golang.org/x/crypto/ssh is a widely utilized implementation of the SSH protocol in the Go ecosystem. It provides the core structures and multiplexing capabilities required to implement both SSH clients and servers. Because the SSH protocol permits multiple logical channels to run over a single physical transport layer, the package relies on an internal multiplexer layer to coordinate concurrent message streams.
CVE-2026-39830 is a design vulnerability within this multiplexer component. The issue stems from the improper handling of unexpected, unsolicited protocol responses. Specifically, both global-level and channel-level request response handlers lack safety gates to verify if a response was actually requested before placing it into internal Go channels.
An unauthenticated remote attacker can exploit this behavior to block the main connection-reading routine. By stalling the read loop, the attacker forces Go routines associated with the connection to hang indefinitely, even if the application subsequently attempts to close the underlying socket. This results in an incremental and permanent resource exhaustion of system memory and file descriptors.
The root cause of CVE-2026-39830 is a buffer saturation vulnerability that deadlocks the Go SSH connection multiplexer. The SSH multiplexer maintains a background packet processing routine named readLoop to deserialize incoming packets and route them to their respective channels or global handlers. When processing global request responses, the multiplexer routes success or failure packets into an internal Go channel named globalResponses, which has a bounded capacity of one.
Prior to the patch, the handleGlobalPacket function unconditionally dispatched received responses directly into the globalResponses channel. Because this channel is bounded, writing to it blocks the executing thread if the channel is already full. When a malicious peer sends an unsolicited global response packet, the channel becomes saturated. A subsequent unsolicited response packet blocks the handleGlobalPacket function indefinitely, which in turn blocks the entire readLoop goroutine.
Similarly, at the channel level, channel-specific response packets are processed by channel.handlePacket and written to the ch.msg channel, which has a bounded capacity of 16. If a malicious peer transmits unsolicited channel success or failure messages, the channel buffer overflows. The execution path blocks on the channel send statement, permanently halting the connection's main read routine.
This design flaw creates an un-killable deadlock state because the blocking operations occur on Go channels rather than network socket I/O. When the socket is closed by the server, the blocked readLoop goroutine never reaches the code path that handles socket closure. Consequently, the goroutines associated with the connection remain allocated in memory, creating a persistent leak.
The vulnerability was resolved through two targeted patches that introduce atomic state gates and non-blocking channel writes. In ssh/mux.go, the patch adds an atomic boolean flag named globalSentPending to track whether a global request is actively awaiting a response. If a response packet arrives while no request is pending, the message is discarded immediately instead of being pushed into the channel.
// ssh/mux.go patch highlights
case *globalRequestSuccessMsg, *globalRequestFailureMsg:
// Verify if a global request is actively pending
if !m.globalSentPending.Load() {
return nil // Safely discard unsolicited packet
}
select {
case m.globalResponses <- msg:
default:
// Non-blocking fallback to prevent lockups
}The second patch in ssh/channel.go duplicates this architecture at the channel layer by introducing sentRequestPending. Before executing a channel request, the package drains any spurious or residual messages from the channel buffer to ensure stale messages cannot interfere with valid operations. The message insertion is also wrapped in a non-blocking select statement.
// ssh/channel.go patch highlights
case *channelRequestSuccessMsg, *channelRequestFailureMsg:
// Verify if a channel request is pending
if !ch.sentRequestPending.Load() {
return nil // Discard unsolicited channel responses
}
select {
case ch.msg <- msg:
default:
// Fallback protects read loop if reader is slow
}These modifications successfully decouple the physical read loop from uncoordinated remote peer behavior. The implementation of atomic state gates ensures that unexpected packets are discarded at the boundary, preventing buffer saturation attacks. The transition to non-blocking writes ensures that even if a valid caller is delayed in reading, the core multiplexer thread remains unblocked.
Exploitation of CVE-2026-39830 does not require authentication or complex sequence timing. An attacker begins by establishing a standard TCP handshake with a target Go SSH service and completing the initial SSH key exchange protocol. Once the transport layer is established, the attacker can target either the global-level multiplexer or the channel-level multiplexer.
To target the global multiplexer, the attacker transmits two successive global response packets, such as SSH_MSG_GLOBAL_REQUEST_SUCCESS or SSH_MSG_GLOBAL_REQUEST_FAILURE. Because the target server has not initiated a global request, the first packet fills the single-slot globalResponses channel. The second packet causes the server's background read loop to block indefinitely while attempting to write to the full channel.
To target the channel-level multiplexer, the attacker first requests an interactive channel or subsystem. Once the channel is open, the attacker transmits 17 or more consecutive unsolicited SSH_MSG_CHANNEL_SUCCESS or SSH_MSG_CHANNEL_FAILURE packets. This overflows the 16-slot channel buffer on the server, resulting in an identical blocking condition in the background packet-reading thread.
The impact of CVE-2026-39830 is a complete denial of service and continuous resource exhaustion. Because the blocked routines are held on Go channel operations, calling Close() on the connection does not release the underlying structures. The main multiplexer read loop, the keep-alive loops, and the key exchange loops remain active in memory indefinitely.
An attacker can automate this sequence across thousands of concurrent connections to systematically exhaust the server's memory allocation. This leads to Out-Of-Memory (OOM) kernel interventions, which can terminate the host application or trigger system-wide deadlocks. Because no specialized authentication is required, the attack surface includes any public-facing application utilizing the vulnerable Go package.
The vulnerability is classified with a CVSS v3.1 score of 9.1, reflecting its high availability impact and low attack complexity. Although the vulnerability does not directly expose confidential system data, the resulting denial of service poses an operational risk to containerized environments and cloud-native gateways.
The primary remediation path is upgrading the golang.org/x/crypto package to version 0.52.0 or higher. This upgrade replaces the vulnerable multiplexer logic with the gated, non-blocking implementation. Developers should update their dependencies using standard Go module commands and rebuild affected binaries.
# Upgrade the crypto module to the patched version
go get golang.org/x/crypto@v0.52.0
go mod tidyIf immediate upgrading is not feasible, organizations should implement rate-limiting at the network layer to restrict the number of concurrent connections from single source IP addresses. Temporary connection limits can reduce the rate of resource depletion. However, because the leak is permanent, network-level mitigations only delay resource exhaustion and do not resolve the underlying vulnerability.
Security teams can identify ongoing exploitation by monitoring runtime metrics for abnormal trends. A continuous, linear increase in the total number of active goroutines that persists after client disconnects is a strong indicator of an active exploit. Running periodic pprof analyses can help locate blocked channel operations originating from the ssh package.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H| Product | Affected Versions | Fixed Version |
|---|---|---|
golang.org/x/crypto/ssh Go | < 0.52.0 | 0.52.0 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-833 (Deadlock) |
| Attack Vector | Network (AV:N) |
| CVSS v3.1 Score | 9.1 (Critical) |
| EPSS Score | 0.00392 |
| EPSS Percentile | 30.94% |
| Exploit Status | PoC (No Weaponized Public Exploits) |
| CISA KEV Status | Not Listed |
The program contains two or more threads or active execution paths that are permanently blocked waiting for each other or a shared resource, specifically a full Go channel.
CVE-2026-114147 is a high-severity Denial of Service (DoS) vulnerability affecting ASP.NET Core and specifically the Microsoft.AspNetCore.SignalR.StackExchangeRedis scale-out provider across .NET 8.0, 9.0, 10.0, and 11.0 preview releases. The vulnerability originates from a string comparison mismatch between internal per-connection group collections and the centralized Redis channel subscription registry, compounded by a race condition during connection teardown. Remote unauthenticated attackers can exploit this flaw to leave orphaned connection contexts and active Redis pub/sub listeners pinned in memory, leading to unbounded memory exhaustion and application process termination.
CVE-2026-114156 is an improper resolution of path equivalence vulnerability (CWE-41) in Microsoft ASP.NET Core affecting .NET 11.0 preview releases and Microsoft Visual Studio 2026. The vulnerability stems from a discrepancy between how path prefix validation helpers (such as PathString.StartsWithSegments) and downstream routing mechanisms handle alternate path separators and percent-encoded characters. An unauthenticated remote attacker can exploit this mismatch over the network to bypass path-based authorization middleware and access restricted endpoints.
CVE-2026-114157 is a high-severity local privilege escalation and security feature bypass vulnerability affecting ASP.NET Core on Microsoft Windows. The flaw resides in the Kestrel web server's Named Pipes transport layer (Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes) and stems from a race condition (CWE-362) during broken pipe error recovery. When an active connection throws an IOException during handshake acceptance, the connection listener previously disposed of the broken NamedPipeServerStream instance before acquiring a replacement stream from its internal pool. This sequence created a momentary window where zero server instances of the named pipe existed in the Windows Named Pipe File System (NPFS). A local, low-privileged attacker can exploit this timing window to create a named pipe with the identical name and a permissive Discretionary Access Control List (DACL), hijacking subsequent inter-process communications and escalating privileges across security boundaries.
CVE-2026-124194 is a forced authentication and spoofing vulnerability in Microsoft Office Outlook caused by a missing user interface warning before dereferencing remote network paths (CWE-356). By embedding an attacker-controlled Universal Naming Convention (UNC) path within MAPI message properties such as PidLidReminderFileParameter, an unauthenticated remote attacker can force a victim's system to initiate an outbound SMB or WebDAV connection upon opening or previewing a crafted message. This automatic authentication handshake leaks the user's NetNTLMv2 hash, enabling offline password cracking or real-time NTLM relay attacks. The vulnerability was exploited in the wild as a zero-day prior to its remediation in Microsoft's November 2026 Patch Tuesday updates and is listed in the CISA Known Exploited Vulnerabilities (KEV) catalog.
CVE-2026-114154 is a high-severity Denial of Service (DoS) and uncontrolled resource consumption vulnerability in the Microsoft.AspNetCore.Server.HttpSys component of ASP.NET Core. When processing an HTTP request that simultaneously contains a chunked Transfer-Encoding header, a Content-Length header, and an explicit X-Content-Length header, the server throws an unhandled ArgumentException during header normalization. In certain versions, subsequent exception handling attempts to dereference a disposed native request context, aborting error response dispatch and leaking unmanaged HTTP.sys request structures.
A local elevation of privilege vulnerability exists in the Microsoft .NET Aspire CLI (`Aspire.Cli`) versions 13.5.4 prior to 13.6.5. When executing SDK management commands (`aspire sdk generate`, `aspire sdk dump`, and `aspire sdk export`), the CLI creates temporary project directories inside the shared operating system temporary folder (such as `/tmp` on Unix-like systems) without restricting directory permissions or disabling MSBuild automatic response file resolution. A local, low-privileged attacker on a multi-user system can place a crafted `Directory.Build.rsp` file in the shared temporary directory hierarchy. When a victim user executes an affected Aspire CLI command, MSBuild traverses upward, ingests the attacker-controlled response file, and executes arbitrary commands in the security context of the victim user.