idnits 2.17.1 draft-ietf-6man-uri-zoneid-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year (Using the creation date from RFC3986, updated by this document, for RFC5378 checks: 2002-11-01) -- 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 (December 7, 2012) is 4151 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) -- Obsolete informational reference (is this intentional?): RFC 2629 (Obsoleted by RFC 7749) Summary: 0 errors (**), 0 flaws (~~), 1 warning (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 6MAN B. Carpenter 3 Internet-Draft Univ. of Auckland 4 Updates: 3986 (if approved) S. Cheshire 5 Intended status: Standards Track Apple Inc. 6 Expires: June 10, 2013 R. Hinden 7 Check Point 8 December 7, 2012 10 Representing IPv6 Zone Identifiers in Address Literals and Uniform 11 Resource Identifiers 12 draft-ietf-6man-uri-zoneid-06 14 Abstract 16 This document describes how the Zone Identifier of an IPv6 scoped 17 address, as defined in RFC 4007, can be represented in a literal IPv6 18 address and in a Uniform Resource Identifier that includes such a 19 literal address. It updates RFC 3986 accordingly. 21 Status of this Memo 23 This Internet-Draft is submitted in full conformance with the 24 provisions of BCP 78 and BCP 79. 26 Internet-Drafts are working documents of the Internet Engineering 27 Task Force (IETF). Note that other groups may also distribute 28 working documents as Internet-Drafts. The list of current Internet- 29 Drafts is at http://datatracker.ietf.org/drafts/current/. 31 Internet-Drafts are draft documents valid for a maximum of six months 32 and may be updated, replaced, or obsoleted by other documents at any 33 time. It is inappropriate to use Internet-Drafts as reference 34 material or to cite them other than as "work in progress." 36 This Internet-Draft will expire on June 10, 2013. 38 Copyright Notice 40 Copyright (c) 2012 IETF Trust and the persons identified as the 41 document authors. All rights reserved. 43 This document is subject to BCP 78 and the IETF Trust's Legal 44 Provisions Relating to IETF Documents 45 (http://trustee.ietf.org/license-info) in effect on the date of 46 publication of this document. Please review these documents 47 carefully, as they describe your rights and restrictions with respect 48 to this document. Code Components extracted from this document must 49 include Simplified BSD License text as described in Section 4.e of 50 the Trust Legal Provisions and are provided without warranty as 51 described in the Simplified BSD License. 53 Table of Contents 55 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 56 2. Specification . . . . . . . . . . . . . . . . . . . . . . . . 4 57 3. Web Browsers . . . . . . . . . . . . . . . . . . . . . . . . . 5 58 4. Security Considerations . . . . . . . . . . . . . . . . . . . 6 59 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 6 60 6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 6 61 7. Change log [RFC Editor: Please remove] . . . . . . . . . . . . 7 62 8. References . . . . . . . . . . . . . . . . . . . . . . . . . . 7 63 8.1. Normative References . . . . . . . . . . . . . . . . . . . 7 64 8.2. Informative References . . . . . . . . . . . . . . . . . . 8 65 Appendix A. Options Considered . . . . . . . . . . . . . . . . . 8 66 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 10 68 1. Introduction 70 The Uniform Resource Identifier (URI) syntax [RFC3986] defined how a 71 literal IPv6 address can be represented in the "host" part of a URI. 72 A subsequent specification [RFC4007] extended the text representation 73 of limited-scope IPv6 addresses such that a zone identifier may be 74 concatenated to a literal address, for purposes described in that 75 RFC. Zone identifiers are especially useful in contexts where 76 literal addresses are typically used, for example during fault 77 diagnosis, when it may be essential to specify which interface is 78 used for sending to a link local address. It should be noted that 79 zone identifiers have purely local meaning within the node where they 80 are defined, often being the same as IPv6 interface names. They are 81 completely meaningless for any other node. Today, they are only 82 meaningful when attached to addresses with less than global scope, 83 but it is possible that other uses might be defined in the future. 85 RFC 4007 does not specify how zone identifiers are to be represented 86 in URIs. Practical experience has shown that this feature is useful, 87 in particular when using a web browser for debugging with link local 88 addresses, but as it is undefined, it is not implemented consistently 89 in URI parsers or in browsers. 91 Some versions of some browsers accept the RFC 4007 syntax for scoped 92 IPv6 addresses embedded in URIs, i.e., they have been coded to 93 interpret the "%" sign according to RFC 4007 instead of RFC 3986. 94 Clearly this approach is very convenient for users, although it 95 formally breaches the syntax rules of RFC 3986. The present document 96 defines an alternative approach that respects and extends the rules 97 of URI syntax, and IPv6 literals in general, to be consistent. 99 Thus, this document updates [RFC3986] by adding syntax to allow a 100 zone identifier to be included in a literal IPv6 address within a 101 URI. 103 It should be noted that in other contexts than a user interface, a 104 zone identifier is mapped into a numeric zone index or interface 105 number. The MIB textual convention InetZoneIndex [RFC4001] and the 106 socket interface [RFC3493] define this as a 32 bit unsigned integer. 107 The mapping between the human-readable zone identifier string and the 108 numeric value is a host-specific function that varies between 109 operating systems. The present document is concerned only with the 110 human-readable string. 112 Several alternative solutions were considered while this document was 113 developed. The Appendix briefly describes the various options and 114 their advantages and disadvantages. 116 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 117 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 118 document are to be interpreted as described in [RFC2119]. 120 2. Specification 122 According to RFC 4007, a zone identifier is attached to the textual 123 representation of an IPv6 address by concatenating "%" followed by 124 , where is a string identifying the zone of the 125 address. However, RFC 4007 gives no precise definition of the 126 character set allowed in . There are no rules or de facto 127 standards for this. For example, the first Ethernet interface in a 128 host might be called %0, %1, %en1, %eth0, or whatever the implementer 129 happened to choose. 131 In a URI, a literal IPv6 address is always embedded between "[" and 132 "]". This document specifies how a can be appended to the 133 address. Unfortunately "%" is always treated as an escape character 134 in a URI, and according to RFC 3986 it MUST therefore itself be 135 percent-encoded in a URI, in the form "%25". Thus, the scoped 136 address fe80::a%en1 would appear in a URI as http://[fe80::a%25en1]. 138 A SHOULD contain only ASCII characters classified in RFC 139 3986 as "unreserved". This excludes characters such as "]" or even 140 "%" which would complicate parsing. However, the syntax below does 141 allow such characters to be percent-encoded, for compatibility with 142 existing devices that use them. 144 If an operating system uses any other characters in zone or interface 145 identifiers that are not in the "unreserved" character set, they MUST 146 be escaped with a "%" sign according to RFC 3986. 148 We now present the necessary formal syntax. 150 In RFC 3986, the IPv6 literal format is formally defined in ABNF 151 [RFC5234] by the following rule: 153 IP-literal = "[" ( IPv6address / IPvFuture ) "]" 155 To provide support for a zone identifier, the existing syntax of 156 IPv6address is retained, and a zone identifier may be added 157 optionally to any literal address. This allows flexibility for 158 unknown future uses. The rule quoted above from RFC 3986 is replaced 159 by three rules: 161 IP-literal = "[" ( IPv6address / IPv6addrz / IPvFuture ) "]" 163 ZoneID = 1*( unreserved / pct-encoded ) 165 IPv6addrz = IPv6address "%25" ZoneID 167 This syntax fills the gap that is described at the end of Section 168 11.7 of RFC 4007. 170 The rules in [RFC5952] SHOULD be applied in producing URIs. 172 RFC 3986 states that URIs have a global scope, but that in some cases 173 their interpretation depends on the end-user's context. URIs 174 including a ZoneID are to be interpreted only in the context of the 175 host where they originate, since the ZoneID is of local significance 176 only. 178 RFC 4007 offers guidance on how the ZoneID affects interface/address 179 selection inside the IPv6 stack. Note that the behaviour of an IPv6 180 stack if passed a non-null zone index for an address other than link- 181 local is undefined. 183 3. Web Browsers 185 This section discusses how web browsers might handle this syntax 186 extension. Unfortunately there is no formal distinction between the 187 syntax allowed in a browser's input dialogue box and the syntax 188 allowed in URIs. For this reason, no normative statements are made 189 in this section. 191 Due to the lack of defined syntax, web browsers have been 192 inconsistent in providing for ZoneIDs. Many have no support, but 193 there are examples of ad hoc support. For example, some versions of 194 Firefox allowed the use of a ZoneID preceded by an unescaped "%" 195 character, but this was removed for consistency with RFC 3986. As 196 another example, some versions of Internet Explorer allow use of a 197 ZoneID preceded by a "%" character escaped as "%25", still beyond the 198 syntax allowed by RFC 3986. This syntax extension is in fact used 199 internally in the Windows operating system and some of its APIs. 201 It is desirable for all browsers to recognise a ZoneID preceded by an 202 escaped "%". In the spirit of "be liberal with what you accept", we 203 also suggest that URI parsers accept bare "%" signs when possible 204 (i.e., a "%" not followed by two valid and meaningful hexadecimal 205 characters). This would make it possible for a user to copy and 206 paste a string such as "fe80::a%en1" from the output of a "ping" 207 command and have it work. On the other hand, "%ee1" would need to be 208 manually escaped as "fe80::a%25ee1" to avoid any risk of 209 misinterpretation. 211 Such bare "%" signs are for user interface convenience, and need to 212 be turned into properly escaped characters (where "%25" encodes "%") 213 before the URI is used in any protocol or HTML document. However, 214 URIs including a ZoneID have no meaning outside the originating node. 215 It would therefore be highly desirable for a browser to remove the 216 ZoneID from a URI before including that URI in an HTTP request. 218 The normal diagnostic usage for the ZoneID syntax will cause it to be 219 entered in the browser's input dialogue box. Thus, URIs including a 220 ZoneID are unlikely to be encountered in HTML documents. However, if 221 they do (for example, in a diagnostic script coded in HTML) it would 222 be appropriate to treat them exactly as above. 224 4. Security Considerations 226 The security considerations of [RFC3986] and [RFC4007] apply. In 227 particular, this URI format creates a specific pathway by which a 228 deceitful zone index might be communicated, as mentioned in the final 229 security consideration of RFC 4007. It is emphasised that the format 230 is intended only for debugging purposes, but of course this intention 231 does not prevent misuse. 233 To limit this risk, implementations MUST NOT allow use of this format 234 except for well-defined usages such as sending to link local 235 addresses under prefix fe80::/10. At the time of writing, this is 236 the only well-defined usage known. 238 An HTTP client, proxy or other intermediary MUST remove any ZoneID 239 attached to an outgoing URI, as it only has local significance at the 240 sending host. 242 5. IANA Considerations 244 This document requests no action by IANA. 246 6. Acknowledgements 248 The lack of this format was first pointed out by Margaret Wasserman 249 some years ago, and more recently by Kerry Lynn. A previous draft 250 document by Martin Duerst and Bill Fenner [I-D.fenner-literal-zone] 251 discussed this topic but was not finalised. 253 Valuable comments and contributions were made by Karl Auer, Carsten 254 Bormann, Benoit Claise, Stephen Farrell, Brian Haberman, Ted Hardie, 255 Tatuya Jinmei, Yves Lafon, Barry Leiba, Radia Perlman, Tom Petch, 256 Tomoyuki Sahara, Juergen Schoenwaelder, Dave Thaler, Martin Thomson, 257 and Ole Troan. 259 Brian Carpenter was a visitor at the Computer Laboratory, Cambridge 260 University during part of this work. 262 This document was produced using the xml2rfc tool [RFC2629]. 264 7. Change log [RFC Editor: Please remove] 266 draft-ietf-6man-uri-zoneid-06: responding to IETF Last Call and IESG 267 comments, 2012-12-07. 269 draft-ietf-6man-uri-zoneid-05: tuned ABNF, clarified RFC 4007 text, 270 2012-11-06. 272 draft-ietf-6man-uri-zoneid-04: additional author, 2012-09-21. 274 draft-ietf-6man-uri-zoneid-03: reverted to percent-encoded model 275 following WGLC, 2012-09-10. 277 draft-ietf-6man-uri-zoneid-02: additional WG comments, 2012-07-11. 279 draft-ietf-6man-uri-zoneid-01: use "-" instead of %25, listed 280 alternatives in Appendix, according to WG debate, added suggestion 281 for browser developers, 2012-05-29. 283 draft-ietf-6man-uri-zoneid-00: adopted by WG, fixed syntax to allow 284 for % encoded characters, 2012-02-17. 286 draft-carpenter-6man-uri-zoneid-01: chose Option 2, removed 15 287 character limit, added explanation of ID/number mapping and other 288 clarifications, 2012-02-08. 290 draft-carpenter-6man-uri-zoneid-00: original version, 2011-12-07. 292 8. References 294 8.1. Normative References 296 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 297 Requirement Levels", BCP 14, RFC 2119, March 1997. 299 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 300 Resource Identifier (URI): Generic Syntax", STD 66, 301 RFC 3986, January 2005. 303 [RFC4007] Deering, S., Haberman, B., Jinmei, T., Nordmark, E., and 304 B. Zill, "IPv6 Scoped Address Architecture", RFC 4007, 305 March 2005. 307 [RFC5234] Crocker, D. and P. Overell, "Augmented BNF for Syntax 308 Specifications: ABNF", STD 68, RFC 5234, January 2008. 310 [RFC5952] Kawamura, S. and M. Kawashima, "A Recommendation for IPv6 311 Address Text Representation", RFC 5952, August 2010. 313 8.2. Informative References 315 [I-D.fenner-literal-zone] 316 Fenner, B. and M. Duerst, "Formats for IPv6 Scope Zone 317 Identifiers in Literal Address Formats", 318 draft-fenner-literal-zone-02 (work in progress), 319 October 2005. 321 [RFC2629] Rose, M., "Writing I-Ds and RFCs using XML", RFC 2629, 322 June 1999. 324 [RFC3493] Gilligan, R., Thomson, S., Bound, J., McCann, J., and W. 325 Stevens, "Basic Socket Interface Extensions for IPv6", 326 RFC 3493, February 2003. 328 [RFC4001] Daniele, M., Haberman, B., Routhier, S., and J. 329 Schoenwaelder, "Textual Conventions for Internet Network 330 Addresses", RFC 4001, February 2005. 332 [chrome] Google, "Use the address bar (omnibox)", 2012, . 335 Appendix A. Options Considered 337 The syntax defined above allows a ZoneID to be added to any IPv6 338 address. The 6man WG discussed and rejected an alternative in which 339 the existing syntax of IPv6address would be extended by an option to 340 add the ZoneID only for the case of link-local addresses. It was 341 felt that the present solution offers more flexibility for future 342 uses and is more straightforward to implement. 344 The various syntax options considered are now briefly described. 346 1. Leave the problem unsolved. 348 This would mean that per-interface diagnostics would still have 349 to be performed using ping or ping6: 351 ping fe80::a%en1 353 Advantage: works today. 355 Disadvantage: less convenient than using a browser. 357 2. Simply using the percent character. 359 http://[fe80::a%en1] 361 Advantage: allows use of browser, allows cut and paste. 363 Disadvantage: invalid syntax under RFC 3986; not acceptable to 364 URI community. 366 3. Escaping the escape character as allowed by RFC 3986: 368 http://[fe80::a%25en1] 370 Advantage: allows use of browser, consistent with general URI 371 syntax. 373 Disadvantage: somewhat ugly and confusing, doesn't allow simple 374 cut and paste. 376 This is the option chosen for standardization. 378 4. Alternative separator 380 http://[fe80::a-en1] 382 Advantage: allows use of browser, simple syntax 384 Disadvantage: Requires all IPv6 address literal parsers and 385 generators to be updated in order to allow simple cut and paste; 386 inconsistent with existing tools and practice. 388 Note: the initial proposal for this choice was to use an 389 underscore as the separator, but it was noted that this becomes 390 effectively invisible when a user interface automatically 391 underlines URLs. 393 5. With the "IPvFuture" syntax left open in RFC 3986: 395 http://[v6.fe80::a_en1] 397 Advantage: allows use of browser. 399 Disadvantage: ugly and redundant, doesn't allow simple cut and 400 paste. 402 Authors' Addresses 404 Brian Carpenter 405 Department of Computer Science 406 University of Auckland 407 PB 92019 408 Auckland, 1142 409 New Zealand 411 Email: brian.e.carpenter@gmail.com 413 Stuart Cheshire 414 Apple Inc. 415 1 Infinite Loop 416 Cupertino, CA 95014 417 US 419 Email: cheshire@apple.com 421 Robert M. Hinden 422 Check Point Software Technologies, Inc. 423 800 Bridge Parkway 424 Redwood City, CA 94065 425 US 427 Email: bob.hinden@gmail.com