diff options
author | Jeremy Evans <[email protected]> | 2020-07-15 08:38:44 -0700 |
---|---|---|
committer | Hiroshi SHIBATA <[email protected]> | 2020-11-13 11:35:10 +0900 |
commit | 957efa95cc12c608705a5663256226f022ea6c7f () | |
tree | e85362f238f86d483025792f964477672576a13c /lib | |
parent | 6325866421d552c43ecc0f631fc9e848f9a2862f (diff) |
[ruby/webrick] Allow empty POST and PUT requests without content length
RFC 7230 section 3.3.3 allows for this. Fixes #30 https://.com/ruby/webrick/commit/069e9b1908
-rw-r--r-- | lib/webrick/httprequest.rb | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -522,7 +522,7 @@ module WEBrick if @remaining_size > 0 && @socket.eof? raise HTTPStatus::BadRequest, "invalid body size." end - elsif BODY_CONTAINABLE_METHODS.member?(@request_method) raise HTTPStatus::LengthRequired end return @body |