-
Notifications
You must be signed in to change notification settings - Fork 1
Closed
Labels
Description
This would prevent out of memory scenarios. Defaults vary, around 8K - 16K, see https://stackoverflow.com/questions/686217/maximum-on-http-header-values - however, 8K is easily reached by some of the newer JWT-cookies.
Motivation
Uncapped HTTP header size keeps the server exposed to attacks and can bring down its capacity to serve organic traffic.
- GHSA-2p2c-vwq7-7vg6
- https://nodejs.org/en/blog/vulnerability/november-2018-security-releases#denial-of-service-with-large-http-headers-cve-2018-12121
- Max header size of 8KB is a breaking change nodejs/node#24731
- Increase HTTP_MAX_HEADER_SIZE to 16kb nodejs/node#27645
- When http header size limit is reached, instead of a generic 400 response, return 431 Request Header Fields Too Large nodejs/node#25528
- Add an error message warning developers of oversized headers. meteor/meteor#10877
- https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#3.2-tune.http.maxhdr