# GHSA-GPXF-V9P3-4HH5: Micronaut WebSocket upgrade handling leaks request bodies, upgrades malformed requests and lets messages run before @OnOpen completes

- Database: GitHub
- Severity: CVSS 5.3 (Medium)
- Published: 2026-11-11
- Modified: 2026-11-11

## Affected versions

- io.micronaut:micronaut-http-server-netty (Maven): fixed in 3.10.19
- io.micronaut:micronaut-http-server-netty (Maven): from 4.0.0, fixed in 4.10.37
- io.micronaut:micronaut-http-server-netty (Maven): from 5.0.0, fixed in 5.2.23
- io.micronaut:micronaut-http-netty (Maven): fixed in 3.10.19
- io.micronaut:micronaut-http-netty (Maven): from 4.0.0, fixed in 4.10.37
- io.micronaut:micronaut-http-netty (Maven): from 5.0.0, fixed in 5.2.23

## Description

### Summary

Upgrade requests that carry a body leak the buffered request bytes when answered with an ordinary response (404, filter rejection), when cancelled, on a successful 101 when the body arrived with the head, and on h2c listeners (fixed on 5.3.x and in 5.2.23 on the 5.2.x line). The upgrade path accepts HTTP/1.1 heads that failed to decode (duplicate `Content-Length`, invalid header name, oversized header block) where every other path answers 400/413 and closes, and a `WebSocketServerHandshakeException` escapes `writeResponse`, so a rejected handshake is never answered and later pipelined responses stall. `@OnMessage` can also run before an asynchronous `@OnOpen` has decided whether to reject the session, so an endpoint that authorises in `@OnOpen` processes messages from a session it would reject. The fix is to discard the request body on every upgrade outcome, reject decoder-failed heads, answer handshake failures, and gate message dispatch on the completion of `@OnOpen`.

### Affected and patched versions

WebSocket upgrade and open/message handling predate 3.0.0. The 3.x fixes cover F43, F44 and W2AK41IC; applicability of F15 to 3.x has not been established.

| Package | Affected versions | Patched version |
| --- | --- | --- |
| `io.micronaut:micronaut-http-server-netty` | `< 3.10.19` | `3.10.19` |
| `io.micronaut:micronaut-http-server-netty` | `>= 4.0.0, < 4.10.37` | `4.10.37` |
| `io.micronaut:micronaut-http-server-netty` | `>= 5.0.0, < 5.2.23` | `5.2.23` |
| `io.micronaut:micronaut-http-netty` | `< 3.10.19` | `3.10.19` |
| `io.micronaut:micronaut-http-netty` | `>= 4.0.0, < 4.10.37` | `4.10.37` |
| `io.micronaut:micronaut-http-netty` | `>= 5.0.0, < 5.2.23` | `5.2.23` |

The 3.x fix is in [commit d9a8da384f](https://github.com/micronaut-projects/micronaut-core/commit/d9a8da384f23d7bd6450f3ebd8b9d5397b2104a3), first included in stable release [3.10.19](https://github.com/micronaut-projects/micronaut-core/releases/tag/v3.10.19). The last affected stable 3.10.x release is 3.10.18.

### Findings

- F15 (= ANT-2026-6RZI5GLK)
- F43
- F44 (= ANT-2026-XGRTNVS6)
- ANT-2026-W2AK41IC

## References

- https://github.com/micronaut-projects/micronaut-core/security/advisories/GHSA-gpxf-v9p3-4hh5

Page: https://cve.now/GHSA-GPXF-V9P3-4HH5

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