Web.config File for IIS
Example of a web.config file to be copied into the IIS shares.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <directoryBrowse enabled="true" /> <security> <requestFiltering> <fileExtensions> <remove fileExtension=".resources" /> <remove fileExtension=".csproj" /> <remove fileExtension=".resx" /> <remove fileExtension=".vbproj" /> <remove fileExtension=".vb" /> <remove fileExtension=".cs" /> <remove fileExtension=".vjsproj" /> <remove fileExtension=".java" /> <remove fileExtension=".ldf" /> <remove fileExtension=".mdf" /> <remove fileExtension=".mdb" /> <remove fileExtension=".config" /> <add fileExtension="." allowed="true" /> </fileExtensions> <hiddenSegments> <remove segment="bin" /> </hiddenSegments> </requestFiltering> </security> <staticContent> <mimeMap fileExtension="." mimeType="application/octet-stream" /> <mimeMap fileExtension=".*" mimeType="application/octet-stream" /> </staticContent> </system.webServer> </configuration> |
https://github.com/DavidWuibaille/IVANTI/tree/main/WebConfig
Script Configuration for IIS
Installing IIS (requires a reboot)
1 | Commands to enable IIS features and manage file sharing permissions. |
IIS Configuration for Downloading Files Without Extension
To enable the downloading of files without an extension, an IIS configuration is necessary.
- In IIS on the HTTP share, configure the “Mime Types”.

- Add an entry for files without an extension.

If Certain Extensions Cannot Be Downloaded via HTTP
An IIS configuration is necessary.
- In the virtual directory (NOT on the “Default Web Site”), go to “Request Filtering”.

- Remove the extensions that are causing issues.
