-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Open
Labels
A-errorArea: error handlingArea: error handling
Description
Currently if an http1 message head exceeds the http1_max_buf_size
, a hyper::Error
is returned where err.is_parse() == true
. This is indistinguishable from other errors that httparse
might bubble up, which poses a problem for deciding how to respond to these errors. A TooLarge
can occur just because of the choices made when setting up the max buffer size (many implementations default to 1MB vs the ~400KB default for hyper
), vs. an actually malformed HTTP message which probably indicates a misbehaving server.
Could we add a new method to hyper::Error
that distinguishes these? hyper::Error::is_buf_size_exceeded()
as a strawman?
Metadata
Metadata
Assignees
Labels
A-errorArea: error handlingArea: error handling