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 — Fix [15908] - Ignore unknown Http3Setting Identifier in Http3SettingsFrame by sanjomo · Pull Request #15909 · netty/netty Conversation
Contributor
Motivation
Modification
Result
Fixes #15908
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactionsIntroduces Http3SettingIdentifier enum for standard HTTP/3 settings, replacing static constants. Updates all usages to reference the enum, enforces ignoring unknown/non-standard settings, and adds support for H3_DATAGRAM setting and error code. Updates tests and documentation to reflect these changes and ensure compliance with RFCs. Introduces support for the H3_DATAGRAM setting in Http3Settings, including methods to enable/disable and query its state. Updates tests to cover the new setting and ensure correct behavior in equality, iteration, and validation scenarios.
Member
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
sanjomo
marked this pull request as ready for review
normanmaurer
requested changes
Uh oh!
There was an error while loading. Please reload this page. Uh oh!
There was an error while loading. Please reload this page.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This will throw if the id is unknown.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
@Nullable public Long put(long key, Long value) { // When HTTP/2 settings identifier is present – throw error if (Http3CodecUtils.isReservedHttp2Setting(key)) { throw new IllegalArgumentException("Setting is reserved for HTTP/2: " + key); } // When a non-standard / unknown settings identifier is present – ignore if (Http3SettingIdentifier.fromId(key) == null) { return value; } // Validate standard settings verifyStandardSetting(key, value); return settings.put(key, value); }
I’m all ears if you want to refactor it further!
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactionsadd javadoc for public methods and refactor verifyStandardSetting char in line at-most 120
Contributor
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
normanmaurer
approved these changes
Member
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
vietj
reviewed
Uh oh!
There was an error while loading. Please reload this page.
vietj
reviewed
Uh oh!
There was an error while loading. Please reload this page.
vietj
reviewed
Uh oh!
There was an error while loading. Please reload this page.
vietj
reviewed
Uh oh!
There was an error while loading. Please reload this page.
Contributor
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. Uh oh!
There was an error while loading. Please reload this page.
Contributor
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
Member
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
Contributor
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
chrisvest
requested changes
Uh oh!
There was an error while loading. Please reload this page.
chrisvest
approved these changes
Member
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
normanmaurer
added a commit
that referenced
this pull request
…Frame (#15909) ## Motivation * According to the spec https://www.rfc-editor.org/rfc/rfc9114.html#section-7.2.4-9 , endpoints **must ignore unknown settings identifiers**. Netty’s previous behavior incorrectly **stored** unknown settings values, which contradicts RFC behaviour. * A **HTTP/3 error code** was missing - H3_DATAGRAM_ERROR * The **SETTINGS_H3_DATAGRAM (0x33)** identifier was not added. * Prior behaviour fixed in [https://github.com/netty/netty/pull/15835](https://github.com/netty/netty/pull/15835) still allowed direct injection of unsupported settings; this PR effectively deprecates that direct-settings behaviour completely. --- ## Modification * [x] **Ignore unknown HTTP/3 SETTINGS identifiers** * Updated parsing logic to skip unknown settings identifiers: ```java // When Non-Standard/Unknown settings identifier present - Ignore if (Http3SettingIdentifier.fromId(key) == null) { return value; } ``` * Unknown settings are **no longer stored** in `Http3Settings`. * Fully aligns with HTTP/3 specification behaviour. * Effectively **deprecates the old direct-settings behavior** introduced/fixed in PR #15835. * [x] **Added missing HTTP/3 error codes** * Implemented the remaining H3 error codes defined in the RFC. * Ensures accurate error propagation and complete protocol support. * [x] **Added `SETTINGS_H3_DATAGRAM (0x33)`** * Introduced the identifier: ```java SETTINGS_H3_DATAGRAM(0x33) ``` * Added proper handling in both encoder and decoder paths. * [x] **Added unit tests** * Tests covering: * Ignoring unknown setting identifiers * Correct handling of `SETTINGS_H3_DATAGRAM` * Verification of newly added error codes * Ensuring unknown settings do **not** appear in `Http3Settings` --- ## Result * [x] Netty now **correctly ignores unknown HTTP/3 settings**, as required by the specification. * [x] `Http3Settings` no longer stores invalid or non-standard identifiers. * [x] Full support for **`SETTINGS_H3_DATAGRAM (0x33)`**. * [x] Complete coverage of **HTTP/3 error codes**. * [x] Added unit tests ensure long-term correctness. * [x] Behaviour from PR #15835 is effectively superseded and corrected. Fixes #[15908](#15908) --------- Co-authored-by: Norman Maurer <[email protected]>
10 tasks done
normanmaurer
added a commit
that referenced
this pull request
#15956) …Frame (#15909) ## Motivation * According to the spec https://www.rfc-editor.org/rfc/rfc9114.html#section-7.2.4-9 , endpoints **must ignore unknown settings identifiers**. Netty’s previous behavior incorrectly **stored** unknown settings values, which contradicts RFC behaviour. * A **HTTP/3 error code** was missing - H3_DATAGRAM_ERROR * The **SETTINGS_H3_DATAGRAM (0x33)** identifier was not added. * Prior behaviour fixed in [https://github.com/netty/netty/pull/15835](https://github.com/netty/netty/pull/15835) still allowed direct injection of unsupported settings; this PR effectively deprecates that direct-settings behaviour completely. --- ## Modification * [x] **Ignore unknown HTTP/3 SETTINGS identifiers** * Updated parsing logic to skip unknown settings identifiers: ```java // When Non-Standard/Unknown settings identifier present - Ignore if (Http3SettingIdentifier.fromId(key) == null) { return value; } ``` * Unknown settings are **no longer stored** in `Http3Settings`. * Fully aligns with HTTP/3 specification behaviour. * Effectively **deprecates the old direct-settings behavior** introduced/fixed in PR #15835. * [x] **Added missing HTTP/3 error codes** * Implemented the remaining H3 error codes defined in the RFC. * Ensures accurate error propagation and complete protocol support. * [x] **Added `SETTINGS_H3_DATAGRAM (0x33)`** * Introduced the identifier: ```java SETTINGS_H3_DATAGRAM(0x33) ``` * Added proper handling in both encoder and decoder paths. * [x] **Added unit tests** * Tests covering: * Ignoring unknown setting identifiers * Correct handling of `SETTINGS_H3_DATAGRAM` * Verification of newly added error codes * Ensuring unknown settings do **not** appear in `Http3Settings` --- ## Result * [x] Netty now **correctly ignores unknown HTTP/3 settings**, as required by the specification. * [x] `Http3Settings` no longer stores invalid or non-standard identifiers. * [x] Full support for **`SETTINGS_H3_DATAGRAM (0x33)`**. * [x] Complete coverage of **HTTP/3 error codes**. * [x] Added unit tests ensure long-term correctness. * [x] Behaviour from PR #15835 is effectively superseded and corrected. Fixes #[15908](#15908) Co-authored-by: sanjomo <[email protected]>
This was referenced
2 tasks done
normanmaurer
added a commit
to netty/netty-incubator-codec-http3
that referenced
this pull request
* According to the spec https://www.rfc-editor.org/rfc/rfc9114.html#section-7.2.4-9 , endpoints **must ignore unknown settings identifiers**. Netty’s previous behavior incorrectly **stored** unknown settings values, which contradicts RFC behaviour. * A **HTTP/3 error code** was missing - H3_DATAGRAM_ERROR * The **SETTINGS_H3_DATAGRAM (0x33)** identifier was not added. * Prior behaviour fixed in [https://github.com/netty/netty/pull/15835](https://github.com/netty/netty/pull/15835) still allowed direct injection of unsupported settings; this PR effectively deprecates that direct-settings behaviour completely. --- * [x] **Ignore unknown HTTP/3 SETTINGS identifiers** * Updated parsing logic to skip unknown settings identifiers: ```java // When Non-Standard/Unknown settings identifier present - Ignore if (Http3SettingIdentifier.fromId(key) == null) { return value; } ``` * Unknown settings are **no longer stored** in `Http3Settings`. * Fully aligns with HTTP/3 specification behaviour. * Effectively **deprecates the old direct-settings behavior** introduced/fixed in PR #15835. * [x] **Added missing HTTP/3 error codes** * Implemented the remaining H3 error codes defined in the RFC. * Ensures accurate error propagation and complete protocol support. * [x] **Added `SETTINGS_H3_DATAGRAM (0x33)`** * Introduced the identifier: ```java SETTINGS_H3_DATAGRAM(0x33) ``` * Added proper handling in both encoder and decoder paths. * [x] **Added unit tests** * Tests covering: * Ignoring unknown setting identifiers * Correct handling of `SETTINGS_H3_DATAGRAM` * Verification of newly added error codes * Ensuring unknown settings do **not** appear in `Http3Settings` --- * [x] Netty now **correctly ignores unknown HTTP/3 settings**, as required by the specification. * [x] `Http3Settings` no longer stores invalid or non-standard identifiers. * [x] Full support for **`SETTINGS_H3_DATAGRAM (0x33)`**. * [x] Complete coverage of **HTTP/3 error codes**. * [x] Added unit tests ensure long-term correctness. * [x] Behaviour from PR #15835 is effectively superseded and corrected. Fixes #[15908](netty/netty#15908) Port of netty/netty#15909
Merged
10 tasks done
normanmaurer
added a commit
to netty/netty-incubator-codec-http3
that referenced
this pull request
* According to the spec https://www.rfc-editor.org/rfc/rfc9114.html#section-7.2.4-9 , endpoints **must ignore unknown settings identifiers**. Netty’s previous behavior incorrectly **stored** unknown settings values, which contradicts RFC behaviour. * A **HTTP/3 error code** was missing - H3_DATAGRAM_ERROR * The **SETTINGS_H3_DATAGRAM (0x33)** identifier was not added. * Prior behaviour fixed in [https://github.com/netty/netty/pull/15835](https://github.com/netty/netty/pull/15835) still allowed direct injection of unsupported settings; this PR effectively deprecates that direct-settings behaviour completely. --- * [x] **Ignore unknown HTTP/3 SETTINGS identifiers** * Updated parsing logic to skip unknown settings identifiers: ```java // When Non-Standard/Unknown settings identifier present - Ignore if (Http3SettingIdentifier.fromId(key) == null) { return value; } ``` * Unknown settings are **no longer stored** in `Http3Settings`. * Fully aligns with HTTP/3 specification behaviour. * Effectively **deprecates the old direct-settings behavior** introduced/fixed in PR #15835. * [x] **Added missing HTTP/3 error codes** * Implemented the remaining H3 error codes defined in the RFC. * Ensures accurate error propagation and complete protocol support. * [x] **Added `SETTINGS_H3_DATAGRAM (0x33)`** * Introduced the identifier: ```java SETTINGS_H3_DATAGRAM(0x33) ``` * Added proper handling in both encoder and decoder paths. * [x] **Added unit tests** * Tests covering: * Ignoring unknown setting identifiers * Correct handling of `SETTINGS_H3_DATAGRAM` * Verification of newly added error codes * Ensuring unknown settings do **not** appear in `Http3Settings` --- * [x] Netty now **correctly ignores unknown HTTP/3 settings**, as required by the specification. * [x] `Http3Settings` no longer stores invalid or non-standard identifiers. * [x] Full support for **`SETTINGS_H3_DATAGRAM (0x33)`**. * [x] Complete coverage of **HTTP/3 error codes**. * [x] Added unit tests ensure long-term correctness. * [x] Behaviour from PR #15835 is effectively superseded and corrected. Fixes #[15908](netty/netty#15908) Port of netty/netty#15909
Merged
2 tasks done
Closed
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Reviewers+1 more reviewerUh oh!
There was an error while loading. Please reload this page. AssigneesNo one assignedLabels
None yet
ProjectsDevelopmentSuccessfully merging this pull request may close these issues. Uh oh!
There was an error while loading. Please reload this page. Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later. | |||||||||||||||||||
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |