Server will now throw BAD_REQUEST when a HTTP 1.0 client sends a Transfer-Encoding header (ref).
Any chunk-ext present on chunksize lines is now trimmed out, since we wont be supporting any.
Chunk sizes are now properly validated.
Added overflow check when calculating the total size of a chunked request body.
Limited the total length of a chunksize line (altough somewhat arbitrarily).
Implemented Reader::read_exact_into to avoid creating a temporary buffer and extra copy when appending to a chunked request body.
Chunked transfer should now be stable. The only thing that should be missing from this is limiting the length of trailer lines, but this is no different from header lines, so i'll be handling that in #36.
Main changes
BAD_REQUEST
when a HTTP 1.0 client sends a Transfer-Encoding header (ref).chunk-ext
present on chunksize lines is now trimmed out, since we wont be supporting any.Reader::read_exact_into
to avoid creating a temporary buffer and extra copy when appending to a chunked request body.Chunked transfer should now be stable. The only thing that should be missing from this is limiting the length of trailer lines, but this is no different from header lines, so i'll be handling that in #36.