Skip to content

Conversation

seanmonstar
Copy link
Member

Backports #3494 and #3495

Previously, hyper would decode `\r\n\r\n` as `0\r\n\r\n`. This fixes
hyper to require a digit to be present before starting at 0.

Reported-by: Ben Kallus <[email protected]>
The chunked transfer-encoding allows for extensions within the header of
each chunk. hyper currently ignores the extension bytes. Sending large
amounts of bytes in the extensions will waste CPU reaing and skipping
them.

This change adds an internal limit to how many bytes will be read and
ignored in a single body, before returning an error.

Reported-by: Bartek Nowotarski <[email protected]>
@seanmonstar seanmonstar merged commit 344a878 into 0.14.x Dec 18, 2023
@seanmonstar seanmonstar deleted the 0.14-backport-chunked-fixes branch December 18, 2023 14:00
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.

1 participant