Environment
- Elixir version (elixir -v): 1.11.3
- Phoenix version (mix deps): 1.5.8
- Operating system: macOS Big Sur 11.1
Expected behavior
When making a curl request with a large query string (>10,000 bytes), the request succeeds.
Actual behavior
Request fails with:
> Host: localhost:4000
> User-Agent: curl/7.64.1
> Accept: */*
>
< HTTP/1.1 414 Request-URI Too Long
< connection: close
< content-length: 0
<
* Closing connection 0
I thought this may have been happening in Plug.Parsers.fetch_query_params/x but (a) that function has a default limit of 1M bytes and (b) I can prove that function is never called.
I made this example repo where the first plug called in Endpoint prints a "HERE" and halts. Alas, the response is the same (414) and there is no indication that this plug is invoked. Therefore, I have reason to suspect the 414 is coming higher up in the chain.
Environment
Expected behavior
When making a
curlrequest with a large query string (>10,000 bytes), the request succeeds.Actual behavior
Request fails with:
I thought this may have been happening in
Plug.Parsers.fetch_query_params/xbut (a) that function has a default limit of 1M bytes and (b) I can prove that function is never called.I made this example repo where the first plug called in
Endpointprints a "HERE" and halts. Alas, the response is the same (414) and there is no indication that this plug is invoked. Therefore, I have reason to suspect the 414 is coming higher up in the chain.