0

My issue is relating to large file uploads (>2 GB) that are getting filtered by IIS request filtering.

So how can I completely disable IIS request filtering?

2

1 Answer 1

1

You ask how to disable request filtering entirely (for a site, I assume), and there's a way to do that which I'll offer in a moment.

But first, were you aware that you could at least try to raise the limit for that one aspect of it that might be rejecting the upload? See the discussion of the maxAllowedContentLength element, which can be modified a) within the IIS UI (via the "edit features" link within the Request Filtering feature--at the site or server level) or by editing the web.config (or applicationhost.config for the server level). The element is discussed in this MS doc page.

Finally, if somehow you did really want to remove the request filtering feature completely (which should be done with considerable caution), I will note that I offered an answer to another question asking that, here. Their focus was indeed on removing it for a specific site, but what I share covers also if you wanted to somehow remove it from the server level as well.

4
  • I will add that they specifically mention files over 2GB. The maximum value for uploadReadAheadSize in <serverRuntime> is around 2GB. There appears to be no way around this other than to disable the module entirely.
    – addMitt
    Feb 28, 2023 at 19:31
  • However I'm curious if this actually fixed the issue for OP, because this still did not allow me to upload files larger than 2GB to the server.
    – addMitt
    Feb 28, 2023 at 19:50
  • Are you saying that YOUR fix didn't work, or mine? What specifically of mine did you do? I offered one here and more in the other post I pointed to. Mar 1, 2023 at 20:22
  • I followed your other post and was able to successfully disable the RequestFilteringModule for the site entirely, but in my case that still did not stop a PHP file upload over 2GB from failing once sent to IIS. Couldn't fathom why at that point. We're instead changing gears to create a custom upload form that utilizes file chunking in JavaScript, sent to a custom PHP handler.
    – addMitt
    Mar 2, 2023 at 21:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .