# GHSA-54GP-563G-92F3: Micronaut Netty server leaks pooled buffers when a streaming JSON request body contains a malformed element or is cancelled

- Database: GitHub
- Severity: CVSS 5.9 (Medium)
- Published: 2026-10-22
- Modified: 2026-10-23

## Affected versions

- io.micronaut:micronaut-http-netty (Maven): from 4.0.0, fixed in 4.10.33
- io.micronaut:micronaut-http-netty (Maven): from 5.0.0, fixed in 5.2.17
- io.micronaut:micronaut-http (Maven): from 4.0.0, fixed in 4.10.33
- io.micronaut:micronaut-http (Maven): from 5.0.0, fixed in 5.2.17

## Description

### Impact
_What kind of vulnerability is it? Who is impacted?_

Denial of service through memory exhaustion (CWE-401)..

When a JSON request body is bound as `Publisher<T>` or `Flux<T>` the server tokenises the incoming bytes into one retained slice per JSON element. A slice whose element fails to decode (a type mismatch such as a string where an integer is expected) is never released. Slices queued for the consumer are also dropped without release when the consumer cancels, for example with `take(n)`, or when the consumer errors. A client sends an array whose first element is valid and whose second is malformed, and repeats; each request leaks one pooled buffer. The related `application/x-json-stream` `List<T>` binding double-releases the body on a parse error, replacing the intended 400 with a 500 (no leak).

Impacted: applications with a route that binds a JSON body as `Publisher<T>`, `Flux<T>` or another reactive type, which is the documented way to process large JSON arrays incrementally.

### Patches
_Has the problem been patched? What versions should users upgrade to?_

Patched in 4.10.33 and 5.2.17. Message body readers now release the buffer on failure as well as on success, the tokeniser registers discard hooks so cancelled or queued elements are released, and the `x-json-stream` list path reads synchronously and reports malformed input as a 400.

### Workarounds
_Is there a way for users to fix or remediate the vulnerability without upgrading?_

- Bind the body as `List<T>` (or a single object) instead of `Publisher<T>`; the buffered path releases correctly on failure.
- Validate the raw payload in a filter before binding if incremental processing must be kept.

### References
_Are there any links users can visit to find out more?_

- https://github.com/micronaut-projects/micronaut-core/security/advisories/GHSA-xxxx
- https://docs.micronaut.io/latest/guide/#jsonBinding

## References

- https://github.com/micronaut-projects/micronaut-core/security/advisories/GHSA-54gp-563g-92f3

Page: https://cve.now/GHSA-54GP-563G-92F3

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
