Tuesday, July 05, 2005
by Nik Kalyani
Tuesday, July 05, 2005 6:42:52 PM (Pacific Standard Time, UTC-08:00)

Now that I have made significant progress in my WebDAV server API implementation, I can post some details.

My goal is to create an API that faithfully implements RFC2518. This RFC outlines the Http/1.1 Extensions that constitute the WebDAV protocol. There are two levels: Level 1, general WebDAV support, and Level 2, locking support. I plan on supporting both levels, but for the 0.xx release will release with Level 1 support only.

I have designed the API so any developer who knows how to code with a .Net language can use the API. Zero knowledge of WebDAV is required. To use the API, a developer would need to:

1) Reference the API assembly from her/his class project.

2) Provide an implementation of abstract classes WebDAVCollection and WebDAVItem. Basically, you have to map your data store collections and items so that when the API requests a collection or an item, it gets one.

3) Provide an implementation of abstract WebDAVAuthentication class.

To put it in use, you have to:

1) Configure IIS to support file extension .davx and have it respond to all verbs (the extension is irrelevant; if you want, you can have it be .foobar, as long as it responds to all verbs).

2) Add a line similar to the following in your web.config:
<add verb="*" path="MyFiles.davx" type="MyCompany.WebDAV, MyCompany.WebDAV" />

3) Create a file with the name used in #2 (i.e. MyFiles.davx). This file can be empty.

With this in place, Windows or Mac clients can natively map a drive letter using http://yourserver/MyFiles.davx as the path. Alternately, they can directly open a resource as a file from applications such as Word, Excel, HomeSite etc.

I have designed the API so each unique data store type on the server, would have an end-point ({something}.davx) and a line in the web.config.

For example, a handler such as DotNetNukeHTML.davx could be placed in the root of a DotNetNuke portal. A user on a Windows or Mac platform could then map a drive letter using http://yourserver/DotNetNukeHTML.davx/NNN where NNN is the DotNetNuke Portal ID. The user would then see a folder structure where each folder corresponds to a DotNetNuke tab. Within each folder are files corresponding to DotNetNuke module instances. Initially I plan on supporting only the HTML and NukeHTML modules so you would only see files for each instance of these modules. You could then open any of the files using Word, HomeSite or any other HTML Editor and edit the file and save it back. Of course, you can also create a new file which will result in a new module instance being added to the page.

This will basically eliminate the need to use a browser-based editor to create/modify portal content. Just use any rich Windows or Mac editors at your disposal.

This is one example. Using the API, you could also allow full file management on the web server, view a mailbox as a collection of EML files, open up a database table in Excel, there is really no limit to the possibilities. As long as you can figure out a way to present your data (any format) as a data stream that represents the file content expected by a WebDAV-enabled desktop app, you can enable native WebDAV access to your app.

Here's an illustration that gives an overview of how things will work:

WebDAVAPI

Friday, July 08, 2005 1:24:45 PM (Pacific Standard Time, UTC-08:00)
I've been following your WebDAV proposal eagerly. This post raises a couple of concerns. To add the .davx extension to IIS, this would need to be done at the iis managmenet level, right (configuring it for a website or a virtual directory)? My host tries to run ASP.Net code at medium trust and makes an exception for DNN running DNN in a separate app pool. I think it is unlikely that I can pursuade my host to add processing for a new extension.

As I said, I'm eager to see how this goes, but I want to work through any issues before I start making plans that rely on this technology.
Friday, July 08, 2005 1:29:28 PM (Pacific Standard Time, UTC-08:00)
This is not at all unusual for a host to do and has nothing to do with the trust level or the app pool. Basically, unless you tell IIS to accept all verbs, it cannot support WebDAV. By default, .aspx only supports GET and PUT. WebDAV has verbs such as PROPFIND, PROPATCH, MKCOL etc. The host can either add a new extension (example: .davx) or change the default for .aspx to support all verbs. Either is fine, but without it, you cannot have WebDAV because IIS will ignore the client's commands.
Nik Kalyani
Thursday, July 14, 2005 5:33:01 AM (Pacific Standard Time, UTC-08:00)
Nik,

Excellent idea. I've been looking for creative ways to integrate my portal service better with desktop client applications and this has the potential for making many different kinds of things possible. Look forward to the first release -- and would be happy to beta test for you.

-Dharmesh
Wednesday, August 17, 2005 8:56:03 PM (Pacific Standard Time, UTC-08:00)
It's very beautiful site. I like it. All of the best
Tuesday, August 30, 2005 1:32:54 AM (Pacific Standard Time, UTC-08:00)
Hi, I am quite excited when I found your site.
I have spend some time on webdav, and add some features to my CMS. I didn't create special filetype like .davx you had. I thought it is more clean if user open web folder by url like http://server/webfile than http://server/webfile.davx, not mention if it is deeper level, http://server/webfile/folder1 for sure is better. To archieve that, I need create a vritual folder, I havn't found a way to make it work on the root level.
I have two issues(I havn't worked on it for two months, and kind forget what issue I had):
1, I havn't figured out a way to authenticate user, for example, when user open http://server/webfile/folder1 by open web folder on IE, is there a way to prompt user for username and password? I know the default webdav does(or maybe it is just the feature of IIS). now I am using cookie.
2, sometime when I go to http://server/webfile, it will prompt for username and password(note here the different from the previous issue), I found out it is because the client app tries to reach http://server level and that level is not set to be browsable.

Hope you or someone else see my post and can give me some suggestion.
wyx2000
Friday, November 18, 2005 8:38:18 AM (Pacific Standard Time, UTC-08:00)
How far along are you now?
Micheal
Wednesday, December 07, 2005 12:30:19 PM (Pacific Standard Time, UTC-08:00)
Hello friend,
I'm working in a WebDav server implementation on top of ASP.NET to publish some "virtual" documents thats really are database records ...

Can you help me an send me any materials or source code?

thank you,

Rafael Batiati
Rafael Batiati
Sunday, January 15, 2006 5:55:39 PM (Pacific Standard Time, UTC-08:00)
Nik

I have a requirement to implement a WebDAV solution that allows users to open, edit, and save Office documents, which are stored in an Oracle database, via an ASP.NET Web application. Your solution seems to implement this requirement.

If possible, can you please forward me your implementation? I appreciate your help.

Regards,

Chris
Christopher Padgett
Thursday, January 19, 2006 11:19:17 AM (Pacific Standard Time, UTC-08:00)
Hello,
I'm working on a special db file system, which may have a great use for your WebDAV implementation.
Is it possible to get your implementation?

Thanks ahead!

Effy
Friday, January 20, 2006 12:16:04 AM (Pacific Standard Time, UTC-08:00)
Sorry for not having followed-up sooner on some of these comments -- have had the flu.

I had to back-burner WebDAV for some time, but it's back on the front burner again. In fact, another developer is working on it full-time to meet our early Feb. release objective. I guess I should have figured it would be a significant undertaking otherwise it would already have been done. ;-)

The API will be available as a commercial product under a developer's license, with and without source when it is released. It will also be bundled with other Speerio products currently on the roadmap -- http://www.speerio.net/Default.aspx?tabid=820

Nik
Nik Kalyani
Wednesday, January 25, 2006 5:45:15 AM (Pacific Standard Time, UTC-08:00)
I want to know if you will provide only your API without the file management in your product? I am interested because I have my own file management module in DNN and I want to implement the WebDAV protocol for the files comming from this module.

Christian

Thanks
Wednesday, January 25, 2006 6:00:37 AM (Pacific Standard Time, UTC-08:00)
Yep...the standalone API does nothing by itself as the file/folder "collections" are abstract. You have to override them with your own collections and you also have to provide the implementations for actions such as copy/move/delete/create resources, get content, save content etc. The API takes care of the HTTP transaction and your code takes care of the actual manifestation of actions on your collections (whether they are files, database records, etc.)
Nik Kalyani
Monday, February 13, 2006 10:39:28 AM (Pacific Standard Time, UTC-08:00)
The WebDAV API sounds just like what we're looking for -- but I can't find where to buy or download it! Any pointers, or an ETA?

Thanks
Bill
Friday, May 26, 2006 9:49:06 AM (Pacific Standard Time, UTC-08:00)
Is this API dead on the vine? This is a product in which we're very interested.

Thanks.
Brett
Tuesday, February 13, 2007 9:02:34 AM (Pacific Standard Time, UTC-08:00)
May be this WebDAV server API will help: http://www.webdavsystem.com
Here is how to authenticate a user against windows accounts or any custom store: http://www.webdavsystem.com/documentation/authentication
Name
E-mail
(will show your gravatar icon)
Home page

Comment (Some html is allowed: a@href@title, b, i, u) where the @ means "attribute." For example, you can use <a href="" title=""> or <blockquote cite="Scott">.  

Enter the code shown (prevents robots):

Live Comment Preview
RSS feed
Search and Links
Bling

View Nik Kalyani's profile on LinkedIn

Contact me: nik*kalyani.com (replace "*")

TechBubble
www.flickr.com
This is a Flickr badge showing public photos from techbubble. Make your own badge here.
Statistics
Total Posts: 204
This Year: 22
This Month: 0
This Week: 0
Comments: 231
About the author/Disclaimer

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008
Nik Kalyani
Sign In
All Content © 2008, Nik Kalyani