Repository navigation
Fix response decoding, framing, and OPTIONS replay - #52
Merged
Merged
Conversation
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.
Chrome response capture can corrupt non-ASCII bytes and forward compressed or chunked framing for a decoded body. Ordinary OPTIONS requests can also be mistaken for preflights and swallowed until timeout. This change returns the captured bytes with consistent downstream headers and forwards ordinary OPTIONS requests to the server.
Validation used existing dependencies, Chrome 152.0.7977.64, a disposable policy-configured profile, and ordinary local HTTP fixtures through the actual proxy and request engine. All 38 checks passed: navigation/fetch across Unicode, gzip/Brotli/deflate, header casing, chunked bodies, redirects, empty statuses, partial responses and cookies; binary fetch, HEAD, same/cross-origin OPTIONS, network failure, timeout expiry and recovery. Normal responses reused the downstream connection. Repeated Set-Cookie preservation was checked at the formatter boundary because this Chrome build omits those fields from the observed Fetch events. JavaScript syntax and git diff whitespace checks passed.
Post-hook validation passed 36 additional local wire checks using asynchronous hooks over HTTP/1.1 and TLS HTTP/2: growing/shrinking Unicode bodies, binary and typed-array bodies, empty bodies, supported header containers, bodyless status changes, repeated cookies, and fallback responses. All 36 normal Chrome navigation/fetch checks passed again after this change; the two timeout cases were verified in the earlier run.
Repeated-header compatibility passed eight focused checks through the real formatter and bundled hook, plus all 36 HTTP/1.1 and HTTP/2 wire checks with repeated Server values processed by that hook. These checks preserve separate cookies and use local fixtures only.
Details are in
_readme/internal-notes.md. No dependency, Chrome launch configuration, or main README changes. Refs #49.