-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
request.max_content_length is only enforced when parsing form data #1096
Comments
To summarize: pass |
I'm puzzled that this is closed. Using werkzeug via Flask, |
It's three years old, I'm sure I closed it for a reason, but I don't remember what it was off the top of my head. This is unreliable anyway, use your HTTP server to control the allowed request size. |
Sure; but if it's unreliable, I would offer that it should be removed altogether, rather than staying in with surprising behaviour. |
Fixed by #2620 |
It should be enforced for raw
get_data
as well. Not sure if it should apply tostream
, since at that point you probably know what you're doing.Also, it's only enforced if the
Content-Length
header is set, so chunked requests can spin forever and consume memory.One solution might be to provide a
max_input_length
toget_input_stream
and always return aLimitedStream
if it is set.The text was updated successfully, but these errors were encountered: