fix(http2): pass proper value to h2 max_local_error_reset_streams#3782
Merged
seanmonstar merged 2 commits intohyperium:masterfrom Nov 15, 2024
Merged
Conversation
The patch hyperium#3528 added the ability for hyper users to configure `max_local_error_reset_streams` via the server builder to hyper v0.14.29. It was then pulled in to hyper v1.2.0 as well in hyperium#3530, where the wrong parameter `max_pending_accept_reset_streams` is passed to h2's builder as `max_local_error_reset_streams`. This could lead to significant impact especially when a hyper user does not set `max_pending_accept_reset_streams`, because its default value is `None` and passing `None` to h2's `max_local_error_reset_streams` method will make the server vulnerable to DOS attacks. This issue has been fixed in this patch, simply by passing the correct value to the h2's builder method.
max_local_error_reset_streams
Contributor
Author
|
Looks like the hashbrown crate was recently released which bumped MSRV to 1.65.0. Do we want to bump our MSRV too? |
Member
Nah, in our MSRV job, we pin dependencies to a version that works with it. There's a couple others in the |
Member
|
I fixed the MSRV failure in #3783 |
seanmonstar
approved these changes
Nov 15, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
The patch #3528 added the ability for hyper users to configure
max_local_error_reset_streamsvia the server builder to hyper v0.14.29. It was then pulled in to hyper v1.2.0 as well in #3530, where the wrong parametermax_pending_accept_reset_streamsis passed to h2's builder asmax_local_error_reset_streams.This could lead to significant impact especially when a hyper user does not set
max_pending_accept_reset_streams, because its default value isNoneand passingNoneto h2'smax_local_error_reset_streamsmethod will make the server vulnerable to DOS attacks.This issue has been fixed in this patch, simply by passing the correct value to the h2's builder method.
Note that the original patch merged into v0.14 does not suffer this problem.