Hi,
we have a route that uses fastfy-raw-body and sets a bigger bodyLimit on a single route, but fastify-raw-body does not respect it and instead keep using the smaller fastify default bodyLimit (see
|
limit: fastify.initialConfig.bodyLimit, // limit to avoid memory leak or DoS |
)
This in turn causes an issue that's difficult to debug because the error from raw-body is ignored in
|
if (err) { |
|
/** |
|
* the error is managed by fastify server |
|
* so the request object will not have any |
|
* `body` parsed |
|
*/ |
|
return |
, but fastify is not actually raising nor returning any error as the limit is bigger.
As a result of this, the requests just hangs up without ever responding to the client.
I have a created a reduced test case at https://gist.github.com/paolochiodi/7176009653df985ddcd33e51fecb4959
Hi,
we have a route that uses
fastfy-raw-bodyand sets a biggerbodyLimiton a single route, butfastify-raw-bodydoes not respect it and instead keep using the smaller fastify defaultbodyLimit(seefastify-raw-body/plugin.js
Line 61 in 84f755f
This in turn causes an issue that's difficult to debug because the error from
raw-bodyis ignored infastify-raw-body/plugin.js
Lines 64 to 70 in 84f755f
As a result of this, the requests just hangs up without ever responding to the client.
I have a created a reduced test case at https://gist.github.com/paolochiodi/7176009653df985ddcd33e51fecb4959