Skip to content

Treat a 204 response to CONNECT as an established tunnel - #535

Merged
ericmj merged 1 commit into
http2-remove-infinity-branchesfrom
http2-connect-204
Nov 30, 2026
Merged

ericmj merged 1 commit into
http2-remove-infinity-branchesfrom
http2-connect-204

Conversation

@ericmj

@ericmj ericmj commented Oct 16, 2026

Copy link
Copy Markdown
Member

The check for 204 and 304 responses, which must not have content, came before the check for 2xx responses to CONNECT. A CONNECT request answered with 204 was treated as a response without content, so the first DATA frame on the tunnel failed the request with a protocol error.

RFC 9110 9.3.6 and RFC 9113 8.5 make any 2xx response to CONNECT establish a tunnel, so the CONNECT case is checked first and DATA frames after a 204 are delivered as tunnel data.

@coveralls

coveralls commented Oct 16, 2026 •

Copy link
Copy Markdown

Coverage Report for CI Build 0

Coverage decreased (-0.1%) to 90.541%

Details

  • Coverage decreased (-0.1%) from the base build.
  • Patch coverage: 1 of 1 lines across 1 file are fully covered (100%).
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 2051
Covered Lines: 1857
Line Coverage: 90.54%
Coverage Strength: 1478.99 hits per line

💛 - Coveralls

@ericmj
ericmj removed this pull request from stack #537 November 30, 2026 12:00
@ericmj
ericmj added this pull request to stack #554 November 30, 2026 12:00
The check for 204 and 304 responses, which must not have content, came
before the check for 2xx responses to CONNECT. A CONNECT request
answered with 204 was treated as a response without content, so the
first DATA frame on the tunnel failed the request with a protocol error.

RFC 9110 9.3.6 and RFC 9113 8.5 make any 2xx response to CONNECT
establish a tunnel, so the CONNECT case is checked first and DATA
frames after a 204 are delivered as tunnel data.
@ericmj
ericmj merged commit 86176dd into main Nov 30, 2026
5 of 6 checks passed
@ericmj
ericmj deleted the http2-connect-204 branch November 30, 2026 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants