CVE-2025-47950: CoreDNS Vulnerable to DoQ Memory Exhaustion via Stream Amplification
Summary
A Denial of Service (DoS) vulnerability was discovered in the CoreDNS DNS-over-QUIC (DoQ) server implementation. The server previously created a new goroutine for every incoming QUIC stream without imposing any limits on the number of concurrent streams or goroutines. A remote, unauthenticated attacker could open a large number of streams, leading to uncontrolled memory consumption and eventually causing an Out Of Memory (OOM) crash — especially in containerized or memory-constrained environments.
Impact
- Component: serverquic.go - Attack Vector: Remote, network-based - Attack Complexity: Low - Privileges Required: None - User Interaction: None - Impact: High availability loss (OOM kill or unresponsiveness)
This issue affects deployments with quic:// enabled in the Corefile. A single attacker can cause the CoreDNS instance to become unresponsive using minimal bandwidth and CPU.
Patches
The patch introduces two key mitigation mechanisms:
- maxstreams: Caps the number of concurrent QUIC streams per connection. Default: 256. - workerpoolsize: Introduces a server-wide, bounded worker pool to process incoming streams. Default: 1024.
This eliminates the 1:1 stream-to-goroutine model and ensures that CoreDNS remains resilient under high concurrency. The new configuration options are exposed through the quic Corefile block:
quic { maxstreams 256 workerpoolsize 1024 }
These defaults are generous and aligned with typical DNS-over-QUIC client behavior.
Workarounds
If you're unable to upgrade immediately, you can: - Disable QUIC support by removing or commenting out the quic:// block in your Corefile - Use container runtime resource limits to detect and isolate excessive memory usage - Monitor QUIC connection patterns and alert on anomalies
References
- RFC 9250 - DNS over Dedicated QUIC Connections - quic-go GitHub project - QUIC stream exhaustion class of vulnerabilities (related)
Credit
Thanks to @thevilledev for disclovering this vulnerability and contributing a high-quality fix.
For more information
Please consult our security guide for more information regarding our security process.
Other sources
CoreDNS is a DNS server that chains plugins. In versions prior to 1.12.2, a Denial of Service (DoS) vulnerability exists in the CoreDNS DNS-over-QUIC (DoQ) server implementation. The server previously created a new goroutine for every incoming QUIC stream without imposing any limits on the number of concurrent streams or goroutines. A remote, unauthenticated attacker could open a large number of streams, leading to uncontrolled memory consumption and eventually causing an Out Of Memory (OOM) crash — especially in containerized or memory-constrained environments. The patch in version 1.12.2 introduces two key mitigation mechanisms: maxstreams, which caps the number of concurrent QUIC streams per connection with a default value of 256; and workerpoolsize, which Introduces a server-wide, bounded worker pool to process incoming streams with a default value of 1024. This eliminates the 1:1 stream-to-goroutine model and ensures that CoreDNS remains resilient under high concurrency. Some workarounds are available for those who are unable to upgrade. Disable QUIC support by removing or commenting out the quic:// block in the Corefile, use container runtime resource limits to detect and isolate excessive memory usage, and/or monitor QUIC connection patterns and alert on anomalies.
— MITRE
CoreDNS Vulnerable to DoQ Memory Exhaustion via Stream Amplification
— Microsoft
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
go/github.com/coredns/corednsto a version that resolves this vulnerability.Fixed in 1.12.2 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 1.11.1-19 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 1.11.4-7 - Upgrade
Upgrade
corednsto a version that resolves this vulnerability.Fixed in 1.12.2 - Configuration
In the Corefile, set `max_streams 256` under the `quic { ... }` block (introduced by the 1.12.2 mitigation) to cap concurrent QUIC streams per connection.
CoreDNS DoQ (QUIC server, quic:// block) max_streams = 256 - Configuration
In the Corefile, set `worker_pool_size 1024` under the `quic { ... }` block (introduced by the 1.12.2 mitigation) to use a bounded worker pool for processing incoming streams.
CoreDNS DoQ (QUIC server, quic:// block) worker_pool_size = 1024 - Configuration
Disable QUIC support by removing or commenting out the `quic://` block in the Corefile.
CoreDNS DoQ (QUIC server, quic:// block) quic:// block = disabled - Compensating control
Use container runtime resource limits to detect and isolate excessive memory usage.
- Compensating control
Monitor QUIC connection patterns and alert on anomalies.
Event History
Frequently Asked Questions
What is the severity of CVE-2025-47950?
CVE-2025-47950 is classified as a Denial of Service (DoS) vulnerability.
How do I fix CVE-2025-47950?
To fix CVE-2025-47950, update CoreDNS to version 1.21.2 or later.
What version of CoreDNS is affected by CVE-2025-47950?
CoreDNS versions prior to 1.21.2 are affected by CVE-2025-47950.
What impact does CVE-2025-47950 have on CoreDNS?
CVE-2025-47950 can lead to a Denial of Service, causing the CoreDNS server to become unresponsive.
What does CVE-2025-47950 affect in CoreDNS?
CVE-2025-47950 affects the DNS-over-QUIC (DoQ) server implementation in CoreDNS.