Login | Register
My pages Projects Community openCollabNet

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Catacomb] DAV property value namespace bug



It appears that there is a bug in the way Catacomb handles namespaces of property values that are XML. For example, a PROPPATCH with:

<?xml version="1.0" encoding="utf-8"?><D:propertyupdate
xmlns:D="DAV:"
xmlns:alpha="http://www.arc.nasa.gov/";
xmlns:custom="http://webdav.org/cadaver/custom-properties/";
><D:set>
<D:prop>
<custom:foo>
<alpha:bar>baz</alpha:bar></custom:foo>
</D:prop></D:set></D:propertyupdate>

In dasl_property, the value is stored as <ns6845556:bar>baz</ns6845556:bar>.



I'm not entirely sure that mod_dav handles this properly either, the response from a PROPFIND looks like the below (note that bar has ns0, not ns2 as you'd expect):

<?xml version="1.0" encoding="utf-8"?>
<D:multistatus xmlns:D="DAV:">
<D:response xmlns:ns0="DAV:" xmlns:ns1="http://webdav.org/cadaver/custom-properties/"; xmlns:ns2="http://www.arc.nasa.gov/"; xmlns:lp1="DAV:" xmlns:lp2="http://apache.org/dav/props/";>
<D:href>/davfs/</D:href>
<D:propstat>
<D:prop>
<ns1:foo>
<ns0:bar>baz</ns0:bar></ns1:foo>
<lp1:resourcetype><D:collection/></lp1:resourcetype>
<lp1:creationdate>2002-12-31T00:03:08Z</lp1:creationdate>
<lp1:getlastmodified>Tue, 31 Dec 2002 00:03:08 GMT</lp1:getlastmodified>
<lp1:getetag>"42d2d-200-eaa82700"</lp1:getetag>
<D:supportedlock>
<D:lockentry>
<D:lockscope><D:exclusive/></D:lockscope>
<D:locktype><D:write/></D:locktype>
</D:lockentry>
<D:lockentry>
<D:lockscope><D:shared/></D:lockscope>
<D:locktype><D:write/></D:locktype>
</D:lockentry>
</D:supportedlock>
<D:lockdiscovery/>
<D:getcontenttype>httpd/unix-directory</D:getcontenttype>
</D:prop>
<D:status>HTTP/1.1 200 OK</D:status>
</D:propstat>
</D:response>
</D:multistatus>

(I've filed a bug in the Apache Bugzilla db regarding mod_dav's behavior.)