> If you are using django-rest-framework, how would the fields counter work?. It would be a shame if only multi part and urlencoded uploads would have the benefit of these checks, while still allowing json, xml and others still be "exploited".
Note I didn't really read the code changes completely so I'm talking with almost no knowledge on the proposed change.
They wouldn't be respected by anything other than multi-part or urlencoded requests.
Tim's correct in noting that accessing `request.body` or `request.stream` won't apply these checks (which is for example, what REST framework does).
Even so I think this is probably a reasonable approach. We could add support for respecting these settings in REST framework too, once they exist.(Although I think we'd have need to have a stricter consideration of backwards compat wrt. folks POSTing large amounts of JSON data)