5

Currently if I am hosting an Access .MDB file to allow users to download, IIS7 is throwing a 404 error. I know the file is there and the permissions are fine. It appears to be a Handler issue, but I cannot figure out how to change the handler to allow downloading of MDB file. I assume I need to add something to the Handlers section of the web.config, but I am unsure of the syntax.

Thanks.

Fionnuala
  • 90,370
  • 7
  • 114
  • 152
Bryan Lewis
  • 5,629
  • 4
  • 39
  • 45

2 Answers2

9

Or, if you don't want to modify a system-wide configuration file, you could add the following lines to that section in your web.config:

<remove fileExtension=".mdb" />
<add fileExtension=".mdb" allowed="true"/>

For example your Web.config should be similar to this:

<configuration>
  <system.webServer>
    <security>
      <requestFiltering>
        <fileExtensions allowUnlisted="true" >
          <remove fileExtension=".mdb" />
          <add fileExtension=".mdb" allowed="true"/>
        </fileExtensions>
     </requestFiltering>
   </security>
 </system.webServer>
</configuration>

Also see http://www.adamwlewis.com/articles/iis-7-not-serving-files-4047-error.

davidrl1000
  • 311
  • 1
  • 4
  • 16
Yorick Sijsling
  • 920
  • 1
  • 6
  • 9
2

OK, found it.

Just need to remove the following line:

<add fileExtension=".mdb" allowed="false" />

in the "requestFiltering" section from the \Windows\System32\inetserv\config\applicationHost.config file.

Bryan Lewis
  • 5,629
  • 4
  • 39
  • 45