<div dir="ltr">Hi,<div><br></div><div>I have checked twisted.web.http.HTTPChannel and I see that it limits the headers by number and not by size.</div><div><br></div><div><a href="https://github.com/twisted/twisted/blob/trunk/twisted/web/http.py#L1596">https://github.com/twisted/twisted/blob/trunk/twisted/web/http.py#L1596</a></div>

<div><br></div><div>Maybe I don't see the big picture, but wouldn't this allow the server to load in memory a request with a single header of 1G ?</div><div><div><br></div><div>Other than changing the HTTPChannel.lineReceived() implementation, is there a way to limit header size?</div>

<div><br></div><div>I did a quick test and the server accepted an 1M cookie value without any problem.</div><div><br></div><div>curl --cookie cookies.txt <a href="http://localhost:8080">http://localhost:8080</a><br></div>

<div>cookies.txt in in this format <a href="https://gist.github.com/adiroiban/8557725">https://gist.github.com/adiroiban/8557725</a></div><div><br></div><div>It this a feature or a bug?</div><div><br></div><div>Many thanks!</div>

-- <br>Adi Roiban
</div></div>