Closed chibenwa closed 8 months ago
Opened https://github.com/playframework/play-json/issues/984
It looks like we are going to need to add a safeguard at the HTTP level when receiving the post request!
In jmap.properties
api.request.max.size=5M
And check that prior deserializing here: https://github.com/apache/james-project/blob/05b72736a07e51c0e83350cc918e2f71b00c785b/server/protocols/jmap-rfc-8621/src/main/scala/org/apache/james/jmap/routes/JMAPApiRoutes.scala#L85
This could be done either by checking readable bytes or by using LimitedInputStream
it will easily be done by config in api gateway Example: https://docs.nginx.com/nginx-management-suite/acm/how-to/policies/request-body-size-limit/#:~:text=The%20Request%20Body%20Size%20Limit,error%20code%20will%20be%20returned.
Ok with me too.
More on APISIX then.
Please go ahead with a patch on tmail-backend helm chart.
Reviewed. We IMO need 2 settings: one for uploads, one for everyting else...
By default that is 20MB.
That's a LOT!
I would prefer seeing a smaller size eg 500KB
That's user input, we should definitly consider it as non-safe!
Let's make this configurable?
CF
Definition of done