# CVE-2026-40395: Varnish Enterprise denial of service in vmod_headerplus

Source: https://junglewise.ai/threats/cve-2026-40395-varnish-enterprise-denial-of-service-in-vmod-headerplus  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-04-12. Updated: 2026-05-10  
License: CC BY 4.0 with a link back

CVE-2026-40395 · Severity: medium · CVSS 4 · Published 2026-04-12

Varnish Enterprise, a high-performance web accelerator and caching server, is vulnerable to a denial-of-service attack. By sending a specially crafted web request with an excessive number of headers, a malicious actor can cause the server to crash. This results in a service outage, preventing legitimate users from accessing the websites or applications protected by the Varnish server.

## Quick answers

**Is CVE-2026-40395 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-40395 being exploited in the wild.

**How severe is CVE-2026-40395?** Medium severity, with a CVSS score of 4, published 12 April 2026.

**Which products and versions are affected?** Varnish Software Varnish Enterprise 6.0.9r5 through 6.0.16r11.

**Is there a fix for CVE-2026-40395?** A patch was published on 2026-04-12: Fixed in Varnish Enterprise 6.0.16r12 Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-40395 attacked?** It is attacked over the network, in a network appliance.

**Am I affected by CVE-2026-40395?** Check whether anything you run is named in the advisory. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

A workspace overflow vulnerability exists in Varnish Enterprise's vmod_headerplus module. The headerplus.write_req0() function is used to update the underlying req0 object (the original read-only request) before transitioning between VCL (Varnish Configuration Language) labels, a common pattern in shared VCL deployments managed by Varnish Controller. If an incoming request is modified to contain more header fields than the req0 workspace can accommodate, the function triggers a workspace overflow. This results in a daemon panic and immediate crash of the Varnish server. The issue is resolved in version 6.0.16r12.

## Affected products

- Varnish Software Varnish Enterprise 6.0.9r5 through 6.0.16r11

## Timeline

- 2026-04-09: advisory: Vendor advisory published by Varnish Software
- 2026-04-12: disclosed: CVE-2026-40395 published
- 2026-04-12: patched: Fixed in Varnish Enterprise 6.0.16r12

## References

- [https://docs.varnish-software.com/security/VEV00003/](https://docs.varnish-software.com/security/VEV00003/)
