GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||
GeezerVison is showing github.com — Reject invalid content-length in PUSH_PROMISE with a stream error by yawkat · Pull Request #17867 · netty/netty Conversation
Contributor
Motivation: Modification:
Result: Discovered by fuzzing. 🤖 Generated with Claude Code
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactionsMotivation: `DefaultHttp2ConnectionDecoder.onPushPromiseRead` parses the content-length of the promised request with `HttpUtil.normalizeAndGetContentLength` but does not catch the `IllegalArgumentException` it throws for invalid values (e.g. non-numeric, multiple different values, or overflow). The exception is then handled as an unexpected error, and the client closes the whole connection with GOAWAY(INTERNAL_ERROR). `onHeadersRead` already converts the same exception into a stream error with PROTOCOL_ERROR. Modification: - Catch the `IllegalArgumentException` in `onPushPromiseRead` and throw a stream error with PROTOCOL_ERROR on the promised stream, like for a non-zero content-length. - Add a test. Result: A PUSH_PROMISE with an invalid content-length resets the promised stream with PROTOCOL_ERROR instead of closing the connection with INTERNAL_ERROR. Discovered by fuzzing. Co-Authored-By: Claude Opus 5.5 <[email protected]>
yawkat
marked this pull request as ready for review
yawkat
added a commit
to micronaut-projects/micronaut-fuzzing
that referenced
this pull request
OSS-Fuzz found two client-side Netty bugs that a server can trigger with PUSH_PROMISE frames: an invalid content-length in the promised request throws an IllegalArgumentException instead of a stream error (netty/netty#17867), and a DATA frame on the reserved promised stream throws an UnsupportedOperationException from the local flow controller (netty/netty#17868). Ignore exactly these two cases, matched by the throwing method and its caller, until the fixes are released. Add a smoke test with both inputs, and drop the checked exception from fuzzerTestOneInput. Co-authored-by: Claude Opus 5.5 <[email protected]>
|
There was an error while loading. Please reload this page.
🚨 TestLens detected 2 failed tests 🚨Failed Jobs without Test Failures❌ Build PR / windows-x86_64-java11-boringssl Test SummaryTip Inspect all details with the TestLens CLI: Build PR / macos-aarch64-java11-boringssl build > Netty/Transport/Native/KQueue
Build PR / macos-x86_64-java11-boringssl build > Netty/Transport/Native/KQueue
🏷️ Commit: bd4c40d Test FailuresKQueueDatagramUnicastIPv6MappedTest > testSimpleSendWithoutBind(TestInfo) (Netty/Transport/Native/KQueue in Build PR / macos-aarch64-java11-boringssl build)KQueueDatagramUnicastIPv6MappedTest > testSimpleSendWithConnect(TestInfo) (Netty/Transport/Native/KQueue in Build PR / macos-x86_64-java11-boringssl build)Rerun ControlsNote Checks are currently running using the configuration below. Select tests to mute in this pull request: 🔲 KQueueDatagramUnicastIPv6MappedTest > testSimpleSendWithConnect(TestInfo) Reuse successful test results: 🔲 ♻️ Only rerun the tests that failed or were muted before Click the checkbox to trigger a rerun: 🔲 Rerun jobs Learn more about TestLens at testlens.app/docs. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Auto-port PR for 4.1: #17875 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Auto-port PR for 5.0: #17876 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…tream error (#17875) Auto-port of #17867 to 4.1 Cherry-picked commit: a143321 --- Motivation: `DefaultHttp2ConnectionDecoder.onPushPromiseRead` parses the content-length of the promised request with `HttpUtil.normalizeAndGetContentLength` but does not catch the `IllegalArgumentException` it throws for invalid values (e.g. non-numeric, multiple different values, or overflow). The exception is then handled as an unexpected error, and the client closes the whole connection with GOAWAY(INTERNAL_ERROR). `onHeadersRead` already converts the same exception into a stream error with PROTOCOL_ERROR. Modification: - Catch the `IllegalArgumentException` in `onPushPromiseRead` and throw a stream error with PROTOCOL_ERROR on the promised stream, like for a non-zero content-length. - Add a test. Result: A PUSH_PROMISE with an invalid content-length resets the promised stream with PROTOCOL_ERROR instead of closing the connection with INTERNAL_ERROR. Discovered by fuzzing. Co-authored-by: Jonas Konrad <[email protected]>
…tream error (#17876) Auto-port of #17867 to 5.0 Cherry-picked commit: a143321 --- Motivation: `DefaultHttp2ConnectionDecoder.onPushPromiseRead` parses the content-length of the promised request with `HttpUtil.normalizeAndGetContentLength` but does not catch the `IllegalArgumentException` it throws for invalid values (e.g. non-numeric, multiple different values, or overflow). The exception is then handled as an unexpected error, and the client closes the whole connection with GOAWAY(INTERNAL_ERROR). `onHeadersRead` already converts the same exception into a stream error with PROTOCOL_ERROR. Modification: - Catch the `IllegalArgumentException` in `onPushPromiseRead` and throw a stream error with PROTOCOL_ERROR on the promised stream, like for a non-zero content-length. - Add a test. Result: A PUSH_PROMISE with an invalid content-length resets the promised stream with PROTOCOL_ERROR instead of closing the connection with INTERNAL_ERROR. Discovered by fuzzing. Co-authored-by: Jonas Konrad <[email protected]>
…tream error (netty#17875) Auto-port of netty#17867 to 4.1 Cherry-picked commit: a143321 --- Motivation: `DefaultHttp2ConnectionDecoder.onPushPromiseRead` parses the content-length of the promised request with `HttpUtil.normalizeAndGetContentLength` but does not catch the `IllegalArgumentException` it throws for invalid values (e.g. non-numeric, multiple different values, or overflow). The exception is then handled as an unexpected error, and the client closes the whole connection with GOAWAY(INTERNAL_ERROR). `onHeadersRead` already converts the same exception into a stream error with PROTOCOL_ERROR. Modification: - Catch the `IllegalArgumentException` in `onPushPromiseRead` and throw a stream error with PROTOCOL_ERROR on the promised stream, like for a non-zero content-length. - Add a test. Result: A PUSH_PROMISE with an invalid content-length resets the promised stream with PROTOCOL_ERROR instead of closing the connection with INTERNAL_ERROR. Discovered by fuzzing. Co-authored-by: Jonas Konrad <[email protected]>
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.