Skip to content

Microsoft Office Client

mikedeboer edited this page Feb 24, 2013 · 2 revisions

Microsoft Office WebDAV client

Before MS Office 2000 there was no WebDAV support in the Office suite, but it wasn't until Office 2003 when the company integrated a better client. For information about how to work with WebDAV on versions prior to Office 2003, you may find useful this page: http://www.atarex.com/services/support/webdav-msft.shtml

The following observations of the Microsoft WebDAV client in Office was taken using Word. Other applications of the suite may behave the same way.

Authentication

Office understands both HTTP Basic and Digest authentication.

Reading files

No problems found downloading and showing a document. Office will try to set a lock in any case.

Writing files

Locks are required for saving, otherless MS Word will open the file as read only.

If a file is locked, Office 2007 and 2010 will ask you if you want to open the file as read only, download and modify it only in your computer or allow editing while in background the lock is checked at an interval (usually less than 20 seconds) until the file is released.

Once Office 2003 and 2007 gets the lock, it is updated at the "x" minutes interval you specify in your jsDav locks plugin (30 minutes by default), but this time cannot be less than 180 seconds.

Office 2010 (Beta) has some kind of bug which makes the program don't update the lock anymore, so if another client checks the lock after the timeout, the lock will be released. This behaviour was observed in the Beta, so it may be corrected by the final product version.

LockRoot

It was discovered that certain versions of Office break if the {DAV:}lockdiscovery property contains a {DAV:}lockroot element.

To fix this, you can hide this element using the following code snippet:
jsDAV_Property_LockDiscovery.hideLockRoot = true;
Hiding it hasn't caused any issues for other clients, so it should be safe to call this.

Properties

Microsoft office may perform the following request to update a file's properties:

    <D:propertyupdate xmlns:D="DAV:" xmlns:Z="urn:schemas-microsoft-com:">
        <D:set>
            <D:prop>
                <Z:Win32CreationTime>Mon, 12 Dec 2011 17:37:08 GMT</Z:Win32CreationTime>
                <Z:Win32LastAccessTime>Mon, 12 Dec 2011 17:37:08 GMT</Z:Win32LastAccessTime>
                <Z:Win32LastModifiedTime>Mon, 12 Dec 2011 17:37:08 GMT</Z:Win32LastModifiedTime>
                <Z:Win32FileAttributes>00002002</Z:Win32FileAttributes>
            </D:prop>
        </D:set>
    </D:propertyupdate>

However, it appears to disregard any existing locks on the resource, and attempt to perform this request without any supplied lock tokens.

Office 2011 for Mac notes

When using the "Open URL" feature from Office 2011, it makes the following PROPFIND request:

PROPFIND /filename.docx HTTP/1.1
From: 127.0.0.1
User-Agent: Microsoft Office
Accept: */*
Accept-Language: en
Translate: f
Brief: t
Depth: 0
Content-Type: text/xml; charset=utf-8
Content-Length: 236
Connection: Keep-Alive
Host: localhost:80

<?xml version="1.0" encoding="utf-8"?><D:propfind xmlns:D="DAV:"><D:prop><D:resourcetype/><D:getetag/><D:getcontentlength/><D:getmodifiedby/><D:creationdate/><D:getlastmodified/><D:lockdiscovery/><D:supportedlock/></D:prop></D:propfind>

Based on the original document at http://code.google.com/p/sabredav/wiki/MicrosoftOfficeClient