totaljs / framework

Node.js framework
http://www.totaljs.com
Other
4.36k stars 450 forks source link

Request Header Fields Too Large #722

Closed buzzeins closed 5 years ago

buzzeins commented 5 years ago

Hi, got some issue with a multipart/form-data request.

Problem: The same request can be properly passed, or even being trown (unsystematically) with 431 (Request Header Fields Too Large). Like here: image

It's exactly the same request...

image

What's wrong?

Environment:

Node.js : v8.16.0 Total.js : v3.2.4 OS : linux 4.15.0-54-generic Mode : debug

Route

F.route('/app/elem/{id}', save, ['upload', 1024 1024], 1024 1024);

config:

default_request_maxlength : 1048576 default_request_length : 1048576

Request snip example:

POST /surf/spot/260 HTTP/1.1 Connection: keep-alive Content-Length: 5364 Pragma: no-cache Cache-Control: no-cache Accept: application/json, text/plain, text/html, / User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.142 Safari/537.36 Content-Type: multipart/form-data; boundary=----WebKitFormBoundarymYffuyF5Guhyzsna Accept-Encoding: gzip, deflate Accept-Language: de-DE,de;q=0.9,en-US;q=0.8,en;q=0.7

petersirka commented 5 years ago

Hi @buzzeins,

Please, try to install Total.js beta $ npm install total.js@beta and try your example again. I found a bug in upload parser last month ago. Let me know.

buzzeins commented 5 years ago

Yeah, workin' with @beta now, thanks :D When are you planning the release?

petersirka commented 5 years ago

Great. I wanted to publish it previous month. I hope that this new version will be in august.

buzzeins commented 5 years ago

cool