Live › vulnerability › GHSA-h7wr-284f-5qvc
Go to dashboardThe Echo v4 Decompress middleware does not limit how large a gzip request body can grow when decoded. A small compressed request can expand into a very large body that exhausts server memory or CPU, causing denial of service.
Summary written from the sources below. Check the originals before acting.
First seen by InfraStack 2026-10-23 20:59 UTC. All times on this page are UTC.
| Product | Ecosystem | Affected | Fixed in |
|---|
| github.com/labstack/echo/v4 | go | >= 4.0.0, < 4.16.1 | 4.16.1 |
4.16.1 (go list -m github.com/labstack/echo/v4)v4.16.1 or laterEach row is the first time that source carried this signal. The analyst’s rows are its own findings.
Echo v4's opt-in Decompress middleware exposed a gzip-decoded request stream without limiting its expanded size. A small compressed request could therefore produce a very large decoded body. Handlers that read or bind that body could consume excessive memory or CPU, and repeated or concurrent requests could cause denial of service.
The middleware is not enabled by default. A limit on the compressed request size alone does not bound the decompressed size. Applications that already apply an effective body limit after decompression have reduced exposure.
Echo v4 versions through v4.16.0 are affected. Upgrade to v4.16.1.
The patch adds DecompressConfig.MaxDecompressedSize, defaulting to 100 MiB when zero. A value of -1 explicitly disables the limit. Reading beyond the cap returns ErrStatusRequestEntityTooLarge (HTTP 413), including through JSON and XML binding. Bodies exactly at the configured limit remain valid. Streaming enforcement requires callers to handle body-read errors.
Disable gzip request decompression on exposed routes, or place BodyLimit after Decompress so the application limit applies to decoded bytes. Apply suitable request deadlines and concurrency limits as well.
Reported by @q490107865. The exact-limit behavior incorporates @Shubham-Padkonde's work in #3136.
This page as .md · .json · in your agent: get_signal("GHSA-h7wr-284f-5qvc")
GitHub Advisory Database, CC-BY 4.0. Posts quoted belong to their authors.