idnits 2.17.1
draft-reschke-webdav-search-01.txt:
Checking boilerplate required by RFC 5378 and the IETF Trust (see
https://trustee.ietf.org/license-info):
----------------------------------------------------------------------------
** Looks like you're using RFC 2026 boilerplate. This must be updated to
follow RFC 3978/3979, as updated by RFC 4748.
Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt:
----------------------------------------------------------------------------
** The document seems to lack a 1id_guidelines paragraph about
Internet-Drafts being working documents.
== No 'Intended status' indicated for this document; assuming Proposed
Standard
== It seems as if not all pages are separated by form feeds - found 1 form
feeds but 55 pages
Checking nits according to https://www.ietf.org/id-info/checklist :
----------------------------------------------------------------------------
No issues found here.
Miscellaneous warnings:
----------------------------------------------------------------------------
== The copyright year in the RFC 3978 Section 5.4 Copyright Line does not
match the current year
== Line 834 has weird spacing: '...LIST lt cas...'
== Line 837 has weird spacing: '...IST lte case...'
== Line 840 has weird spacing: '...LIST gt cas...'
== Line 843 has weird spacing: '...IST gte case...'
== Line 846 has weird spacing: '...LIST eq cas...'
== (1 more instance...)
== The document seems to lack the recommended RFC 2119 boilerplate, even if
it appears to use RFC 2119 keywords -- however, there's a paragraph with
a matching beginning. Boilerplate error?
(The document does seem to have the reference to RFC 2119 which the
ID-Checklist requires).
== Using lowercase 'not' together with uppercase 'MUST', 'SHALL', 'SHOULD',
or 'RECOMMENDED' is not an accepted usage according to RFC 2119. Please
use uppercase 'NOT' together with RFC 2119 keywords (if that is what you
mean).
Found 'SHOULD not' in this paragraph:
Query grammars are identified by URIs. Applications SHOULD not
attempt to retrieve these URIs even if they appear to be retrievable (for
example, those that begin with "http://")
-- The document seems to lack a disclaimer for pre-RFC5378 work, but may
have content which was first submitted before 10 November 2008. If you
have contacted all the original authors and they are all willing to grant
the BCP78 rights to the IETF Trust, then this is fine, and you can ignore
this comment. If not, you may need to add the pre-RFC5378 disclaimer.
(See the Legal Provisions document at
https://trustee.ietf.org/license-info for more information.)
-- The document date (June 2002) is 7979 days in the past. Is this
intentional?
Checking references for intended status: Proposed Standard
----------------------------------------------------------------------------
(See RFCs 3967 and 4897 for information about using normative references
to lower-maturity documents in RFCs)
== Unused Reference: 'XMLNS' is defined on line 1659, but no explicit
reference was found in the text
== Outdated reference: A later version (-13) exists of
draft-ietf-webdav-acl-07
** Obsolete normative reference: RFC 2518 (Obsoleted by RFC 4918)
** Obsolete normative reference: RFC 2616 (Obsoleted by RFC 7230, RFC 7231,
RFC 7232, RFC 7233, RFC 7234, RFC 7235)
** Obsolete normative reference: RFC 3023 (Obsoleted by RFC 7303)
-- Possible downref: Non-RFC (?) normative reference: ref. 'XML'
-- Possible downref: Non-RFC (?) normative reference: ref. 'XMLNS'
-- Possible downref: Non-RFC (?) normative reference: ref. 'XS2'
-- No information found for draft-dasl-protocol - is the name correct?
-- No information found for draft-dasl-requirements - is the name correct?
Summary: 5 errors (**), 0 flaws (~~), 13 warnings (==), 7 comments (--).
Run idnits with the --verbose option for more detailed information about
the items above.
--------------------------------------------------------------------------------
2 Network Working Group J. F. Reschke
3 Internet Draft greenbytes
4 Expires: December 2002 S. Reddy
5 Oracle
6 J. Davis
7 Intelligent Markets
8 A. Babich
9 Filenet
10 June 2002
12 WebDAV SEARCH
13 draft-reschke-webdav-search-01
15 Status of this Memo
17 This document is an Internet-Draft and is in full conformance with
18 all provisions of Section 10 of RFC2026. Internet-Drafts are working
19 documents of the Internet Engineering Task Force (IETF), its areas,
20 and its working groups. Note that other groups may also distribute
21 working documents as Internet-Drafts.
23 Internet-Drafts are draft documents valid for a maximum of six months
24 and may be updated, replaced, or obsoleted by other documents at any
25 time. It is inappropriate to use Internet-Drafts as reference
26 material or to cite them other than as "work in progress".
28 The list of current Internet-Drafts can be accessed at
29 http://www.ietf.org/ietf/1id-abstracts.txt.
31 The list of Internet-Draft Shadow Directories can be accessed at
32 http://www.ietf.org/shadow.html.
34 This Internet-Draft will expire in December 2002.
36 Copyright Notice
38 Copyright (C) The Internet Society (2002). All Rights Reserved.
40 Abstract
42 This document specifies a set of methods, headers, properties and
43 content-types composing WebDAV SEARCH, an application of the HTTP/1.1
44 protocol to efficiently search for DAV resources based upon a set of
46 .
48 client-supplied criteria.
50 Distribution of this document is unlimited. Please send comments to
51 the Distributed Authoring and Versioning (WebDAV) DASL mailing list
52 at www-webdav-dasl@w3.org, which may be joined by sending a message
53 with subject "subscribe" to www-webdav-dasl-request@w3.org.
54 Discussions of the WebDAV DASL mailing list are archived at URL:
55 http://www.w3.org/pub/WWW/Archives/Public/www-webdav-dasl/.
57 .
59 Table of Contents
61 Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
62 Table of Contents . . . . . . . . . . . . . . . . . . . . . . 3
63 1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . 5
64 1.1 DASL . . . . . . . . . . . . . . . . . . . . . . . . . . 5
65 1.2 Relationship to DAV . . . . . . . . . . . . . . . . . . 5
66 1.3 Terms . . . . . . . . . . . . . . . . . . . . . . . . . 5
67 1.4 Notational Conventions . . . . . . . . . . . . . . . . . 6
68 1.5 An Overview of DASL at Work . . . . . . . . . . . . . . 6
69 2 The SEARCH Method . . . . . . . . . . . . . . . . . . . . . 7
70 2.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . 7
71 2.2 The Request . . . . . . . . . . . . . . . . . . . . . . 7
72 2.2.1 The Request-URI . . . . . . . . . . . . . . . . . . 7
73 2.2.2 The Request Body . . . . . . . . . . . . . . . . . . 7
74 2.3 The DAV:searchrequest XML Element . . . . . . . . . . . 8
75 2.4 The Successful 207 (Multistatus) Response . . . . . . . 8
76 2.4.1 Extending the PROPFIND Response . . . . . . . . . . 8
77 2.4.2 Example: A Simple Request and Response . . . . . . . 8
78 2.4.3 Example: Result Set Truncation . . . . . . . . . . . 9
79 2.5 Unsuccessful Responses . . . . . . . . . . . . . . . . . 11
80 2.6 Invalid Scopes . . . . . . . . . . . . . . . . . . . . . 11
81 2.6.1 Indicating an Invalid Scope . . . . . . . . . . . . 11
82 2.6.2 Example of an Invalid Scope . . . . . . . . . . . . 12
83 3 Discovery of Supported Query Grammars . . . . . . . . . . . 13
84 3.1 The OPTIONS Method . . . . . . . . . . . . . . . . . . . 13
85 3.2 The DASL Response Header . . . . . . . . . . . . . . . . 13
86 3.3 DAV:supported-query-grammar-set (protected) . . . . . . 14
87 3.4 Example: Grammar Discovery . . . . . . . . . . . . . . . 14
88 4 Query Schema Discovery: QSD . . . . . . . . . . . . . . . . 17
89 4.1 Additional SEARCH semantics . . . . . . . . . . . . . . 17
90 4.1.1 Example of query schema discovery . . . . . . . . . 18
91 5 The DAV:basicsearch Grammar . . . . . . . . . . . . . . . . 20
92 5.1 Introduction . . . . . . . . . . . . . . . . . . . . . . 20
93 5.2 The DAV:basicsearch DTD . . . . . . . . . . . . . . . . 20
94 5.2.1 Example Query . . . . . . . . . . . . . . . . . . . 21
95 5.3 DAV:select . . . . . . . . . . . . . . . . . . . . . . . 22
96 5.4 DAV:from . . . . . . . . . . . . . . . . . . . . . . . . 23
97 5.4.1 Relationship to the Request-URI . . . . . . . . . . 23
98 5.4.2 Scope . . . . . . . . . . . . . . . . . . . . . . . 23
99 5.5 DAV:where . . . . . . . . . . . . . . . . . . . . . . . 24
100 5.5.1 Use of Three-Valued Logic in Queries . . . . . . . . 24
101 5.5.2 Handling Optional operators . . . . . . . . . . . . 24
102 5.5.3 Treatment of NULL Values . . . . . . . . . . . . . . 25
103 5.5.4 Treatment of properties with mixed/element content . 25
104 5.5.5 Example: Testing for Equality . . . . . . . . . . . 25
105 5.5.6 Example: Relative Comparisons . . . . . . . . . . . 25
106 5.6 DAV:orderby . . . . . . . . . . . . . . . . . . . . . . 26
108 .
110 5.6.1 Comparing Natural Language Strings. . . . . . . . . 26
111 5.6.2 Example of Sorting . . . . . . . . . . . . . . . . . 27
112 5.7 Boolean Operators: DAV:and, DAV:or, and DAV:not . . . . 27
113 5.8 DAV:eq . . . . . . . . . . . . . . . . . . . . . . . . . 27
114 5.9 DAV:lt, DAV:lte, DAV:gt, DAV:gte . . . . . . . . . . . . 28
115 5.10 DAV:literal . . . . . . . . . . . . . . . . . . . . . . 28
116 5.11 DAV:is-collection . . . . . . . . . . . . . . . . . . . 28
117 5.11.1 Example of DAV:is-collection . . . . . . . . . . . 28
118 5.12 DAV:isdefined . . . . . . . . . . . . . . . . . . . . . 28
119 5.13 DAV:like . . . . . . . . . . . . . . . . . . . . . . . 29
120 5.13.1 Syntax for the Literal Pattern . . . . . . . . . . 29
121 5.13.2 Example of DAV:like . . . . . . . . . . . . . . . . 30
122 5.14 DAV:contains . . . . . . . . . . . . . . . . . . . . . 30
123 5.14.1 Examples . . . . . . . . . . . . . . . . . . . . . 31
124 5.15 The DAV:limit XML Element . . . . . . . . . . . . . . . 32
125 5.16 The DAV:nresults XML Element . . . . . . . . . . . . . 32
126 5.17 The "casesensitive" XML attribute . . . . . . . . . . . 32
127 5.18 The DAV:score Property . . . . . . . . . . . . . . . . 32
128 5.19 Query schema for DAV:basicsearch . . . . . . . . . . . 33
129 5.19.1 DTD for DAV:basicsearch QSD . . . . . . . . . . . . 33
130 5.19.2 DAV:propdesc Element . . . . . . . . . . . . . . . 34
131 5.19.2.1 DAV:any-other-property . . . . . . . . . . . . 34
132 5.19.3 The DAV:datatype Property Description . . . . . . . 34
133 5.19.4 The DAV:searchable Property Description . . . . . . 35
134 5.19.5 The DAV:selectable Property Description . . . . . . 35
135 5.19.6 The DAV:sortable Property Description . . . . . . . 36
136 5.19.7 The DAV:casesensitive Property Description . . . . 36
137 5.19.8 The DAV:operators XML Element . . . . . . . . . . . 36
138 5.19.9 Example of Query Schema for DAV:basicsearch . . . . 37
139 6 Internationalization Considerations . . . . . . . . . . . . 39
140 7 Security Considerations . . . . . . . . . . . . . . . . . . 40
141 8 Scalability . . . . . . . . . . . . . . . . . . . . . . . . 41
142 9 Authentication . . . . . . . . . . . . . . . . . . . . . . . 42
143 10 IANA Considerations . . . . . . . . . . . . . . . . . . . . 43
144 11 Copyright . . . . . . . . . . . . . . . . . . . . . . . . . 44
145 12 Intellectual Property . . . . . . . . . . . . . . . . . . . 45
146 Normative References . . . . . . . . . . . . . . . . . . . . . 46
147 Informative References . . . . . . . . . . . . . . . . . . . . 46
148 Author's Addresses . . . . . . . . . . . . . . . . . . . . . . 47
149 A Three-Valued Logic in DAV:basicsearch . . . . . . . . . . . 48
150 B Change Log . . . . . . . . . . . . . . . . . . . . . . . . . 50
151 B.1 From draft-davis-dasl-protocol-xxx . . . . . . . . . . . 50
152 B.2 since start of draft-reschke-webdav-search . . . . . . . 51
153 B.3 since draft-reschke-webdav-search-00 . . . . . . . . . . 53
154 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
156 .
158 1 Introduction
160 1.1 DASL
162 This document defines WebDAV SEARCH, an application of HTTP/1.1
163 forming a lightweight search protocol to transport queries and result
164 sets and allows clients to make use of server-side search facilities.
165 It is based on the expired draft for WebDAV DASL [DASL]. [DASLREQ]
166 describes the motivation for DASL.
168 DASL will minimize the complexity of clients so as to facilitate
169 widespread deployment of applications capable of utilizing the DASL
170 search mechanisms.
172 DASL consists of:
174 o the SEARCH method,
176 o the DASL response header,
178 o the DAV:searchrequest XML element,
180 o the DAV:queryschema property,
182 o the DAV:basicsearch XML element and query grammar, and
184 o the DAV:basicsearchschema XML element.
186 For WebDAV-compliant servers, it also defines a new live property
187 DAV:supported-query-grammar-set.
189 1.2 Relationship to DAV
191 DASL relies on the resource and property model defined by [RFC2518].
192 DASL does not alter this model. Instead, DASL allows clients to
193 access DAV-modeled resources through server-side search.
195 1.3 Terms
197 This draft uses the terms defined in [RFC2616], [RFC2518], and
198 [DASLREQ].
200 .
202 1.4 Notational Conventions
204 The augmented BNF used by this document to describe protocol elements
205 is exactly the same as the one described in Section 2.1 of [RFC2616].
206 Because this augmented BNF uses the basic production rules provided
207 in Section 2.2 of [RFC2616], those rules apply to this document as
208 well.
210 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT"
211 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
212 document are to be interpreted as described in [RFC2119].
214 When an XML element type in the "DAV:" namespace is referenced in
215 this document outside of the context of an XML fragment, the string
216 "DAV:" will be prefixed to the element type.
218 Note that this draft currently defines elements and properties in the
219 WebDAV namespace "DAV:", which it shouldn't do as it isn't a work
220 item of the WebDAV working group. The reason for this is the desire
221 for some kind of backward compatibility to the expired DASL drafts
222 and the assumption that the draft may become an official RFC
223 submission of the WebDAV working group at a later point of time.
225 Similarily, when an XML element type in the namespace
226 "http://www.w3.org/2001/XMLSchema" is referenced in this document
227 outside of the context of an XML fragment, the string "xs:" will be
228 prefixed to the element type.
230 1.5 An Overview of DASL at Work
232 One can express the basic usage of DASL in the following steps:
234 o The client constructs a query using the DAV:basicsearch grammar.
236 o The client invokes the SEARCH method on a resource that will
237 perform the search (the search arbiter) and includes a text/xml or
238 application/xml request entity that contains the query.
240 o The search arbiter performs the query.
242 o The search arbiter sends the results of the query back to the
243 client in the response. The server MUST send an entity that
244 matches the [RFC2518] PROPFIND response.
246 .
248 2 The SEARCH Method
250 2.1 Overview
252 The client invokes the SEARCH method to initiate a server-side
253 search. The body of the request defines the query. The server MUST
254 emit an entity matching the [RFC2518] PROPFIND response.
256 The SEARCH method plays the role of transport mechanism for the query
257 and the result set. It does not define the semantics of the query.
258 The type of the query defines the semantics.
260 2.2 The Request
262 The client invokes the SEARCH method on the resource named by the
263 Request-URI.
265 2.2.1 The Request-URI
267 The Request-URI identifies the search arbiter. Any HTTP resource may
268 function as search arbiter. It is not a new type of resource (in the
269 sense of DAV:resourcetype as defined in [RFC2518]), nor does it have
270 to be a WebDAV-compliant resource.
272 The SEARCH method defines no relationship between the arbiter and the
273 scope of the search, rather the particular query grammar used in the
274 query defines the relationship. For example, the FOO query grammar
275 may force the request-URI to correspond exactly to the search scope.
277 2.2.2 The Request Body
279 The server MUST process a text/xml or application/xml request body,
280 and MAY process request bodies in other formats. See [RFC3023] for
281 guidance on packaging XML in requests.
283 If the client sends a text/xml or application/xml body, it MUST
284 include the DAV:searchrequest XML element. The DAV:searchrequest XML
285 element identifies the query grammar, defines the criteria, the
286 result record, and any other details needed to perform the search.
288 .
290 2.3 The DAV:searchrequest XML Element
292
294 The DAV:searchrequest XML element contains a single XML element that
295 defines the query. The name of the query element defines the type of
296 the query. The value of that element defines the query itself.
298 2.4 The Successful 207 (Multistatus) Response
300 If the server returns 207 (Multistatus), then the search proceeded
301 successfully and the response MUST match that of a PROPFIND. The
302 results of this method SHOULD NOT be cached.
304 There MUST be one DAV:response for each resource that matched the
305 search criteria. For each such response, the DAV:href element
306 contains the URI of the resource, and the response MUST include a
307 DAV:propstat element.
309 In addition, the server MAY include DAV:response items in the reply
310 where the DAV:href element contains a URI that is not a matching
311 resource, e.g. that of a scope or the query arbiter. Each such
312 response item MUST NOT contain a DAV:propstat element, and MUST
313 contain a DAV:status element (unless no property was selected).
315 2.4.1 Extending the PROPFIND Response
317 A response MAY include more information than PROPFIND defines so long
318 as the extra information does not invalidate the PROPFIND response.
319 Query grammars SHOULD define how the response matches the PROPFIND
320 response.
322 2.4.2 Example: A Simple Request and Response
324 This example demonstrates the request and response framework. The
325 following XML document shows a simple (hypothetical) natural language
326 query. The name of the query element is natural-language-query in the
327 XML namespace "http://example.com/foo". The actual query is "Find the
328 locations of good Thai restaurants in Los Angeles". For this
329 hypothetical query, the arbiter returns two properties for each
331 .
333 selected resource.
335 >> Request:
337 SEARCH / HTTP/1.1
338 Host: ryu.com
339 Content-Type: application/xml
340 Content-Length: xxx
342
343
344
345 Find the locations of good Thai restaurants in Los Angeles
346
347
349 >> Response:
351 HTTP/1.1 207 Multi-Status
352 Content-Type: text/xml; charset="utf-8"
353 Content-Length: xxx
355
356
357
358 http://siamiam.com/
359
360
361 259 W. Hollywood
362 4
363
364
365
366
368 2.4.3 Example: Result Set Truncation
370 A server MAY limit the number of resources in a reply, for example to
371 limit the amount of resources expended in processing a query. If it
372 does so, the reply MUST use status code 207, return a DAV:multistatus
373 response body and indicate a status of 507 (Insufficient Storage) for
375 .
377 the search arbiter URI. It SHOULD include the partial results.
379 When a result set is truncated, there may be many more resources that
380 satisfy the search criteria but that were not examined.
382 If partial results are included and the client requested an ordered
383 result set in the original request, then any partial results that are
384 returned MUST be ordered as the client directed.
386 Note that the partial results returned MAY be any subset of the
387 result set that would have satisfied the original query.
389 >> Request:
391 SEARCH / HTTP/1.1
392 Host: gdr.com
393 Content-Type: text/xml; charset="utf-8"
394 Content-Length: xxx
396 ... the query goes here ...
398 >> Response:
400 HTTP/1.1 207 Multistatus
401 Content-Type: text/xml; charset="utf-8"
402 Content-Length: xxx
404
405
406
407 http://www.gdr.com/sounds/unbrokenchain.au
408
409
410 HTTP/1.1 200 OK
411
412
413
414 http://tech.mit.edu/archive96/photos/Lesh1.jpg
415
416
417 HTTP/1.1 200 OK
418
419
420
422 .
424 http://gdr.com
425 HTTP/1.1 507 Insufficient Storage
426
427 Only first two matching records were returned
428
429
430
432 2.5 Unsuccessful Responses
434 If an error occurred that prevented execution of the query, the
435 server MUST indicate the failure with the appropriate status code and
436 SHOULD include a DAV:multistatus element to point out errors
437 associated with scopes.
439 400 Bad Request. The query could not be executed. The request may be
440 malformed (not valid XML for example). Additionally, this can be used
441 for invalid scopes and search redirections.
443 422 Unprocessable entity. The query could not be executed. If a
444 application/xml or text/xml request entity was provided, then it may
445 have been well-formed but may have contained an unsupported or
446 unimplemented query operator.
448 2.6 Invalid Scopes
450 2.6.1 Indicating an Invalid Scope
452 A client may submit a scope that the arbiter may be unable to query.
453 The inability to query may be due to network failure, administrative
454 policy, security, etc. This raises the condition described as an
455 "invalid scope".
457 To indicate an invalid scope, the server MUST respond with a 400 (Bad
458 Request).
460 The response includes a body with a DAV:multistatus element. Each
461 DAV:response in the DAV:multistatus identifies a scope. To indicate
462 that this scope is the source of the error, the server MUST include
463 the DAV:scopeerror element.
465 .
467 2.6.2 Example of an Invalid Scope
469 >> Response:
471 HTTP/1.1 400 Bad-Request
472 Content-Type: text/xml; charset="utf-8"
473 Content-Length: xxx
475
477
478
479 http://www.foo.com/X
480 HTTP/1.1 404 Object Not Found
481
482
483
485 .
487 3 Discovery of Supported Query Grammars
489 Servers MUST support discovery of the query grammars supported by a
490 search arbiter resource.
492 Clients can determine which query grammars are supported by an
493 arbiter by invoking OPTIONS on the search arbiter. If the resource
494 supports SEARCH, then the DASL response header will appear in the
495 response. The DASL response header lists the supported grammars.
497 Servers supporting the WebDAV extensions [RFC3253] and/or [ACL] MUST
498 also
500 o report SEARCH in the live property DAV:supported-method-set for
501 all search arbiter resources and
503 o support the live property DAV:supported-query-grammar-set as
504 defined in Section del-13.3.
506 3.1 The OPTIONS Method
508 The OPTIONS method allows the client to discover if a resource
509 supports the SEARCH method and to determine the list of search
510 grammars supported for that resource.
512 The client issues the OPTIONS method against a resource named by the
513 Request-URI. This is a normal invocation of OPTIONS defined in
514 [RFC2616].
516 If a resource supports the SEARCH method, then the server MUST list
517 SEARCH in the OPTIONS response as defined by [RFC2616].
519 DASL servers MUST include the DASL header in the OPTIONS response.
520 This header identifies the search grammars supported by that
521 resource.
523 3.2 The DASL Response Header
525 >> Response:
527 DASLHeader = "DASL" ":" Coded-URL-List
528 Coded-URL-List : Coded-URL [ "," Coded-URL-List ]
529 Coded-URL ; defined in section 9.4 of [RFC2518]
531 .
533 The DASL response header indicates server support for a query grammar
534 in the OPTIONS method. The value is a URI that indicates the type of
535 grammar. Note that although the URI can be used to identify each
536 supported search grammar, there is not necessarily a direct
537 relationship between the URI and the XML element name that can be
538 used in XML based SEARCH requests (the element name itself is
539 identified by it's namespace name (a URI reference) and the element's
540 local name).
542 This header MAY be repeated.
544 For example:
546 DASL:
547 DASL:
548 DASL:
549 DASL:
551 3.3 DAV:supported-query-grammar-set (protected)
553 This WebDAV property is required for any server supporting either
554 [RFC3253] and/or [ACL] and identifies the XML based query grammars
555 that are supported by the search arbiter resource.
557
559
561
563 ANY value: a query grammar element type
565 3.4 Example: Grammar Discovery
567 This example shows that the server supports search on the /somefolder
568 resource with the query grammars: DAV:basicsearch,
569 http://foo.bar.com/syntax1 and http://akuma.com/syntax2. Note that
570 every server MUST support DAV:basicsearch.
572 .
574 >> Request:
576 OPTIONS /somefolder HTTP/1.1
577 Host: ryu.com
579 >> Response:
581 HTTP/1.1 200 OK
582 Date: Tue, 20 Jan 1998 20:52:29 GMT
583 Allow: OPTIONS, GET, HEAD, POST, PUT, DELETE, TRACE, COPY, MOVE,
584 MKCOL, PROPFIND, PROPPATCH, LOCK, UNLOCK, SEARCH
585 DASL:
586 DASL:
587 DASL:
589 This example shows the equivalent taking advantage of a server's
590 support for DAV:supported-method-set and DAV:supported-query-grammar-
591 set.
593 >> Request:
595 PROPFIND /somefolder HTTP/1.1
596 Host: ryu.com
597 Depth: 0
598 Content-Type: text/xml; charset="utf-8"
599 Content-Length: xxx
601
602
603
604
605
606
607
609 >> Response:
611 HTTP/1.1 207 Multi-Status
612 Content-Type: text/xml; charset="utf-8"
614 .
616 Content-Length: xxx
618
619
620
621 http://ryu.com/somefolder
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653 HTTP/1.1 200 OK
654
655
656
658 Note that the query grammar element names marshalled as part of the
659 DAV:supported-query-grammar-set can be directly used as element names
660 in an XML based query.
662 .
664 4 Query Schema Discovery: QSD
666 Servers MAY support the discovery of the schema for a query grammar.
668 The DASL response header and the DAV:supported-query-grammar-set
669 property provide means for clients to discover the set of query
670 grammars supported by a resource. This alone is not sufficient
671 information for a client to generate a query. For example, the
672 DAV:basicsearch grammar defines a set of queries consisting of a set
673 of operators applied to a set of properties and values, but the
674 grammar itself does not specify which properties may be used in the
675 query. QSD for the DAV:basicsearch grammar allows a client to
676 discover the set of properties that are searchable, selectable, and
677 sortable. Moreover, although the DAV:basicsearch grammar defines a
678 minimal set of operators, it is possible that a resource might
679 support additional operators in a query. For example, a resource
680 might support a optional operator that can be used to express
681 content-based queries in a proprietary syntax. QSD allows a client to
682 discover these operators and their syntax. The set of discoverable
683 quantities will differ from grammar to grammar, but each grammar can
684 define a means for a client to discover what can be discovered.
686 In general, the schema for a given query grammar depends on both the
687 resource (the arbiter) and the scope. A given resource might have
688 access to one set of properties for one potential scope, and another
689 set for a different scope. For example, consider a server able to
690 search two distinct collections, one holding cooking recipes, the
691 other design documents for nuclear weapons. While both collections
692 might support properties such as author, title, and date, the first
693 might also define properties such as calories and preparation time,
694 while the second defined properties such as yield and applicable
695 patents. Two distinct arbiters indexing the same collection might
696 also have access to different properties. For example, the recipe
697 collection mentioned above might also indexed by a value-added server
698 that also stored the names of chefs who had tested the recipe. Note
699 also that the available query schema might also depend on other
700 factors, such as the identity of the principal conducting the search,
701 but these factors are not exposed in this protocol.
703 4.1 Additional SEARCH semantics
705 Each query grammar supported by DASL defines its own syntax for
706 expressing the possible query schema. A client retrieves the schema
707 for a given query grammar on an arbiter resource with a given scope
708 by invoking the SEARCH method on that arbiter with that grammar and
709 scope and with a root element of DAV:query-schema-discovery rather
710 than DAV:searchrequest.
712 .
714 Marshalling:
716 The requst body MUST be DAV:query-schema-discovery element.
718
719 ANY value: XML element defining a valid query
721 The response body takes the form of a RFC2518 DAV:multistatus
722 element, where DAV:response is extended to hold the returned query
723 grammar inside a DAV:query-schema container element.
725
727
729 The content of this container is an XML element whose name and syntax
730 depend upon the grammar, and whose value may (and likely will) vary
731 depending upon the grammar, arbiter, and scope.
733 4.1.1 Example of query schema discovery
735 In this example, the arbiter is recipes.com, the grammar is
736 DAV:basicsearch, the scope is also recipes.com.
738 >> Request:
740 SEARCH / HTTP/1.1
741 Host: recipes.com
742 Content-Type: application/xml
743 Content-Length: xxx
745
746
747
748
750 .
752
753 http://recipes.com
754 infinity
755
756
757
758
760 >> Response:
762 HTTP/1.1 207 Multistatus
763 Content-Type: application/xml
764 Content-Length: xxx
766
767
768
769 http://recipes.com
770 HTTP/1.1 200 OK
771
772
773 (See section "Query schema for DAV:basicsearch" for
774 the actual contents)
775
776
777
778
780 The query schema for DAV:basicsearch is defined in Section 5.19.
782 .
784 5 The DAV:basicsearch Grammar
786 5.1 Introduction
788 DAV:basicsearch uses an extensible XML syntax that allows clients to
789 express search requests that are generally useful for WebDAV
790 scenarios. DASL-extended servers MUST accept this grammar, and MAY
791 accept others grammars.
793 DAV:basicsearch has several components:
795 o DAV:select provides the result record definition.
797 o DAV:from defines the scope.
799 o DAV:where defines the criteria.
801 o DAV:orderby defines the sort order of the result set.
803 o DAV:limit provides constraints on the query as a whole.
805 5.2 The DAV:basicsearch DTD
807
809
811
812
814
815
816
817
818
820
823
825 .
827
829
831
833
834
836
837
839
840
842
843
845
846
848
850
851
852
854
856
857
860
862
864
865
867 5.2.1 Example Query
869 This query retrieves the content length values for all resources
870 located under the server's "/container1/" URI namespace whose length
872 .
874 exceeds 10000.
876
877
878
879
880
881
882
883 /container1/
884 infinity
885
886
887
888
889
890 10000
891
892
893
894
895
896
897
898
899
900
902 5.3 DAV:select
904 DAV:select defines the result record, which is a set of properties
905 and values. This document defines two possible values: DAV:allprop
906 and DAV:prop, both defined in [RFC2518].
908 If the value is DAV:allprop, the result record for a given resource
909 includes all the properties for that resource.
911 If the value is DAV:prop, then the result record for a given resource
912 includes only those properties named by the DAV:prop element. Each
913 property named by the DAV:prop element must be referenced in the
914 Multistatus response.
916 .
918 The rules governing the status codes for each property match those of
919 the PROPFIND method defined in [RFC2518].
921 5.4 DAV:from
923 DAV:from defines the query scope. This contains exactly one DAV:scope
924 element. The scope element contains mandatory DAV:href and DAV:depth
925 elements.
927 DAV:href indicates the URI for a collection to use as a scope.
929 When the scope is a collection, if DAV:depth is "0", the search
930 includes only the collection. When it is "1", the search includes the
931 (toplevel) members of the collection. When it is "infinity", the
932 search includes all recursive members of the collection.
934 5.4.1 Relationship to the Request-URI
936 If the DAV:scope element is an absolute URI, the scope is exactly
937 that URI.
939 If the DAV:scope element is is an absolute URI reference, the scope
940 is taken to be relative to the request-URI.
942 5.4.2 Scope
944 A Scope can be an arbitrary URI.
946 Servers, of course, may support only particular scopes. This may
947 include limitations for particular schemes such as "http:" or "ftp:"
948 or certain URI namespaces.
950 If a scope is given that is not supported the server MUST respond
951 with a 400 status code that includes a Multistatus error. A scope in
952 the query appears as a resource in the response and must include an
953 appropriate status code indicating its validity with respect to the
954 search arbiter.
956 Example:
958 HTTP/1.1 400 Bad Request
959 Content-Type: text/xml; charset="utf-8"
960 Content-Length: xxx
962 .
964
965
966
967 http://www.foo.com/scope1
968 HTTP/1.1 502 Bad Gateway
969
970
972 This example shows the response if there is a scope error. The
973 response provides a Multistatus with a status for the scope. In this
974 case, the scope cannot be reached because the server cannot search
975 another server (502).
977 5.5 DAV:where
979 DAV:where element defines the search condition for inclusion of
980 resources in the result set. The value of this element is an XML
981 element that defines a search operator that evaluates to one of the
982 Boolean truth values TRUE, FALSE, or UNKNOWN. The search operator
983 contained by DAV:where may itself contain and evaluate additional
984 search operators as operands, which in turn may contain and evaluate
985 additional search operators as operands, etc. recursively.
987 5.5.1 Use of Three-Valued Logic in Queries
989 Each operator defined for use in the where clause that returns a
990 Boolean value MUST evaluate to TRUE, FALSE, or UNKNOWN. The resource
991 under scan is included as a member of the result set if and only if
992 the search condition evaluates to TRUE.
994 Consult Appendix A for details on the application of three-valued
995 logic in query expressions.
997 5.5.2 Handling Optional operators
999 If a query contains an operator that is not supported by the server,
1000 then the server MUST respond with a 422 (Unprocessable Entity) status
1001 code.
1003 .
1005 5.5.3 Treatment of NULL Values
1007 If a PROPFIND for a property value would yield a 404 or 403 response
1008 for that property, then that property is considered NULL.
1010 NULL values are "less than" all other values in comparisons.
1012 Empty strings (zero length strings) are not NULL values. An empty
1013 string is "less than" a string with length greater than zero.
1015 The DAV:isdefined operator is defined to test if the value of a
1016 property is NULL.
1018 5.5.4 Treatment of properties with mixed/element content
1020 Comparisons of properties that do not have simple types (text-only
1021 content) is out-of-scope for DAV:basicsearch. For querying the
1022 DAV:resourcetype property, see Section 5.11.
1024 5.5.5 Example: Testing for Equality
1026 The example shows a single operator (DAV:eq) applied in the criteria.
1028
1029
1030
1031
1032
1033 100
1034
1035
1037 5.5.6 Example: Relative Comparisons
1039 The example shows a more complex operation involving several
1040 operators (DAV:and, DAV:eq, DAV:gt) applied in the criteria. This
1041 DAV:where expression matches those resources that are "image/gifs"
1042 over 4K in size.
1044 .
1046
1047
1048
1049
1050
1051
1052 image/gif
1053
1054
1055
1056
1057
1058 4096
1059
1060
1061
1063 5.6 DAV:orderby
1065 The DAV:orderby element specifies the ordering of the result set. It
1066 contains one or more DAV:order elements, each of which specifies a
1067 comparison between two items in the result set. Informally, a
1068 comparison specifies a test that determines whether one resource
1069 appears before another in the result set. Comparisons are applied in
1070 the order they occur in the DAV:orderby element, earlier comparisons
1071 being more significant.
1073 The comparisons defined here use only a single property from each
1074 resource, compared using the same ordering as the DAV:lt operator
1075 (ascending) or DAV:gt operator (descending). If neither direction is
1076 specified, the default is DAV:ascending.
1078 In the context of the DAV:orderby element, null values are considered
1079 to collate before any actual (i.e., non null) value, including
1080 strings of zero length ( as in [SQL99]).
1082 5.6.1 Comparing Natural Language Strings.
1084 Comparisons on strings take into account the language defined for
1085 that property. Clients MAY specify the language using the xml:lang
1086 attribute. If no language is specified either by the client or
1087 defined for that property by the server or if a comparison is
1088 performed on strings of two different languages, the results are
1089 undefined.
1091 .
1093 The "casesensitive" attribute may be used to indicate case-
1094 sensitivity for comparisons. Servers SHOULD do caseless matching as
1095 defined in [CaseMap].
1097 5.6.2 Example of Sorting
1099 This sort orders first by last name of the author, and then by size,
1100 in descending order, so that the largest works appear first.
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1113 5.7 Boolean Operators: DAV:and, DAV:or, and DAV:not
1115 The DAV:and operator performs a logical AND operation on the
1116 expressions it contains.
1118 The DAV:or operator performs a logical OR operation on the values it
1119 contains.
1121 The DAV:not operator performs a logical NOT operation on the values
1122 it contains.
1124 5.8 DAV:eq
1126 The DAV:eq operator provides simple equality matching on property
1127 values.
1129 The "casesensitive" attribute may be used with this element.
1131 .
1133 5.9 DAV:lt, DAV:lte, DAV:gt, DAV:gte
1135 The DAV:lt, DAV:lte, DAV:gt, and DAV:gte operators provide
1136 comparisons on property values, using less-than, less-than or equal,
1137 greater-than, and greater-than or equal respectively. The
1138 "casesensitive" attribute may be used with these elements.
1140 5.10 DAV:literal
1142 DAV:literal allows literal values to be placed in an expression.
1144 White space in literal values is significant in comparisons. For
1145 consistency with [RFC2518], clients SHOULD NOT specify the attribute
1146 "xml:space" (section 2.10 of [XML]) to override this behaviour.
1148 5.11 DAV:is-collection
1150 The DAV:is-collection operator allows clients to determine whether a
1151 resource is a collection (that is, whether it's DAV:resourcetype
1152 element contains the element DAV:collection).
1154 Rationale: This operator is provided in lieu of defining generic
1155 structure queries, which would suffice for this and for many more
1156 powerful queries, but seems inappropriate to standardize at this
1157 time.
1159 5.11.1 Example of DAV:is-collection
1161 This example shows a search criterion that picks out all and only the
1162 resources in the scope that are collections.
1164
1165
1166
1168 5.12 DAV:isdefined
1170 The DAV:isdefined operator allows clients to determine whether a
1171 property is defined on a resource. The meaning of "defined on a
1173 .
1175 resource" is found in Section 5.5.3.
1177 Example:
1179
1180
1181
1183 The DAV:isdefined operator is optional.
1185 5.13 DAV:like
1187 The DAV:like is an optional operator intended to give simple
1188 wildcard-based pattern matching ability to clients.
1190 The operator takes two arguments.
1192 The first argument is a DAV:prop element identifying a single
1193 property to evaluate.
1195 The second argument is a DAV:literal element that gives the pattern
1196 matching string.
1198 5.13.1 Syntax for the Literal Pattern
1200 Pattern := [wildcard] 0*( text [wildcard] )
1201 wildcard := exactlyone | zeroormore
1202 text := 1*( | escapesequence )
1203 exactlyone : = "?"
1204 zeroormore := "%"
1205 escapechar := "\"
1206 escapesequence := "\" ( exactlyone | zeroormore | escapechar )
1207 character: see section 2.2 of [XML]
1209 The value for the literal is composed of wildcards separated by
1210 segments of text. Wildcards may begin or end the literal. Wildcards
1212 .
1214 may not be adjacent.
1216 The "?" wildcard matches exactly one character.
1218 The "%" wildcard matches zero or more characters
1220 The "
1222 5.13.2 Example of DAV:like
1224 This example shows how a client might use DAV:like to identify those
1225 resources whose content type was a subtype of image.
1227
1228
1229
1230 image%
1231
1232
1234 5.14 DAV:contains
1236 The DAV:contains operator is an optional operator that provides
1237 content-based search capability. This operator implicitly searches
1238 against the text content of a resource, not against content of
1239 properties. The DAV:contains operator is intentionally not overly
1240 constrained, in order to allow the server to do the best job it can
1241 in performing the search.
1243 The DAV:contains operator evaluates to a Boolean value. It evaluates
1244 to TRUE if the content of the resource satisfies the search.
1245 Otherwise, It evaluates to FALSE.
1247 Within the DAV:contains XML element, the client provides a phrase: a
1248 single word or whitespace delimited sequence of words. Servers MAY
1249 ignore punctuation in a phrase. Case-sensitivity is left to the
1250 server.
1252 The following things may or may not be done as part of the search:
1253 Phonetic methods such as "soundex" may or may not be used. Word
1254 stemming may or may not be performed. Thesaurus expansion of words
1256 .
1258 may or may not be done. Right or left truncation may or may not be
1259 performed. The search may be case insensitive or case sensitive. The
1260 word or words may or may not be interpreted as names. Multiple words
1261 may or may not be required to be adjacent or "near" each other.
1262 Multiple words may or may not be required to occur in the same order.
1263 Multiple words may or may not be treated as a phrase. The search may
1264 or may not be interpreted as a request to find documents "similar" to
1265 the string operand.
1267 The DAV:score property is intended to be useful to rank documents
1268 satisfying the DAV:contains operator.
1270 5.14.1 Examples
1272 The example below shows a search for the phrase "Peter Forsberg".
1274 Depending on its support for content-based searching, a server MAY
1275 treat this as a search for documents that contain the words "Peter"
1276 and "Forsberg".
1278
1279 Peter Forsberg
1280
1282 The example below shows a search for resources that contain "Peter"
1283 and "Forsberg".
1285
1286
1287 Peter
1288 Forsberg
1289
1290
1292 .
1294 5.15 The DAV:limit XML Element
1296
1298 The DAV:limit XML element contains requested limits from the client
1299 to limit the size of the reply or amount of effort expended by the
1300 server.
1302 5.16 The DAV:nresults XML Element
1304 ;only digits
1306 The DAV:nresults XML element contains a requested maximum number of
1307 records to be returned in a reply. The server MAY disregard this
1308 limit. The value of this element is an integer.
1310 5.17 The "casesensitive" XML attribute
1312 The "casesensitive" attribute allows clients to specify case-
1313 sensitive or case-insensitive behavior for DAV:basicsearch operators.
1315 The possible values for "casesensitive" are "1" or "0". The "1" value
1316 indicates case-sensitivity. The "0" value indicates case-
1317 insensitivity. The default value is server-specified. Case-
1318 insensitivity SHOULD implemented using caseless matching as defined
1319 in [CaseMap].
1321 Support for the "casesensitive" attribute is optional. A server
1322 should respond with a status of 422 if it is used but cannot be
1323 supported.
1325 5.18 The DAV:score Property
1327 .
1329
1331 The DAV:score XML element is a synthetic property whose value is
1332 defined only in the context of a query result where the server
1333 computes a score, e.g. based on relevance. It may be used in
1334 DAV:select or DAV:orderby elements. Servers SHOULD support this
1335 property. The value is a string representing the score, an integer
1336 from zero to 10000 inclusive, where a higher value indicates a higher
1337 score (e.g. more relevant).
1339 Clients should note that, in general, it is not meaningful to compare
1340 the numeric values of scores from two different query results unless
1341 both were executed by the same underlying search system on the same
1342 collection of resources.
1344 5.19 Query schema for DAV:basicsearch
1346 The DAV:basicsearch grammar defines a search criteria that is a
1347 Boolean-valued expression, and allows for an arbitrary set of
1348 properties to be included in the result record. The result set may be
1349 sorted on a set of property values. Accordingly the DTD for schema
1350 discovery for this grammar allows the server to express:
1352 1. the set of properties that may be either searched, returned, or
1353 used to sort, and a hint about the data type of such properties
1355 2. the set of optional operators defined by the resource.
1357 5.19.1 DTD for DAV:basicsearch QSD
1359
1361
1362
1363
1366
1367
1369 .
1371
1372
1374 The DAV:properties element holds a list of descriptions of
1375 properties.
1377 The DAV:operators element describes the optional operators that may
1378 be used in a DAV:where element.
1380 5.19.2 DAV:propdesc Element
1382 Each instance of a DAV:propdesc element describes the property or
1383 properties in the DAV:prop element it contains. All subsequent
1384 elements are descriptions that apply to those properties. All
1385 descriptions are optional and may appear in any order. Servers SHOULD
1386 support all the descriptions defined here, and MAY define others.
1388 DASL defines five descriptions. The first, DAV:datatype, provides a
1389 hint about the type of the property value, and may be useful to a
1390 user interface prompting for a value. The remaining four
1391 (DAV:searchable, DAV:selectable, DAV:sortable, and DAV:casesensitive)
1392 identify portions of the query (DAV:where, DAV:select, and
1393 DAV:orderby, respectively). If a property has a description for a
1394 section, then the server MUST allow the property to be used in that
1395 section. These descriptions are optional. If a property does not have
1396 such a description, or is not described at all, then the server MAY
1397 still allow the property to be used in the corresponding section.
1399 5.19.2.1 DAV:any-other-property
1401 This element can be used in place of DAV:prop to describe properties
1402 of WebDAV properties not mentioned in any other DAV:prop element. For
1403 instance, this can be used to indicate that all other properties are
1404 searchable and selectable without giving details about their types (a
1405 typical scenario for dead properties).
1407 5.19.3 The DAV:datatype Property Description
1409 The DAV:datatype element contains a single XML element that provides
1410 a hint about the domain of the property, which may be useful to a
1411 user interface prompting for a value to be used in a query. Datatypes
1412 are identified by an element name. Where appropriate, a server SHOULD
1413 use the simple datatypes defined in [XS2].
1415 .
1417
1419 Examples from [XS2], section 3:
1421 Qualified name Example
1423 xs:boolean true, false, 1, 0
1424 xs:string Foobar
1425 xs:dateTime 1994-11-05T08:15:5Z
1426 xs:float .314159265358979E+1
1427 xs:integer -259, 23
1429 If the data type of a property is not given, then the data type
1430 defaults to xs:string.
1432 5.19.4 The DAV:searchable Property Description
1434
1436 If this element is present, then the server MUST allow this property
1437 to appear within a DAV:where element where an operator allows a
1438 property. Allowing a search does not mean that the property is
1439 guaranteed to be defined on every resource in the scope, it only
1440 indicates the server's willingness to check.
1442 5.19.5 The DAV:selectable Property Description
1444
1446 .
1448 This element indicates that the property may appear in the DAV:select
1449 element.
1451 5.19.6 The DAV:sortable Property Description
1453 This element indicates that the property may appear in the
1454 DAV:orderby element.
1456
1458 5.19.7 The DAV:casesensitive Property Description
1460 This element only applies to properties whose data type is
1461 "xs:string" and derived data types as per the DAV:datatype property
1462 description. Its presence indicates that compares performed for
1463 searches, and the comparisons for ordering results on the string
1464 property will be case sensitive. (The default is case insensitive.)
1466
1468 5.19.8 The DAV:operators XML Element
1470 The DAV:operators element describes every optional operator supported
1471 in a query. (Mandatory operators are not listed since they are
1472 mandatory and permit no variation in syntax.). All optional operators
1473 that are supported MUST be listed in the DAV:operators element. The
1474 listing for an operator consists of the operator (as an empty
1475 element), followed by one element for each operand. The operand MUST
1476 be either DAV:operand-property or DAV:operand-literal, which indicate
1477 that the operand in the corresponding position is a property or a
1478 literal value, respectively. If an operator is polymorphic (allows
1479 more than one operand syntax) then each permitted syntax MUST be
1480 listed separately.
1482 .
1484
1485
1486
1487
1488
1490 5.19.9 Example of Query Schema for DAV:basicsearch
1492
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1523 .
1525 This response lists four properties. The datatype of the last three
1526 properties is not given, so it defaults to xs:string. All are
1527 selectable, and the first three may be searched. All but the last may
1528 be used in a sort. Of the optional DAV operators, DAV:isdefined and
1529 DAV:like are supported.
1531 Note: The schema discovery defined here does not provide for
1532 discovery of supported values of the "casesensitive" attribute. This
1533 may require that the reply also list the mandatory operators.
1535 .
1537 6 Internationalization Considerations
1539 Clients have the opportunity to tag properties when they are stored
1540 in a language. The server SHOULD read this language-tagging by
1541 examining the xml:lang attribute on any properties stored on a
1542 resource.
1544 The xml:lang attribute specifies a nationalized collation sequence
1545 when properties are compared.
1547 Comparisons when this attribute differs have undefined order.
1549 .
1551 7 Security Considerations
1553 This section is provided to detail issues concerning security
1554 implications of which DASL applications need to be aware. All of the
1555 security considerations of HTTP/1.1 also apply to DASL. In addition,
1556 this section will include security risks inherent in searching and
1557 retrieval of resource properties and content.
1559 A query must not allow one to retrieve information about values or
1560 existence of properties that one could not obtain via PROPFIND. (e.g.
1561 by use in DAV:orderby, or in expressions on properties.)
1563 A server should prepare for denial of service attacks. For example a
1564 client may issue a query for which the result set is expensive to
1565 calculate or transmit because many resources match or must be
1566 evaluated. 7.1 Implications of XML External Entities
1568 XML supports a facility known as "external entities", defined in
1569 section 4.2.2 of [XML], which instruct an XML processor to retrieve
1570 and perform an inline include of XML located at a particular URI. An
1571 external XML entity can be used to append or modify the document type
1572 declaration (DTD) associated with an XML document. An external XML
1573 entity can also be used to include XML within the content of an XML
1574 document. For non-validating XML, such as the XML used in this
1575 specification, including an external XML entity is not required by
1576 [XML]. However, [XML] does state that an XML processor may, at its
1577 discretion, include the external XML entity.
1579 External XML entities have no inherent trustworthiness and are
1580 subject to all the attacks that are endemic to any HTTP GET request.
1581 Furthermore, it is possible for an external XML entity to modify the
1582 DTD, and hence affect the final form of an XML document, in the worst
1583 case significantly modifying its semantics, or exposing the XML
1584 processor to the security risks discussed in [RFC3023]. Therefore,
1585 implementers must be aware that external XML entities should be
1586 treated as untrustworthy.
1588 There is also the scalability risk that would accompany a widely
1589 deployed application which made use of external XML entities. In this
1590 situation, it is possible that there would be significant numbers of
1591 requests for one external XML entity, potentially overloading any
1592 server which fields requests for the resource containing the external
1593 XML entity.
1595 .
1597 8 Scalability
1599 Query grammars are identified by URIs. Applications SHOULD not
1600 attempt to retrieve these URIs even if they appear to be retrievable
1601 (for example, those that begin with "http://")
1603 .
1605 9 Authentication
1607 Authentication mechanisms defined in WebDAV will also apply to DASL.
1609 .
1611 10 IANA Considerations
1613 This document uses the namespace defined by [RFC2518] for XML
1614 elements. All other IANA considerations mentioned in [RFC2518]are
1615 also applicable to DASL.
1617 .
1619 11 Copyright
1621 To be supplied.
1623 .
1625 12 Intellectual Property
1627 To be supplied.
1629 .
1631 Normative References
1633 [ACL] Clemm, G., Hopkins, A., Sedlar, E. and Whitehead, J.,
1634 "WebDAV Access Control Protocol", ID draft-ietf-webdav-
1635 acl-07, November 2001.
1637 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
1638 Requirement Levels", BCP 14, RFC 2119, March 1997.
1640 [RFC2518] Goland, Y., Whitehead, E., Faizi, A., Carter, S.R. and
1641 Jensen, D., "HTTP Extensions for Distributed Authoring --
1642 WEBDAV", RFC 2518, February 1999.
1644 [RFC2616] Fielding, R.T., Gettys, J., Mogul, J.C., Nielsen, H.F.,
1645 Masinter, L., Leach, P.J. and Berners-Lee, T., "Hypertext
1646 Transfer Protocol -- HTTP/1.1", RFC 2616, June 1999.
1648 [RFC3023] Makoto, M., St.Laurent, S. and Kohn, D., "XML Media
1649 Types", RFC 3023, January 2001.
1651 [RFC3253] Clemm, G., Amsden, J., Ellison, T., Kaler, C. and
1652 Whitehead, J., "Versioning Extensions to WebDAV", RFC
1653 3253, March 2002.
1655 [XML] Bray, T., Paoli, J., Sperberg-McQueen, C.M. and Maler, E.,
1656 "Extensible Markup Language (XML) 1.0 (2nd ed)", W3C REC-
1657 xml, October 2000.
1659 [XMLNS] Bray, T., Hollander, D. and Layman, A., "Namespaces in
1660 XML", W3C REC-xml-names, January 1999.
1662 [XS2] Biron, P. V., Malhotra, A. and World Wide Web Consortium,
1663 "XML Schema Part 2: Datatypes", W3C XS2, May 2001.
1665 Informative References
1667 [CaseMap] Davis, M., "Case Mappings", Unicode Techical Reports 21,
1668 February 2001.
1670 [DASL] Reddy, S., Lowry, D., Reddy, S., Henderson, R., Davis, J.
1671 and Babich, A., "DAV Searching & Locating", ID draft-dasl-
1672 protocol-00, July 1999.
1674 [DASLREQ] Davis, J., Reddy, S. and Slein, J., "Requirements for DAV
1675 Searching and Locating", ID draft-dasl-requirements-01,
1677 .
1679 February 1999.
1681 [SQL99] Milton, J., "Database Language SQL Part 2: Foundation
1682 (SQL/Foundation)", ISO ISO/IEC 9075-2:1999 (E), July 1999.
1684 Author's Addresses
1686 Julian F. Reschke
1687 greenbytes GmbH
1688 Salzmannstrasse 152
1689 Muenster, NW 48159
1690 Germany
1692 Phone: +49 251 2807760
1693 Fax: +49 251 2807761
1694 EMail: julian.reschke@greenbytes.de
1695 URI: http://greenbytes.de/tech/webdav/
1697 Surendra Reddy
1698 Oracle Corporation
1699 600 Oracle Parkway, M/S 6op3
1700 Redwoodshores, CA 94065
1702 Phone: +1 650 506 5441
1703 EMail: Surendra.Reddy@oracle.com
1705 Jim Davis
1706 Intelligent Markets
1707 410 Jessie Street 6th floor
1708 San Francisco, CA 94103
1710 EMail: jrd3@alum.mit.edu
1712 Alan Babich
1713 FileNET Corp.
1714 3565 Harbor Blvd.
1715 Costa Mesa, CA 92626
1717 Phone: +1 714 327 3403
1718 EMail: ababich@filenet.com
1720 .
1722 A Three-Valued Logic in DAV:basicsearch
1724 ANSI standard three valued logic is used when evaluating the search
1725 condition (as defined in the ANSI standard SQL specifications, for
1726 example in ANSI X3.135-1992, section 8.12, pp. 188-189, section 8.2,
1727 p. 169, General Rule 1)a), etc.).
1729 ANSI standard three valued logic is undoubtedly the most widely
1730 practiced method of dealing with the issues of properties in the
1731 search condition not having a value (e.g., being null or not defined)
1732 for the resource under scan, and with undefined expressions in the
1733 search condition (e.g., division by zero, etc.). Three valued logic
1734 works as follows.
1736 Undefined expressions are expressions for which the value of the
1737 expression is not defined. Undefined expressions are a completely
1738 separate concept >from the truth value UNKNOWN, which is, in fact,
1739 well defined. Property names and literal constants are considered
1740 expressions for purposes of this section. If a property in the
1741 current resource under scan has not been set to a value (either
1742 because the property is not defined for the current resource, or
1743 because it is null for the current resource), then the value of that
1744 property is undefined for the resource under scan. DASL 1.0 has no
1745 arithmetic division operator, but if it did, division by zero would
1746 be an undefined arithmetic expression.
1748 If any subpart of an arithmetic, string, or datetime subexpression is
1749 undefined, the whole arithmetic, string, or datetime subexpression is
1750 undefined.
1752 There are no manifest constants to explicitly represent undefined
1753 number, string, or datetime values.
1755 Since a Boolean value is ultimately returned by the search condition,
1756 arithmetic, string, and datetime expressions are always arguments to
1757 other operators. Examples of operators that convert arithmetic,
1758 string, and datetime expressions to Boolean values are the six
1759 relational operators ("greater than", "less than", "equals", etc.).
1760 If either or both operands of a relational operator have undefined
1761 values, then the relational operator evaluates to UNKNOWN. Otherwise,
1762 the relational operator evaluates to TRUE or FALSE, depending upon
1763 the outcome of the comparison.
1765 The Boolean operators DAV:and, DAV:or and DAV:not are evaluated
1766 according to the following rules:
1768 UNKNOWN and UNKNOWN = UNKNOWN
1770 .
1772 UNKNOWN or UNKKNOWN = UNKNOWN
1774 not UNKNOWN = UNKNOWN
1776 UNKNOWN and TRUE = UNKNOWN
1778 UNKNOWN and FALSE = FALSE
1780 UNKNOWN and UNKNOWN = UNKNOWN
1782 UNKNOWN or TRUE = TRUE
1784 UNKNOWN or FALSE = UNKNOWN
1786 UNKNOWN or UNKNOWN = UNKNOWN
1788 .
1790 B Change Log
1792 B.1 From draft-davis-dasl-protocol-xxx
1794 Feb 14, 1998 Initial Draft
1795 Feb 28, 1998 Referring to DASL as an extension to HTTP/1.1
1796 rather than DAV.
1797 Added new sections "Notational Conventions",
1798 "Protocol Model", "Security Considerations".
1799 Changed section 3 to "Elements of Protocol".
1800 Added some stuff to introduction.
1801 Added "result set" terminology.
1802 Added "IANA Considerations".
1803 Mar 9, 1998 Moved sub-headings of "Elements of Protocol" to
1804 first level and removed "Elements of Protocol"
1805 Heading.
1806 Added an sentence in introduction explaining that
1807 this is a "sketch" of a protocol.
1808 Mar 11, 1998 Added orderby, data typing, three valued logic,
1809 query schema property, and element definitions for
1810 schema for basicsearch.
1811 April 8, 1998 - made changes based on last week's DASL BOF.
1812 May 8, 1998 Removed most of DAV:searcherror; converted to
1813 DAV:searchredirect
1814 Altered DAV:basicsearch grammar to use avoid use
1815 of ANY in DTD
1816 June 17, 1998 -Added details on Query Schema Discovery
1817 -Shortened list of data types
1818 June 23, 1998 moved data types before change history
1819 rewrote the data types section
1820 removed the casesensitive element and replace with
1821 the casesensitive attribute
1822 added the casesensitive attribute to the DTD for
1823 all operations that might work on a string
1824 Jul 20, 1998 A series of changes. See Author's meeting minutes
1825 for details.
1826 July 28, 1998 Changes as per author's meeting. QSD uses SEARCH,
1827 not PROPFIND.
1828 Moved text around to keep concepts nearby.
1829 Boolean literals are 1 and 0, not T and F.
1830 contains changed to contentspassthrough.
1831 Renamed rank to score.
1832 July 28, 1998 Added Dale Lowry as Author
1833 September 4, 1998 Added 422 as response when query lists
1834 unimplemented operators.
1836 .
1838 DAV:literal declares a default value for
1839 xml:space, 'preserve' (see XML spec, section 2.10)
1840 moved to new XML namespace syntax
1841 September 22, 1998 Changed "simplesearch" to "basicsearch"
1842 Changed isnull to isdefined
1843 Defined NULLness as having a 404 or 403 response
1844 used ENTITY syntax in DTD
1845 Added redirect
1846 October 9, 1998 Fixed a series of typographical and formatting
1847 errors.
1848 Modified the section of three-valued logic to use
1849 a table rather than a text description of the role
1850 of UNKNOWN in expressions.
1851 November 2, 1998 Added the DAV:contains operator.
1852 Removed the DAV:contentpassthrough operator.
1853 November 18, 1998 Various author comments for submission
1854 June 3, 1999 Cosmetic and minor editorial changes only. Fix
1855 nits reported by Jim Whitehead in email of April
1856 26, 1999. Converted to HTML from Word 97,
1857 manually.
1858 April 20, 2000 Removed redirection feature, since 301/302
1859 suffices. Removed Query Schema Discovery (former
1860 chapter 4). Everyone agrees this is a useful
1861 feature, but it is apparently too difficult to
1862 define at this time, and it is not essential for
1863 DASL.
1865 B.2 since start of draft-reschke-webdav-search
1867 October 09, 2001 Added Julian Reschke as author.
1868 Chapter about QSD re-added.
1869 Formatted into RFC2629-compliant XML document.
1870 Added first comments.
1871 ID version number kicked up to draft-dasl-
1872 protocol-03.
1873 October 17, 2001 Updated address information for Jim Davis.
1874 Added issue of datatype vocabularies.
1875 Updated issue descriptions for grammar discovery,
1876 added issues on query schema DTD.
1877 Fixed typos in XML examples.
1878 December 17, 2001 Re-introduced split between normative and non-
1879 normative references.
1881 .
1883 January 05, 2002 Version bumbed up to 04. Started work on resolving
1884 the issues identified in the previous version.
1885 January 14, 2002 Fixed some XML typos.
1886 January 22, 2002 Closed issues naming-of-elements. Fixed query
1887 search DTD and added option to discover properties
1888 of "other" (non-listed) properties.
1889 January 25, 2002 Changed into private submission and added reference
1890 to historic DASL draft. Marked reference to DASL
1891 requirements non-normative.
1892 Updated reference to latest deltav spec.
1893 January 29, 2002 Added feedback from and updated contact info for
1894 Alan Babich.
1895 Included open issues collected in
1896 http://www.webdav.org/dasl/protocol/issues.html.
1897 February 8, 2002 Made sure that all artwork fits into 72 characters
1898 wide text.
1899 February 18, 2002 Changed Insufficient storage handling
1900 (multistatus). Moved is-collection to operators and
1901 added to DTD. Made scope/depth mandatory.
1902 February 20, 2002 Updated reference to SQL99.
1903 February 28, 2002 "Non-normative References" -> "Informative
1904 References". Abstract updated. Consistently specify
1905 a charset when using text/xml (no change bars). Do
1906 not attempt to define PROPFIND's entity encoding
1907 (take out specific references to text/xml). Remove
1908 irrelevant headers (Connection:) from examples (no
1909 change bars). Added issue on querying based on
1910 DAV:href. Updated introduction to indicate
1911 relationship to DASL draft. Updated HTTP reference
1912 from RFC2068 to RFC2616. Updated XML reference to
1913 XML 1.0 2nd edition.
1914 March 1, 2002 Removed superfluous namespace decl in 2.4.2.
1915 Reopened JW14 and suggest to drop xml:space
1916 support.
1917 March 3, 2002 Removed "xml:space" feature on DAV:literal. Added
1918 issue about string comparison vs. collations vs.
1919 xml:lang. Updated some of the open issues with
1920 details from JimW's original mail in April 1999.
1921 Resolved scope vs relative URI references. Resolved
1922 issues about DAV:ascending (added to index) and the
1923 BNF for DAV:like (changed "octets" to
1924 "characters").
1925 March 8, 2002 Updated reference to DeltaV (now RFC3253). Added
1926 Martin Wallmer's comments, moved JW5 into
1927 DAV:basicsearch section.
1928 March 11, 2002 Closed open issues regaring the type of search
1929 arbiters (JW3) and their discovery (JW9). Rephrased
1930 requirements on multistatus response bodies
1932 .
1934 (propstat only if properties were selected, removed
1935 requirement for responsedescription).
1936 March 23, 2002 RFC2376 -> RFC3023. Added missing first names of
1937 authors. OPTIONS added to example for
1938 DAV:supported-method-set.
1940 B.3 since draft-reschke-webdav-search-00
1942 March 29, 2002 Abstract doesn't refer to DASL WG anymore.
1943 April 7, 2002 Fixed section title (wrong property name supported-
1944 search-grammar-set. Changed DAV:casesensitve to
1945 "casesensitive" (it wasn't in the DAV: namespace after
1946 all).
1947 May 28, 2002 Updated some issues with Jim Davis's comments.
1948 June 10, 2002 Added proposal for different method for query schema
1949 discovery, not using pseudo-properties.
1950 June 25, 2002 QSD marshalling rewritten. Added issue "isdefined-
1951 optional".
1953 .
1955 Index
1957 D R
1959 DAV:ascending Result Set Truncation
1960 XML element 5.6 Example 2.4.3
1962 DAV:descending
1963 XML element 5.6
1965 DAV:searchrequest S
1966 XML element 2.3
1968 DAV:supported-query-grammar-set Scope
1969 property 3.3 Invalid 2.6
1971 DAV:supported-search-grammar- SEARCH method
1972 set 2
1973 property
1975 O
1977 OPTIONS method
1978 3.1DASL response header
1979 3.2
1981 Q
1983 Query Grammar Discovery
1984 3using OPTIONS 3.1
1985 using live property 3.3
1986 using live property 3.3
1988 .
1990 Full Copyright Statement
1991 Copyright (C) The Internet Society (2002). All Rights Reserved.
1993 This document and translations of it may be copied and furnished
1994 to others, and derivative works that comment on or otherwise
1995 explain it or assist in its implementation may be prepared,
1996 copied, published and distributed, in whole or in part, without
1997 restriction of any kind, provided that the above copyright notice
1998 and this paragraph are included on all such copies and derivative
1999 works. However, this document itself may not be modified in any
2000 way, such as by removing the copyright notice or references to the
2001 Internet Society or other Internet organizations, except as needed
2002 for the purpose of developing Internet standards in which case the
2003 procedures for copyrights defined in the Internet Standards
2004 process must be followed, or as required to translate it into
2005 languages other than English.
2007 The limited permissions granted above are perpetual and will not
2008 be revoked by the Internet Society or its successors or assigns.
2010 This document and the information contained herein is provided on
2011 an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET
2012 ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR
2013 IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF
2014 THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
2015 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
2017 Acknowledgement
2019 Funding for the RFC editor function is currently provided by the
2020 Internet Society.