tickets: 16201
This data as json
id | created | changetime | last_pulled_from_trac | stage | status | component | type | severity | version | resolution | summary | description | owner | reporter | keywords | easy | has_patch | needs_better_patch | needs_tests | needs_docs | ui_ux |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
16201 | 2011-06-09 16:09:56 | 2011-08-23 15:57:01 | 2022-03-06 04:02:33.100229 | Ready for checkin | closed | HTTP handling | Bug | Normal | 1.3-rc | fixed | When Content-Length is 0, MultiPartParser violates RFC2616 | RFC 2616 says that: "Any Content-Length greater than or equal to zero is a valid value." http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.13 Currently {{{ MultiPartParser }}} doesn't handle "Content-Length: 0". The patch I've attached returns an empty request.POST in {{{ MultiPartParser.parser() }}} if the "Content-Length: 0" instead of raising an exception on {{{ MultiPartParser.__init__() }}}. I've also added the tests for this particular case in requests/tests. ( {{{ ./runtests.py --settings=test_sqlite requests.RequestsTests.test_POST_multipart_with_content_length_zero }}} ) | nobody | albsen | http multipart | 0 | 1 | 0 | 0 | 0 | 0 |