From b000d53855592c5470a8c2f2dcebc4915ec4d4d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Thu, 7 Dec 2017 22:12:34 +0100 Subject: Add more rfc7231 tests and a new max_skip_body_length option The option controls how much body we accept to skip for HTTP/1.1 connections when the user code did not consume the body fully. It defaults to 1MB. --- doc/src/manual/cowboy_http.asciidoc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'doc') diff --git a/doc/src/manual/cowboy_http.asciidoc b/doc/src/manual/cowboy_http.asciidoc index 0c67d9e..e1936fc 100644 --- a/doc/src/manual/cowboy_http.asciidoc +++ b/doc/src/manual/cowboy_http.asciidoc @@ -28,6 +28,7 @@ opts() :: #{ max_keepalive => non_neg_integer(), max_method_length => non_neg_integer(), max_request_line_length => non_neg_integer(), + max_skip_body_length => non_neg_integer(), middlewares => [module()], request_timeout => timeout(), shutdown_timeout => timeout(), @@ -79,6 +80,10 @@ max_method_length (32):: max_request_line_length (8000):: Maximum length of the request line. +max_skip_body_length (1000000):: + Maximum length Cowboy is willing to skip when the user code did not read the body fully. + When the remaining length is too large or unknown Cowboy will close the connection. + middlewares ([cowboy_router, cowboy_handler]):: Middlewares to run for every request. @@ -93,6 +98,7 @@ stream_handlers ([cowboy_stream_h]):: == Changelog +* *2.2*: The `max_skip_body_length` option was added. * *2.0*: The `timeout` option was renamed `request_timeout`. * *2.0*: The `idle_timeout`, `inactivity_timeout` and `shutdown_timeout` options were added. * *2.0*: The `max_method_length` option was added. -- cgit v1.2.3