Simple proxy_pass settings are invalidating/deleting multipart file data sent by POST

Francis Daly francis at
Sat Oct 6 22:35:07 UTC 2018

On Sat, Oct 06, 2018 at 05:15:50PM -0400, Denis Papathanasiou wrote:

Hi there,

> As noted here -- -- I have a
> simple web app that handles multipart form file uploads correctly on its
> own, but when I put it behind a simple proxy_pass configuration like below,
> the underlying application sees a null value where the file form data was.

If you "tcpdump" (or otherwise) and look at the traffic going to
nginx, and going to the backend, when an upload happens, do you see
any difference?

I've tried a quick test using a command like

  curl -v -F file=@/etc/hosts http://localhost:8000/x/

and the only obvious-to-me difference is that nginx sees the client
"Expect: 100-Continue" request header, but does not send that to upstream.

I think that that should probably not make a difference to the upstream

> If it is not a problem with the wen framework (and based on the logs I
> suspect it is not), how can I update my nginx config so it works properly?

I suspect that you'll have to do some more investigation, to see what is
different on your upstream server when nginx is and is not involved. That
might help point at the problem, and see whether the solution is in
nginx or elsewhere.

Good luck with it,

Francis Daly        francis at

More information about the nginx mailing list