CVE-2025-62504 Envoy Lua filter use-after-free when oversized rewritten response body causes crash

Medium 6.5 Published Updated

A use-after-free in Envoy's Lua filter causes a crash when a rewritten response body exceeds buffer limits, leading to denial of service.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2025-62504?

CVE-2025-62504 is a medium-severity use after free vulnerability in Envoyproxy Envoy, published on 16 Oct 2025. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

Envoy is an open source edge and service proxy. Envoy versions earlier than 1.36.2, 1.35.6, 1.34.10, and 1.33.12 contain a use-after-free vulnerability in the Lua filter. When a Lua script executing in the response phase rewrites a response body so that its size exceeds the configured per_connection_buffer_limit_bytes (default 1MB), Envoy generates a local reply whose headers override the original response headers, leaving dangling references and causing a crash. This results in denial of service. Updating to versions 1.36.2, 1.35.6, 1.34.10, or 1.33.12 fixes the issue. Increasing per_connection_buffer_limit_bytes (and for HTTP/2 the initial_stream_window_size) or increasing per_request_buffer_limit_bytes / request_body_buffer_limit can reduce the likelihood of triggering the condition but does not correct the underlying memory safety flaw.

Weakness: CWE-416

Which versions are affected by CVE-2025-62504?

1 open source package ship an affected version, including envoy. It affects 1 product.

PackageAffectedFixed in
envoy BitnamiAll versions1.33.12, 1.34.10, 1.35.6, 1.36.2

Products include Envoyproxy Envoy.

How do I fix CVE-2025-62504?

Upgrade envoy to a fixed version for your release line: 1.33.12, 1.34.10, 1.35.6 or 1.36.2.

Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.

Is CVE-2025-62504 being exploited?

There is no known exploitation of CVE-2025-62504 in the wild and no public exploit code.

All Envoyproxy Envoy vulnerabilities

Sources

Also known as BIT-envoy-2025-62504, GHSA-gcxr-6vrp-wff3.

Is CVE-2025-62504 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free