rfc4505.txt 16KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508
  1. Network Working Group K. Zeilenga, Ed.
  2. Request for Comments: 4505 OpenLDAP Foundation
  3. Obsoletes: 2245 June 2006
  4. Category: Standards Track
  5. Anonymous Simple Authentication and Security Layer (SASL) Mechanism
  6. Status of This Memo
  7. This document specifies an Internet standards track protocol for the
  8. Internet community, and requests discussion and suggestions for
  9. improvements. Please refer to the current edition of the "Internet
  10. Official Protocol Standards" (STD 1) for the standardization state
  11. and status of this protocol. Distribution of this memo is unlimited.
  12. Copyright Notice
  13. Copyright (C) The Internet Society (2006).
  14. Abstract
  15. On the Internet, it is common practice to permit anonymous access to
  16. various services. Traditionally, this has been done with a plain-
  17. text password mechanism using "anonymous" as the user name and using
  18. optional trace information, such as an email address, as the
  19. password. As plain-text login commands are not permitted in new IETF
  20. protocols, a new way to provide anonymous login is needed within the
  21. context of the Simple Authentication and Security Layer (SASL)
  22. framework.
  23. 1. Introduction
  24. This document defines an anonymous mechanism for the Simple
  25. Authentication and Security Layer ([SASL]) framework. The name
  26. associated with this mechanism is "ANONYMOUS".
  27. Unlike many other SASL mechanisms, whose purpose is to authenticate
  28. and identify the user to a server, the purpose of this SASL mechanism
  29. is to allow the user to gain access to services or resources without
  30. requiring the user to establish or otherwise disclose their identity
  31. to the server. That is, this mechanism provides an anonymous login
  32. method.
  33. This mechanism does not provide a security layer.
  34. This document replaces RFC 2245. Changes since RFC 2245 are detailed
  35. in Appendix A.
  36. Zeilenga Standards Track [Page 1]
  37. RFC 4505 Anonymous SASL Mechanism June 2006
  38. 2. The Anonymous Mechanism
  39. The mechanism consists of a single message from the client to the
  40. server. The client may include in this message trace information in
  41. the form of a string of [UTF-8]-encoded [Unicode] characters prepared
  42. in accordance with [StringPrep] and the "trace" stringprep profile
  43. defined in Section 3 of this document. The trace information, which
  44. has no semantical value, should take one of two forms: an Internet
  45. email address, or an opaque string that does not contain the '@'
  46. (U+0040) character and that can be interpreted by the system
  47. administrator of the client's domain. For privacy reasons, an
  48. Internet email address or other information identifying the user
  49. should only be used with permission from the user.
  50. A server that permits anonymous access will announce support for the
  51. ANONYMOUS mechanism and allow anyone to log in using that mechanism,
  52. usually with restricted access.
  53. A formal grammar for the client message using Augmented BNF [ABNF] is
  54. provided below as a tool for understanding this technical
  55. specification.
  56. message = [ email / token ]
  57. ;; to be prepared in accordance with Section 3
  58. UTF1 = %x00-3F / %x41-7F ;; less '@' (U+0040)
  59. UTF2 = %xC2-DF UTF0
  60. UTF3 = %xE0 %xA0-BF UTF0 / %xE1-EC 2(UTF0) /
  61. %xED %x80-9F UTF0 / %xEE-EF 2(UTF0)
  62. UTF4 = %xF0 %x90-BF 2(UTF0) / %xF1-F3 3(UTF0) /
  63. %xF4 %x80-8F 2(UTF0)
  64. UTF0 = %x80-BF
  65. TCHAR = UTF1 / UTF2 / UTF3 / UTF4
  66. ;; any UTF-8 encoded Unicode character
  67. ;; except '@' (U+0040)
  68. email = addr-spec
  69. ;; as defined in [IMAIL]
  70. token = 1*255TCHAR
  71. Note to implementors:
  72. The <token> production is restricted to 255 UTF-8-encoded Unicode
  73. characters. As the encoding of a characters uses a sequence of 1
  74. to 4 octets, a token may be as long as 1020 octets.
  75. Zeilenga Standards Track [Page 2]
  76. RFC 4505 Anonymous SASL Mechanism June 2006
  77. 3. The "trace" Profile of "Stringprep"
  78. This section defines the "trace" profile of [StringPrep]. This
  79. profile is designed for use with the SASL ANONYMOUS Mechanism.
  80. Specifically, the client is to prepare the <message> production in
  81. accordance with this profile.
  82. The character repertoire of this profile is Unicode 3.2 [Unicode].
  83. No mapping is required by this profile.
  84. No Unicode normalization is required by this profile.
  85. The list of unassigned code points for this profile is that provided
  86. in Appendix A of [StringPrep]. Unassigned code points are not
  87. prohibited.
  88. Characters from the following tables of [StringPrep] are prohibited:
  89. - C.2.1 (ASCII control characters)
  90. - C.2.2 (Non-ASCII control characters)
  91. - C.3 (Private use characters)
  92. - C.4 (Non-character code points)
  93. - C.5 (Surrogate codes)
  94. - C.6 (Inappropriate for plain text)
  95. - C.8 (Change display properties are deprecated)
  96. - C.9 (Tagging characters)
  97. No additional characters are prohibited.
  98. This profile requires bidirectional character checking per Section 6
  99. of [StringPrep].
  100. 4. Example
  101. Here is a sample ANONYMOUS login between an IMAP client and server.
  102. In this example, "C:" and "S:" indicate lines sent by the client and
  103. server, respectively. If such lines are wrapped without a new "C:"
  104. or "S:" label, then the wrapping is for editorial clarity and is not
  105. part of the command.
  106. Note that this example uses the IMAP profile [IMAP4] of SASL. The
  107. base64 encoding of challenges and responses as well as the "+ "
  108. preceding the responses are part of the IMAP4 profile, not part of
  109. SASL itself. Additionally, protocols with SASL profiles permitting
  110. an initial client response will be able to avoid the extra round trip
  111. below (the server response with an empty "+ ").
  112. Zeilenga Standards Track [Page 3]
  113. RFC 4505 Anonymous SASL Mechanism June 2006
  114. In this example, the trace information is "sirhc".
  115. S: * OK IMAP4 server ready
  116. C: A001 CAPABILITY
  117. S: * CAPABILITY IMAP4 IMAP4rev1 AUTH=DIGEST-MD5 AUTH=ANONYMOUS
  118. S: A001 OK done
  119. C: A002 AUTHENTICATE ANONYMOUS
  120. S: +
  121. C: c2lyaGM=
  122. S: A003 OK Welcome, trace information has been logged.
  123. 5. Security Considerations
  124. The ANONYMOUS mechanism grants access to services and/or resources by
  125. anyone. For this reason, it should be disabled by default so that
  126. the administrator can make an explicit decision to enable it.
  127. If the anonymous user has any write privileges, a denial-of-service
  128. attack is possible by filling up all available space. This can be
  129. prevented by disabling all write access by anonymous users.
  130. If anonymous users have read and write access to the same area, the
  131. server can be used as a communication mechanism to exchange
  132. information anonymously. Servers that accept anonymous submissions
  133. should implement the common "drop box" model, which forbids anonymous
  134. read access to the area where anonymous submissions are accepted.
  135. If the anonymous user can run many expensive operations (e.g., an
  136. IMAP SEARCH BODY command), this could enable a denial-of-service
  137. attack. Servers are encouraged to reduce the priority of anonymous
  138. users or limit their resource usage.
  139. While servers may impose a limit on the number of anonymous users,
  140. note that such limits enable denial-of-service attacks and should be
  141. used with caution.
  142. The trace information is not authenticated, so it can be falsified.
  143. This can be used as an attempt to get someone else in trouble for
  144. access to questionable information. Administrators investigating
  145. abuse need to realize that this trace information may be falsified.
  146. A client that uses the user's correct email address as trace
  147. information without explicit permission may violate that user's
  148. privacy. Anyone who accesses an anonymous archive on a sensitive
  149. subject (e.g., sexual abuse) likely has strong privacy needs.
  150. Clients should not send the email address without the explicit
  151. permission of the user and should offer the option of supplying no
  152. trace information, thus only exposing the source IP address and time.
  153. Zeilenga Standards Track [Page 4]
  154. RFC 4505 Anonymous SASL Mechanism June 2006
  155. Anonymous proxy servers could enhance this privacy but would have to
  156. consider the resulting potential denial-of-service attacks.
  157. Anonymous connections are susceptible to man-in-the-middle attacks
  158. that view or alter the data transferred. Clients and servers are
  159. encouraged to support external data security services.
  160. Protocols that fail to require an explicit anonymous login are more
  161. susceptible to break-ins given certain common implementation
  162. techniques. Specifically, Unix servers that offer user login may
  163. initially start up as root and switch to the appropriate user id
  164. after an explicit login command. Normally, such servers refuse all
  165. data access commands prior to explicit login and may enter a
  166. restricted security environment (e.g., the Unix chroot(2) function)
  167. for anonymous users. If anonymous access is not explicitly
  168. requested, the entire data access machinery is exposed to external
  169. security attacks without the chance for explicit protective measures.
  170. Protocols that offer restricted data access should not allow
  171. anonymous data access without an explicit login step.
  172. General [SASL] security considerations apply to this mechanism.
  173. [StringPrep] security considerations and [Unicode] security
  174. considerations discussed in [StringPrep] apply to this mechanism.
  175. [UTF-8] security considerations also apply.
  176. 6. IANA Considerations
  177. The SASL Mechanism registry [IANA-SASL] entry for the ANONYMOUS
  178. mechanism has been updated by the IANA to reflect that this document
  179. now provides its technical specification.
  180. To: iana@iana.org
  181. Subject: Updated Registration of SASL mechanism ANONYMOUS
  182. SASL mechanism name: ANONYMOUS
  183. Security considerations: See RFC 4505.
  184. Published specification (optional, recommended): RFC 4505
  185. Person & email address to contact for further information:
  186. Kurt Zeilenga <Kurt@OpenLDAP.org>
  187. Chris Newman <Chris.Newman@sun.com>
  188. Intended usage: COMMON
  189. Author/Change controller: IESG <iesg@ietf.org>
  190. Note: Updates existing entry for ANONYMOUS
  191. Zeilenga Standards Track [Page 5]
  192. RFC 4505 Anonymous SASL Mechanism June 2006
  193. The [StringPrep] profile "trace", first defined in this RFC, has been
  194. registered:
  195. To: iana@iana.org
  196. Subject: Initial Registration of Stringprep "trace" profile
  197. Stringprep profile: trace
  198. Published specification: RFC 4505
  199. Person & email address to contact for further information:
  200. Kurt Zeilenga <kurt@openldap.org>
  201. 7. Acknowledgement
  202. This document is a revision of RFC 2245 by Chris Newman. Portions of
  203. the grammar defined in Section 1 were borrowed from RFC 3629 by
  204. Francois Yergeau.
  205. This document is a product of the IETF SASL WG.
  206. 8. Normative References
  207. [ABNF] Crocker, D. and P. Overell, "Augmented BNF for Syntax
  208. Specifications: ABNF", RFC 4234, October 2005.
  209. [IMAIL] Resnick, P., "Internet Message Format", RFC 2822, April
  210. 2001.
  211. [SASL] Melnikov, A., Ed. and K. Zeilenga, Ed., "Simple
  212. Authentication and Security Layer (SASL)", RFC 4422,
  213. June 2006.
  214. [StringPrep] Hoffman, P. and M. Blanchet, "Preparation of
  215. Internationalized Strings ('stringprep')", RFC 3454,
  216. December 2002.
  217. [Unicode] The Unicode Consortium, "The Unicode Standard, Version
  218. 3.2.0" is defined by "The Unicode Standard, Version 3.0"
  219. (Reading, MA, Addison-Wesley, 2000. ISBN 0-201-61633-5),
  220. as amended by the "Unicode Standard Annex #27: Unicode
  221. 3.1" (http://www.unicode.org/reports/tr27/) and by the
  222. "Unicode Standard Annex #28: Unicode 3.2"
  223. (http://www.unicode.org/reports/tr28/).
  224. [UTF-8] Yergeau, F., "UTF-8, a transformation format of ISO
  225. 10646", RFC 3629 (also STD 63), November 2003.
  226. Zeilenga Standards Track [Page 6]
  227. RFC 4505 Anonymous SASL Mechanism June 2006
  228. 9. Informative References
  229. [IMAP4] Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - VERSION
  230. 4rev1", RFC 3501, March 2003.
  231. [IANA-SASL] IANA, "SIMPLE AUTHENTICATION AND SECURITY LAYER (SASL)
  232. MECHANISMS", <http://www.iana.org/assignments/sasl-
  233. mechanisms>.
  234. Zeilenga Standards Track [Page 7]
  235. RFC 4505 Anonymous SASL Mechanism June 2006
  236. Appendix A. Changes since RFC 2245
  237. This appendix is non-normative.
  238. RFC 2245 allows the client to include optional trace information in
  239. the form of a human readable string. RFC 2245 restricted this string
  240. to US-ASCII. As the Internet is international, this document uses a
  241. string restricted to UTF-8 encoded Unicode characters. A
  242. "stringprep" profile is defined to precisely define which Unicode
  243. characters are allowed in this string. While the string remains
  244. restricted to 255 characters, the encoded length of each character
  245. may now range from 1 to 4 octets.
  246. Additionally, a number of editorial changes were made.
  247. Editor's Address
  248. Kurt D. Zeilenga
  249. OpenLDAP Foundation
  250. EMail: Kurt@OpenLDAP.org
  251. Zeilenga Standards Track [Page 8]
  252. RFC 4505 Anonymous SASL Mechanism June 2006
  253. Full Copyright Statement
  254. Copyright (C) The Internet Society (2006).
  255. This document is subject to the rights, licenses and restrictions
  256. contained in BCP 78, and except as set forth therein, the authors
  257. retain all their rights.
  258. This document and the information contained herein are provided on an
  259. "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
  260. OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET
  261. ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED,
  262. INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE
  263. INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
  264. WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
  265. Intellectual Property
  266. The IETF takes no position regarding the validity or scope of any
  267. Intellectual Property Rights or other rights that might be claimed to
  268. pertain to the implementation or use of the technology described in
  269. this document or the extent to which any license under such rights
  270. might or might not be available; nor does it represent that it has
  271. made any independent effort to identify any such rights. Information
  272. on the procedures with respect to rights in RFC documents can be
  273. found in BCP 78 and BCP 79.
  274. Copies of IPR disclosures made to the IETF Secretariat and any
  275. assurances of licenses to be made available, or the result of an
  276. attempt made to obtain a general license or permission for the use of
  277. such proprietary rights by implementers or users of this
  278. specification can be obtained from the IETF on-line IPR repository at
  279. http://www.ietf.org/ipr.
  280. The IETF invites any interested party to bring to its attention any
  281. copyrights, patents or patent applications, or other proprietary
  282. rights that may cover technology that may be required to implement
  283. this standard. Please address the information to the IETF at
  284. ietf-ipr@ietf.org.
  285. Acknowledgement
  286. Funding for the RFC Editor function is provided by the IETF
  287. Administrative Support Activity (IASA).
  288. Zeilenga Standards Track [Page 9]