-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

All,

In my application under Tomcat 8.5.51, I have configured a servlet to
allow multipart/form-data submissions and I have added this
configuration as a part of the <servlet> config:

    <multipart-config>
      <max-file-size>1048576</max-file-size><!-- 1MiB -->
      <max-request-size>1049600</max-request-size><!-- 1 MiB + 1 kiB -->
    </multipart-config>

Without the <multipart-config> section, the upload does not work at
all, so I know I have added this in the right place.

But I am able to upload files larger than 1MiB, and the data is being
given to the servlet. I was expecting an error to be sent to the
client (unlikely) or the data to be suppressed from the servlet, or
some kind of indication to the servlet code that the upload was too big.

The file I'm uploading as a test is 13658819 bytes, which is greater
than both 1048576 and 1049600.

What am I missing, here?

- -chris
-----BEGIN PGP SIGNATURE-----
Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAl6CWnEACgkQHPApP6U8
pFi1tRAAvs2wnlIgmfTeBpWWWFXh+vP+hOdgqW+7u/WiSb5viXvnYfoa+ezpiy7S
XHzctsBoQhs4Q+ErC1Ikz41btnuGbppnFe97mVplGDyca7aknxxdiLBP11azrD++
Ojn37bHjVFg1YzDFNDIJgG+yQC6/P0iFiMAUUsU1LM9oAOupLfiDyn+H6KLs/yV8
Z/NteP9GDgLvfNdmN1c+2gtAn0diRYOSvIOStXyS2Bsa1kueAu9zjIoHLMZExkdi
TrbmOBZV6/dR4LDP5/ZtIfuKA9urTIfMIpXqufyZh4A0Dk9QcDZMeh2t1txaAmEU
cRCwJkOIlkjq0GYAp8PvaTOSguvaw0om4d2z4V/l0Htov4bvW7h6Tzfx2LGXm2e8
KoqtGkQ9DSUclH3b/ik/Urwxoher24TnN4RcZlTamIJj7JBI5+n+x0YVzqn501Zz
VDTiuHUdNqKX1eqDTRjish0OFUKU6rUipnMZNzVQnKtgHqm5qHvwJan1r/chpQ1f
t4Fyujvs6N2q/K9N6gbvi+MY+hqlEyquOffuC6SY0dZGJkLXBffDqrMZyheOz+5h
RRxGqnrs7ZE2pme5KUdaYFmdDk1gUUph/ezudj1zuQNWVgx/W5T7J/+VuP2SAgoB
oKh5dHtRqCSPQq/Gv79OxxtzD/b5OcimvX2gGvq/OhCmMdYuVv0=
=kWh7
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to