Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTP/3: Header limits and validation #31928

Merged
merged 2 commits into from
Apr 19, 2021
Merged

Conversation

JamesNK
Copy link
Member

@JamesNK JamesNK commented Apr 19, 2021

Addresses #29702

  • MaxRequestHeadersTotalSize
  • MaxRequestHeaderCount

Also copy tests from HTTP/2.

runtime changes mirrored here - dotnet/runtime#51486

@JamesNK JamesNK requested a review from a team April 19, 2021 10:07
@@ -521,6 +535,15 @@ private Task ProcessUnknownFrameAsync()
await OnEndStreamReceived();
}

if (!_isMethodConnect && (_parsedPseudoHeaderFields & _mandatoryRequestPseudoHeaderFields) != _mandatoryRequestPseudoHeaderFields)
{
// All HTTP/3 requests MUST include exactly one valid value for the :method, :scheme, and :path pseudo-header
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this not a requirement for HTTP/2?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

HTTP/2 and HTTP/3 have the same requirements here.

@JamesNK JamesNK merged commit 8d8deb7 into main Apr 19, 2021
@JamesNK JamesNK deleted the jamesnk/http3-header-validation branch April 19, 2021 20:23
@ghost ghost added this to the 6.0-preview5 milestone Apr 19, 2021
@amcasey amcasey added area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions and removed area-runtime labels Jun 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants