Skip to content

fix: handle terminating chunk correctly in Dechunk HTTP response#2258

Open
vishalbhalla02 wants to merge 1 commit intogchq:masterfrom
vishalbhalla02:fix/2247-dechunk-termination
Open

fix: handle terminating chunk correctly in Dechunk HTTP response#2258
vishalbhalla02 wants to merge 1 commit intogchq:masterfrom
vishalbhalla02:fix/2247-dechunk-termination

Conversation

@vishalbhalla02
Copy link

Fixes #2247

  • Detects terminating zero-length chunk (chunkSize === 0)
  • Prevents trailer data from leaking into output
  • Handles chunk termination correctly as per RFC 7230

@CLAassistant
Copy link

CLAassistant commented Mar 17, 2026

CLA assistant check
All committers have signed the CLA.

@GCHQDeveloper581 GCHQDeveloper581 self-requested a review March 18, 2026 15:16
Copy link
Contributor

@GCHQDeveloper581 GCHQDeveloper581 left a comment

Choose a reason for hiding this comment

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

Could you add some tests.

One that would pass before this change (no 0 length section) and one that would fail without this change (eg the case in the original issue #2247)

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.

Bug report: Dechunk HTTP Response leaks terminating chunk and trailers into output

3 participants