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

AbstractProxyServlet include incorrect protocol version in Via header when accessed over H2 #5104

Closed
travisspencer opened this issue Jul 31, 2020 · 0 comments

Comments

@travisspencer
Copy link
Contributor

Jetty version

9.4.30.v20200611

Java version

1.8.0_261

OS type/version

Mac

Description

The Via header of the AbstractProxyServlet has http/1.1 hard coded in the addViaHeader method. When a client accesses it using HTTP 2, this is not right. This should be fixed by:

  1. Not including the protocol at all (if consumed via HTTP)
  2. Using the client's protocol version instead of the hard coded protocol version

The reason for the first is because of what it says in RFC 7230 section 5.7.1:

For brevity, the protocol-name is omitted when the received protocol is HTTP.

travisspencer added a commit to travisspencer/jetty.project that referenced this issue Aug 1, 2020
…er protocols

Signed-off-by: Travis Spencer <travis@curity.io>
travisspencer added a commit to travisspencer/jetty.project that referenced this issue Aug 1, 2020
… and other protocols

Bug: jetty#5104
Signed-off-by: Travis Spencer <travis@curity.io>
travisspencer added a commit to travisspencer/jetty.project that referenced this issue Aug 1, 2020
… and other protocols

Bug: jetty#5104
Signed-off-by: Travis Spencer <travis@curity.io>
travisspencer added a commit to travisspencer/jetty.project that referenced this issue Aug 1, 2020
… and other protocols

Bug: jetty#5104
Signed-off-by: Travis Spencer <travis@curity.io>
travisspencer added a commit to travisspencer/jetty.project that referenced this issue Aug 1, 2020
… and other protocols

Bug: jetty#5104
Signed-off-by: Travis Spencer <travis@curity.io>
travisspencer added a commit to travisspencer/jetty.project that referenced this issue Aug 3, 2020
… and other protocols

Bug: jetty#5104
Signed-off-by: Travis Spencer <travis@curity.io>
sbordet pushed a commit that referenced this issue Aug 12, 2020
…other protocols

Signed-off-by: Travis Spencer <travis@curity.io>
sbordet added a commit that referenced this issue Aug 13, 2020
… in Via header when accessed over H2.

Fixed javadocs.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
sbordet added a commit that referenced this issue Aug 13, 2020
… in Via header when accessed over H2.

Added HttpFields.computeField() for HttpHeader too and updated usages.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
sbordet added a commit that referenced this issue Aug 13, 2020
… in Via header when accessed over H2.

Fixed HttpFields.computeField() removal loop.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant