Repository navigation
Feat: Forward WebSocket upgrades on intercepted connections #1549
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
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
ddd7210
feat: forward WebSocket upgrades on intercepted connections
mrsabath 136d801
fix: sanitize the host in the WebSocket relay's log lines
mrsabath 6cae5d1
fix: fence SanitizeControlRunes so CodeQL's log-injection tracking st…
mrsabath 5de6c31
fix: fence the relay's log host at the sink, not inside the sanitizer
mrsabath 0d2258b
test: wait for the reverse proxy's deferred response row everywhere
mrsabath 238d31f
Merge main into feat/sbx-ws-upgrade
mrsabath 6ea26f8
Merge branch 'main' into feat/sbx-ws-upgrade
mrsabath 13a3123
fix: Close the origin and unstrand the splice when a WebSocket relay …
mrsabath 020d4b9
Merge branch 'main' into feat/sbx-ws-upgrade
mrsabath 81d62cb
fix: Require both upgrade headers, and check the 101's protocol (#1488)
mrsabath aa98ecc
fix: Keep a WebSocket's 101 row out of /v1/usage, and mark a broken r…
mrsabath 576d16e
Merge main into feat/sbx-ws-upgrade (#1488)
mrsabath 44896a1
fix: forward the origin's half-close over the TLS bridge (#1488)
mrsabath d434ee7
test: name Direction among the fields the 101 exclusion reads (#1488)
mrsabath dfd1a60
Merge main into feat/sbx-ws-upgrade (#1488)
mrsabath File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion: the 101 exclusion also swallows the error marker the last round added — a WebSocket that broke mid-session is invisible in
/v1/usage's Errors count.This return runs before error counting, so an outbound 101 carrying
proxy_errornever reaches the Errors fold. The pre-splice failures still count —recordSpliceFailurerecords a 502 row, which passes this guard — but the mid-session break, the case the marker exists for, does not.That is the tunnel precedent (a
dial-failedtunnel close is excluded the same way), but it is the opposite of the broken-SSE-stream rule from #1543, where the row's explicit error is what the Errors count reads, not the status. The comment here justifies the exclusion on latency, bytes and Requests — the Errors consequence is in none of the three, nor in session-api.md, whose "distinguishable" claim a reader could reasonably take as counting.Either let an error-carrying 101 fall through to the error fold (skipping only the latency/Requests fold), or add one line here and in session-api.md saying a broken relay does not appear in the Errors count. Not blocking — the timeline row is right either way.