[Zope-dev] Zope 2 WebDAV and acquisition

Martin Aspeli optilude+lists at gmail.com
Wed Oct 7 00:58:11 EDT 2009


Tres Seaver <tseaver <at> palladion.com> writes:

> There is no way to tell the difference between a WebDAV GET and a
> "normal" browser GET, period:  the specs explicitly, deliberately
> overload the GET verb.
> 
> Hence the IANA-assigned "WebDAV source port"[1] (9800) (which *we*
> requested) in order to disambiguate those requests.

Heh, nice.

Unfortuantely, there's no way to guarantee people will only use this port for
Zope's WebDAV server.

That said, the two problems (WebDAV requests result in a browserDefault lookup,
and folder contents) are not really an issue in everyday use for GET request.
They merely cause things to explode on PUT requests to a null resource. We *can*
identify PUT requests, obviously.

So any comments on my proposal to skip the browserDefault lookup and the
acquisition of resources for PUT/PROPFIND/PROPPATCH requests?

This is the IPublishTraverse adapter I've had to register for this stuff to work
right now. As you can see, I have to "undo" certain things the default traversal
does (nice I didn't want to copy all that code and only modify the one condition
needed). 

http://svn.plone.org/svn/plone/plone.dexterity/trunk/plone/dexterity/browser/traversal.py

(ignore the DAV_FOLDER_DATA_ID stuff - that's application specific).

Martin



More information about the Zope-Dev mailing list