INTERNET DRAFT Weibin Zhao draft-zhao-slp-url-00.txt Henning Schulzrinne February 19, 2002 Columbia University Expires: August 19, 2002 The SLP URL Format Status of This Memo This document is an Internet-Draft and is in full conformance with all provisions of Section 10 of RFC2026. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet- Drafts. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet- Drafts as reference material or to cite them other than as "work in progress." The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html. Copyright Notice Copyright (C) The Internet Society (2002). All Rights Reserved. Abstract This document describes the SLP URL format for the Service Location Protocol. The SLP URL is used to encode an SLP search query into a URL string, which facilitates the integration of SLP with systems that use URL as an interface, and provides a convenient way to express remote SLP discovery. Zhao/Schulzrinne Expires: August 19, 2002 [Page 1] Internet Draft SLP URL February 19, 2002 1. Introduction The Service Location Protocol (SLP [1]) is a lightweight mechanism for service discovery in IP networks. There are three types of search queries in SLP: Service Request (SrvRqst), Service Type Request (SrvTypeRqst), and Attribute Request (AttrRqst). An SLP search query is sent from a User Agent (UA) to a Directory Agent (DA) via unicast or to all Service Agents (SAs) via multicast. This document describes the SLP URL format, which is used to encode an SLP search query into a URL [2] string. The SLP URL facilitates the integration of SLP with systems that use URL as an interface. For example, a client may want to enter an SLP search query as an SLP URL at a WWW browser where a regular URL is expected. Furthermore, the SLP URL provides a convenient way to express remote SLP discovery [3] since a remote domain name can be specified directly via the SLP URL. The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted according to RFC 2119 [4]. 2. The SLP URL Definition The SLP URL is defined as follows: slpurl = "slp://" [domain-name] "/" query-desc domain-name = hostname from section 5 of RFC 1738 [2] query-desc = queryid "?" [scope] "?" filter ["?" extlist] queryid = "SrvRqst" / "SrvTypeRqst" / "AttrRqst" scope = scope-list from section 6.4.1 of RFC 2608 [1] filter = srvfilter / srvtypefilter / attrfilter srvfilter = "type=" servicetype [";pred=" predicate] [";spi=" spistr] servicetype = service type defined in section 4 of RFC 2608 predicate = predicate from section 8.1 of RFC 2608 spistr = SPI defined in section 9.2 of RFC 2608 srvtypefilter = "na=" nalenstr nalenstr = "0" / "-1" / nastr nastr = naming-auth from section 2.1 of RFC 2609 [5] attrfilter = "url=" url [";tag=" taglist] [";spi=" spistr] url = URL defined in section 4 of RFC 2608 taglist = tag-list from section 10.3 of RFC 2608 extlist = extension / extension ";" extlist extension = attrext / selectext / sortext attrext = "ext=attr" selectext = "ext=select;" upper-bound upper-bound = intval from section 5 of RFC 2608 sortext = "ext=sort;" sort-order ";" sort-key-list Zhao/Schulzrinne Expires: August 19, 2002 [Page 2] Internet Draft SLP URL February 19, 2002 sort-order = intval from section 5 of RFC 2608 sort-key-list = attr-list from section 5 of RFC 2608 When the domain-name is omitted, the search query is resolved locally. The UA sends the query to the DAs it knows in the corresponding scopes, or multicasts the query if no DAs are known in the specified scopes. When the domain-name is present, the search query is resolved in the specified remote domain. Normally the UA first obtains a list of DAs and/or SAs at the specified remote domain via DNS SRV [6], then it sends the query to the chosen DAs or SAs. One of the three queryids ("SrvRqst", "SrvTypeRqst" or "AttrRqst") MUST be given in an SLP URL. If the scope is omitted, the UA SHOULD use the default scope "DEFAULT". One of the three SLP filters (srvfilter, srvtypefilter, or attrfilter) MUST be given in an SLP URL, and MUST match the queryid in the SLP URL. A srvfilter MUST specify a service type, and MAY also specify a predicate and/or an SLP Security Parameters Index (SPI) string. A srvtypefilter MUST specify a naming authority, where "0" means IANA, "-1" means all naming authorities. An attrfilter MUST specify a URL whose attributes are to be retrieved, and MAY also specify a tag list and/or an SPI string. An SLP URL MAY have an extlist. Currently, the formats for Attribute List [7], Selection [8] and Sort [8] extension have been defined. A Selection Extension specifies the upper-bound as a decimal integer whose range is 1 to 255. A Sort Extension specifies the sort-order as a binary integer whose range is 0 to 11111111, and the sort-key-list using the format of SLP attribute list. Note that unsafe characters (as defined in section 2.2 of RFC 1738) and the reserved characters ('?', '=' and ';') that occur inside scope, filter and extlist MUST be escaped using the % method per RFC 1738. Zhao/Schulzrinne Expires: August 19, 2002 [Page 3] Internet Draft SLP URL February 19, 2002 3. Examples o slp:///SrvRqst??type=printer find all printers at the local domain o slp://example.com/SrvRqst??type=printer find all printers at the domain example.com o slp:///SrvRqst??type=printer;pred=(speed%3e%3d15) find all printers at the local domain, with a speed>=15 o slp://example.com/SrvRqst?public?type=printer?ext=attr find all printers in the public scope at the domain example.com, return all attributes. 4. Security Considerations The security considerations for RFC 2608 and RFC 1738 apply to this document. 5. References [1] E. Guttman, C. Perkins, J. Veizades and M. Day, "Service location protocol, version 2", RFC 2608, June 1999. [2] T. Berners-Lee, L. Masinter, and M. McCahill, " Uniform Resource Locators (URL)", RFC 1738, December 1994. [3] W. Zhao, H. Schulzrinne, C. Bisdikian and W. Jerome, "The SLP Service and Remote Discovery in SLP", Internet Draft, February 2002. [4] S. Bradner, "Key words for use in RFCs to indicate requirement levels", BCP 14, RFC 2119, March 1997. [5] E. Guttman, C. Perkins and J. Kempf, "Service Templates and Service: Schemes", RFC 2609, June, 1999. [6] A. Gulbrandsen, P. Vixie and L. Esibov, "A DNS RR for specifying the location of services (DNS SRV)", RFC 2782, February 2000. [7] E. Guttman, "Attribute List Extension for the Service Location Protocol", RFC 3059, February 2001. Zhao/Schulzrinne Expires: August 19, 2002 [Page 4] Internet Draft SLP URL February 19, 2002 [8] W. Zhao, H. Schulzrinne, C. Bisdikian and W. Jerome, "Selection ans Sort Extension for SLP", Internet Draft, February 2002. 6. Authors' Addresses Weibin Zhao Henning Schulzrinne Department of Computer Science Columbia University 1214 Amsterdam Avenue, MC 0401 New York, NY 10027-7003 Email: {zwb,hgs}@cs.columbia.edu 7. Full Copyright Statement Copyright (C) The Internet Society (2002). All Rights Reserved. This document and translations of it may be copied and furnished to others, and derivative works that comment on or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice and this paragraph are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to the Internet Society or other Internet organizations, except as needed for the purpose of developing Internet standards in which case the procedures for copyrights defined in the Internet Standards process must be followed, or as required to translate it into languages other than English. The limited permissions granted above are perpetual and will not be revoked by the Internet Society or its successors or assigns. This document and the information contained herein is provided on an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Zhao/Schulzrinne Expires: August 19, 2002 [Page 5]