Configuring WebDAV Server in IIS 7, 6, 5
Web application configuration is required if you plan to host your WebDAV Server in IIS. If you are creating HttpListener-based WebDAV server no IIS is required to be installed.
Creating WebDAV Server Web Application
Open your IIS MMC console and create web application that will be the root of your WebDav Server storage. This web application must be mapped to the folder where your \bin folder with dlls and web.config file resides. To avoid Web Folders client bags on Windows XP and Windows Vista we recommend mapping you WebDAV server to the root of the website.
Web application must catch GET, HEAD, PUT, OPTIONS, PROPFIND, PROPPATCH, COPY, MOVE, DELETE, MKCOL, LOCK and UNLOCK verbs and forward them to your custom HttpHandler. For the sake of simplicity we will create wildcard application map in IIS 7, 6, 5 and catch all verbs send to server.
In Windows XP and Windows 2000 Server (IIS 5 and earlier versions)
To create application map right click on your web application in IIS 5 MMC console and go to Properties->Virtual Directory Tab->Configuration. Click Add to add new application extension mapping. Executable - <Windows Install Folder>\Microsoft.NET\Framework\<.Net Framework Version>\aspnet_isapi.dll Extension - .* Verbs – All verbs Verify that file exists – Unchecked
On Home Directory tab of your application properties set Execute permissions to Scripts only and allow reads.
In Windows Server 2003 (IIS 6)
To create application map right click on your web application in IIS 6 MMC console and go to Properties->Virtual Directory Tab->Configuration. Click Insert to add new wildcard map. Executable - <Windows Install Folder>\Microsoft.NET\Framework\<.Net Framework Version>\aspnet_isapi.dll Verify that file exists - Unchecked

On Home Directory tab of your application properties set Execute permissions to Scripts only and allow reads.
In Windows Vista and Windows Server 2008 (IIS 7)
Your WebDAV server application can utilize Integrated ASP.NET application pool or Classic application pool.
Classic Application Pool
To run WebDAV server in Classic application pool at a minimum ISAPI Extensions must be enabled. To enable ISAPI Extensions go to ‘Control Panel->Programs and Features->Turn Windows features on or off’.
Open IIS 7 MMC console and click on your web application. Than go to Handler Mappings. Click Add Script Map. Request Path: * Executable - <Windows Install Folder>\Microsoft.NET\Framework\<.Net Framework Version>\aspnet_isapi.dll Request Restrictions -> Mapping Tab -> Invoke handler only if request is mapped to – Unchecked Request Restrictions -> Verbs Tab – All Verbs

Integrated Application Pool
To run your web application in the Integrated application pool you must enable ASP.NET via ‘Control Panel->Programs and Features->Turn Windows features on or off’. You do not need to crate aspnet_isapi.dll mapping or configure IIS 7 via MMC console. IIS 7 will use <system.webServer> tag from your web.config file to configure handler mappings:
<configuration>
...
<system.webServer>
<handlers>
<clear />
<add name="My WebDAV Handler" path="*" verb="*" type="WebDAVServer.SqlStorage.WebDAVHandler, WebDAVServer.SqlStorage" preCondition="integratedMode,runtimeVersionv2.0" />
</handlers>
...
</system.webServer>
</configuration>
|