1
2
3
4
5
6
7Network Working Group J. Yao, Ed.
8Request for Comments: 5336 W. Mao, Ed.
9Updates: 2821, 2822, 4952 CNNIC
10Category: Experimental September 2008
11
12
13 SMTP Extension for Internationalized Email Addresses
14
15Status of This Memo
16
17 This memo defines an Experimental Protocol for the Internet
18 community. It does not specify an Internet standard of any kind.
19 Discussion and suggestions for improvement are requested.
20 Distribution of this memo is unlimited.
21
22Abstract
23
24 This document specifies an SMTP extension for transport and delivery
25 of email messages with internationalized email addresses or header
26 information. Communication with systems that do not implement this
27 specification is specified in another document. This document
28 updates some syntaxes and rules defined in RFC 2821 and RFC 2822, and
29 has some material updating RFC 4952.
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58Yao & Mao Experimental [Page 1]
59
60RFC 5336 EAI SMTP Extension September 2008
61
62
63Table of Contents
64
65 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3
66 1.1. Role of This Specification . . . . . . . . . . . . . . . . 3
67 1.2. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3
68 2. Overview of Operation . . . . . . . . . . . . . . . . . . . . 4
69 3. Mail Transport-Level Protocol . . . . . . . . . . . . . . . . 4
70 3.1. Framework for the Internationalization Extension . . . . . 4
71 3.2. The UTF8SMTP Extension . . . . . . . . . . . . . . . . . . 5
72 3.3. Extended Mailbox Address Syntax . . . . . . . . . . . . . 7
73 3.4. The ALT-ADDRESS Parameter . . . . . . . . . . . . . . . . 9
74 3.5. ALT-ADDRESS Parameter Usage and Response Codes . . . . . . 10
75 3.6. Body Parts and SMTP Extensions . . . . . . . . . . . . . . 11
76 3.7. Additional ESMTP Changes and Clarifications . . . . . . . 11
77 3.7.1. The Initial SMTP Exchange . . . . . . . . . . . . . . 12
78 3.7.2. Mail eXchangers . . . . . . . . . . . . . . . . . . . 12
79 3.7.3. Trace Information . . . . . . . . . . . . . . . . . . 12
80 3.7.4. UTF-8 Strings in Replies . . . . . . . . . . . . . . . 13
81 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 15
82 5. Security Considerations . . . . . . . . . . . . . . . . . . . 17
83 6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 17
84 7. References . . . . . . . . . . . . . . . . . . . . . . . . . . 18
85 7.1. Normative References . . . . . . . . . . . . . . . . . . . 18
86 7.2. Informative References . . . . . . . . . . . . . . . . . . 19
87 Appendix A. Material Updating RFC 4952 . . . . . . . . . . . . . 20
88 A.1. Conventional Message and Internationalized Message . . . . 20
89 A.2. LMTP . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
90 A.3. SMTP Service Extension for DSNs . . . . . . . . . . . . . 20
91 A.4. Implementation Advice . . . . . . . . . . . . . . . . . . 20
92 A.5. Applicability of SMTP Extension to Additional Uses . . . . 21
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114Yao & Mao Experimental [Page 2]
115
116RFC 5336 EAI SMTP Extension September 2008
117
118
1191. Introduction
120
121 An internationalized email address includes two parts, the local part
122 and the domain part. The ways email addresses are used by protocols
123 are different from the ways domain names are used. The most critical
124 difference is that emails are delivered through a chain of clients
125 and servers, while domain names are resolved by name servers looking
126 up those names in their own tables. In addition to this, the Simple
127 Mail Transfer Protocol [RFC2821] provides a negotiation mechanism
128 about service extension with which clients can discover server
129 capabilities and make decisions for further processing. An extended
130 overview of the extension model for internationalized addresses and
131 headers appears in [RFC4952], referred to as "the framework document"
132 or just as "Framework" elsewhere in this specification. This
133 document specifies an SMTP extension to permit internationalized
134 email addresses in envelopes, and UNICODE characters (encoded in
135 UTF-8) [RFC3629] in headers.
136
1371.1. Role of This Specification
138
139 The framework document specifies the requirements for, and describes
140 components of, full internationalization of electronic mail. A
141 thorough understanding of the information in that document and in the
142 base Internet email specifications [RFC2821] [RFC2822] is necessary
143 to understand and implement this specification.
144
145 This document specifies an element of the email internationalization
146 work, specifically the definition of an SMTP extension [RFC2821] for
147 internationalized email address transport delivery.
148
1491.2. Terminology
150
151 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
152 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
153 document are to be interpreted as described in RFC 2119 [RFC2119].
154
155 The terms "conventional message" and "internationalized message" are
156 defined in an appendix to this specification. The terms "UTF-8
157 string" or "UTF-8 character" are used informally to refer to Unicode
158 characters encoded in UTF-8 [RFC3629]. All other specialized terms
159 used in this specification are defined in the framework document or
160 in the base Internet email specifications [RFC2821] [RFC2822]. In
161 particular, the terms "ASCII address", "internationalized email
162 address", "non-ASCII address", "i18mail address", "UTF8SMTP",
163 "message", and "mailing list" are used in this document according to
164 the definitions in the framework document.
165
166
167
168
169
170Yao & Mao Experimental [Page 3]
171
172RFC 5336 EAI SMTP Extension September 2008
173
174
175 This specification defines only those Augmented BNF (ABNF) [RFC5234]
176 syntax rules that are different from those of the base email
177 specifications [RFC2821][RFC2822] and, where the earlier rules are
178 upgraded or extended, gives them new names. When the new rule is a
179 small modification to the older one, it is typically given a name
180 starting with "u". Rules that are undefined here may be found in the
181 base email specifications under the same names.
182
1832. Overview of Operation
184
185 This specification describes an optional extension to the email
186 transport mechanism that permits non-ASCII [ASCII] characters in both
187 the envelope and header fields of messages, which are encoded with
188 UTF-8 [RFC3629] characters. The extension is identified with the
189 token "UTF8SMTP". In order to provide information that may be needed
190 in downgrading, an optional alternate ASCII address may be needed if
191 an SMTP client attempts to transfer an internationalized message and
192 encounters a server that does not support this extension.
193
194 The EAI UTF-8 header specification [RFC5335] provides the details of
195 how and where non-ASCII characters are permitted in the header fields
196 of messages. The context for this specification is described in the
197 framework document.
198
1993. Mail Transport-Level Protocol
200
2013.1. Framework for the Internationalization Extension
202
203 The following service extension is defined:
204
205 1. The name of the SMTP service extension is "Email Address
206 Internationalization".
207
208 2. The EHLO keyword value associated with this extension is
209 "UTF8SMTP".
210
211 3. No parameter values are defined for this EHLO keyword value. In
212 order to permit future (although unanticipated) extensions, the
213 EHLO response MUST NOT contain any parameters for that keyword.
214 Clients MUST ignore any parameters; that is, clients MUST behave
215 as if the parameters do not appear. If a server includes
216 UTF8SMTP in its EHLO response, it MUST be fully compliant with
217 this version of this specification.
218
219
220
221
222
223
224
225
226Yao & Mao Experimental [Page 4]
227
228RFC 5336 EAI SMTP Extension September 2008
229
230
231 4. One optional parameter, ALT-ADDRESS, is added to the MAIL and
232 RCPT commands of SMTP. ALT-ADDRESS specifies an all-ASCII
233 address which can be used as a substitute for the corresponding
234 primary (i18mail) address when downgrading. More discussion of
235 the use of this parameter appears in [RFC4952] and [Downgrade].
236
237 5. One optional parameter "UTF8REPLY" is added to the VRFY and EXPN
238 commands. The parameter UTF8REPLY has no value. The parameter
239 indicates that the SMTP client can accept Unicode characters in
240 UTF-8 encoding in replies from the VRFY and EXPN commands.
241
242 6. No additional SMTP verbs are defined by this extension.
243
244 7. Servers offering this extension MUST provide support for, and
245 announce, the 8BITMIME extension [RFC1652].
246
247 8. The reverse-path and forward-path of the SMTP MAIL and RCPT
248 commands are extended to allow Unicode characters encoded in
249 UTF-8 in mailbox names (addresses).
250
251 9. The mail message body is extended as specified in [RFC5335].
252
253 10. The maximum length of MAIL and RCPT command lines is increased
254 by 460 characters by the possible addition of the ALT-ADDRESS
255 keyword and value.
256
257 11. The UTF8SMTP extension is valid on the submission port
258 [RFC4409].
259
2603.2. The UTF8SMTP Extension
261
262 An SMTP server that announces this extension MUST be prepared to
263 accept a UTF-8 string [RFC3629] in any position in which RFC 2821
264 specifies that a mailbox can appear. That string MUST be parsed only
265 as specified in RFC 2821, i.e., by separating the mailbox into source
266 route, local part, and domain part, using only the characters colon
267 (U+003A), comma (U+002C), and at-sign (U+0040) as specified there.
268 Once isolated by this parsing process, the local part MUST be treated
269 as opaque unless the SMTP server is the final delivery Mail Transfer
270 Agent (MTA). Any domain names that are to be looked up in the DNS
271 MUST first be processed into the form specified in
272 "Internationalizing Domain Names in Applications (IDNA)" [RFC3490] by
273 means of the ToASCII() operation unless they are already in that
274 form. Any domain names that are to be compared to local strings
275 SHOULD be checked for validity and then MUST be compared as specified
276 in Section 3.4 of IDNA.
277
278
279
280
281
282Yao & Mao Experimental [Page 5]
283
284RFC 5336 EAI SMTP Extension September 2008
285
286
287 An SMTP client that receives the UTF8SMTP extension keyword in
288 response to the EHLO command MAY transmit mailbox names within SMTP
289 commands as internationalized strings in UTF-8 form. It MAY send a
290 UTF-8 header [RFC5335] (which may also include mailbox names in
291 UTF-8). It MAY transmit the domain parts of mailbox names within
292 SMTP commands or the message header as either ACE (ASCII Compatible
293 Encoding) labels (as specified in IDNA [RFC3490]) or UTF-8 strings.
294 All labels in domain parts of mailbox names which are IDNs (either
295 UTF-8 or ACE strings) MUST be valid. If the original client submits
296 a message to a Message Submission Server ("MSA") [RFC4409], it is the
297 responsibility of the MSA that all domain labels are valid;
298 otherwise, it is the original client's responsibility. The presence
299 of the UTF8SMTP extension does not change the requirement of RFC 2821
300 that servers relaying mail MUST NOT attempt to parse, evaluate, or
301 transform the local part in any way.
302
303 If the UTF8SMTP SMTP extension is not offered by the Server, the SMTP
304 client MUST NOT transmit an internationalized address and MUST NOT
305 transmit a mail message containing internationalized mail headers as
306 described in [RFC5335] at any level within its MIME structure. (For
307 this paragraph, the internationalized domain name in the form of ACE
308 labels as specified in IDNA [RFC3490] is not considered as
309 "internationalized".) Instead, if an SMTP client (SMTP sender)
310 attempts to transfer an internationalized message and encounters a
311 server that does not support the extension, it MUST make one of the
312 following four choices:
313
314 1. If and only if the SMTP client (sender) is a Message Submission
315 Server ("MSA") [RFC4409], it MAY, consistent with the general
316 provisions for changes by such servers, rewrite the envelope,
317 headers, or message material to make them entirely ASCII and
318 consistent with the provisions of RFC 2821 [RFC2821] and RFC 2822
319 [RFC2822].
320
321 2. It may either reject the message during the SMTP transaction or
322 accept the message and then generate and transmit a notification
323 of non-deliverability. Such notification MUST be done as
324 specified in RFC 2821 [RFC2821], RFC 3464 [RFC3464], and the EAI
325 delivery status notification (DSN) specification [RFC5337].
326
327 3. It may find an alternate route to the destination that permits
328 UTF8SMTP. That route may be discovered by trying alternate Mail
329 eXchanger (MX) hosts (using preference rules as specified in RFC
330 2821) or using other means available to the SMTP-sender.
331
332 4. If and only if ASCII addresses are available for all addresses
333 that appear in the return path and the specific forward paths
334 being attempted, it may downgrade the message to an all-ASCII
335
336
337
338Yao & Mao Experimental [Page 6]
339
340RFC 5336 EAI SMTP Extension September 2008
341
342
343 form as specified in [Downgrade]. An ASCII address is considered
344 to be "available" for a particular address if the original
345 address in the envelope is in ASCII or if an ALT-ADDRESS
346 parameter is specified for a UTF8SMTP address.
347
348 The difference between choice 1 and choice 4 is that choice 1 is
349 constrained by Message Submission [RFC4409], while choice 4 is
350 constrained by [Downgrade].
351
3523.3. Extended Mailbox Address Syntax
353
354 RFC 2821, Section 4.1.2, defines the syntax of a mailbox entirely in
355 terms of ASCII characters, using the production for a mailbox and
356 those productions on which it depends.
357
358 The key changes made by this specification are, informally, to
359
360 o Change the definition of "sub-domain" to permit either the
361 definition above or a UTF-8 string representing a DNS label that
362 is conformant with IDNA [RFC3490].
363
364 o Change the definition of "Atom" to permit either the definition
365 above or a UTF-8 string. That string MUST NOT contain any of the
366 ASCII characters (either graphics or controls) that are not
367 permitted in "atext"; it is otherwise unrestricted.
368
369 According to the description above, the syntax of an
370 internationalized email mailbox name (address) is defined in ABNF
371 [RFC5234] as follows.
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394Yao & Mao Experimental [Page 7]
395
396RFC 5336 EAI SMTP Extension September 2008
397
398
399 uMailbox = uLocal-part "@" uDomain
400 ; Replace Mailbox in RFC 2821, Section 4.1.2
401
402 uLocal-part = uDot-string / uQuoted-string
403 ; MAY be case-sensitive
404 ; Replace Local-part in RFC 2821, Section 4.1.2
405
406 uDot-string = uAtom *("." uAtom)
407 ; Replace Dot-string in RFC 2821, Section 4.1.2
408
409 uAtom = 1*ucharacter
410 ; Replace Atom in RFC 2821, Section 4.1.2
411
412 ucharacter = atext / UTF8-non-ascii
413
414 atext = <See Section 3.2.4 of RFC 2822>
415
416 uQuoted-string = DQUOTE *uqcontent DQUOTE
417 ; Replace Quoted-string in RFC 2821, Section 4.1.2
418
419 DQUOTE = <See appendix B.1 of RFC 5234>
420
421 uqcontent = qcontent / UTF8-non-ascii
422
423 qcontent = <See Section 3.2.5 of RFC 2822>
424
425 uDomain = (sub-udomain 1*("." sub-udomain)) / address-literal
426 ; Replace Domain in RFC 2821, Section 4.1.2
427
428 address-literal = <See Section 4.1.2 of RFC 2822>
429
430 sub-udomain = uLet-dig [uLdh-str]
431 ; Replace sub-domain in RFC 2821, Section 4.1.2
432
433 uLet-dig = Let-dig / UTF8-non-ascii
434
435 Let-dig = <See Section 4.1.3 of RFC 2821>
436
437 uLdh-str = *( ALPHA / DIGIT / "-" / UTF8-non-ascii) uLet-dig
438 ; Replace Ldh-str in RFC 2821, Section 4.1.3
439
440 UTF8-non-ascii = UTF8-2 / UTF8-3 / UTF8-4
441
442 UTF8-2 = <See Section 4 of RFC 3629>
443
444 UTF8-3 = <See Section 4 of RFC 3629>
445
446 UTF8-4 = <See Section 4 of RFC 3629>
447
448
449
450Yao & Mao Experimental [Page 8]
451
452RFC 5336 EAI SMTP Extension September 2008
453
454
455 The value of "uDomain" SHOULD be verified by applying the tests
456 specified as part of IDNA [RFC3490]. If that verification fails, the
457 email address with that uDomain MUST NOT be regarded as a valid email
458 address.
459
4603.4. The ALT-ADDRESS Parameter
461
462 If the UTF8SMTP extension is offered, the syntax of the SMTP MAIL and
463 RCPT commands is extended to support the optional esmtp-keyword "ALT-
464 ADDRESS". That keyword specifies an alternate all-ASCII address that
465 may be used when downgrading. If the ALT-ADDRESS esmtp-keyword is
466 used, it MUST have an associated esmtp-value (ALT-ADDRESS-esmtp-
467 value, which is defined below).
468
469 While it may be tempting to consider ALT-ADDRESS as a general-purpose
470 second-chance address, such behavior is not defined here. Instead,
471 in this specification ALT-ADDRESS only has meaning when the
472 associated primary address is non-ASCII and the message is
473 downgraded. This restriction allows for future extension of the
474 specification even though no such extensions are currently
475 anticipated.
476
477 Based on the definition of mail-parameters in [RFC2821], the ALT-
478 ADDRESS parameter usage in the commands of MAIL and RCPT is defined
479 as follows. The following definitions are given in the same format
480 as used in RFC 2821.
481
482 "MAIL FROM:" ("<>" / uReverse-path) [ SP Mail-parameters ] CRLF
483 ; Update the MAIL command in RFC 2821, Section 4.1.1.2.
484 ; A new parameter defined by the ABNF non-terminal
485 ; <ALT-ADDRESS-parameter> is added. It complies
486 ; with the syntax specified for <esmtp-param> in RFC 2821.
487
488 "RCPT TO:" ("<Postmaster@" uDomain ">" / "<Postmaster>" /
489 uForward-path) [ SP Rcpt-parameters ] CRLF
490 ; Update RCPT command in RFC 2821, Section 4.1.1.3.
491 ; A new parameter defined by the ABNF non-terminal
492 ; <ALT-ADDRESS-parameter> is added. It complies
493 ; with the syntax specified for <esmtp-param>.
494 ; uDomain is defined in Section 3.3 of this document.
495
496 uReverse-path = uPath
497 ; Replace Reverse-path in RFC 2821, Section 4.1.2.
498
499 uForward-path = uPath
500 ; Replace Forward-path in RFC 2821, Section 4.1.2.
501
502
503
504
505
506Yao & Mao Experimental [Page 9]
507
508RFC 5336 EAI SMTP Extension September 2008
509
510
511 uPath = "<" [ A-d-l ":" ] uMailbox ">"
512 ; Replace Path in RFC 2821, Section 4.1.2.
513 ; uMailbox is defined in Section 3.3 of this document.
514
515 A-d-l = <See Section 4.1.2 of RFC 2821>
516
517 ALT-ADDRESS-parameter = "ALT-ADDRESS=" ALT-ADDRESS-value
518
519 ALT-ADDRESS-value = xtext
520 ; The value is a mailbox name encoded as xtext.
521
522 xtext = <See Section 4.2 of RFC 3461>
523
524 The ALT-ADDRESS-parameter MUST NOT appear more than once in any MAIL
525 or RCPT command. ALT-ADDRESS-esmtp-value MUST be an all-ASCII email
526 address before xtext encoding.
527
5283.5. ALT-ADDRESS Parameter Usage and Response Codes
529
530 An "internationalized message" as defined in the appendix of this
531 specification MUST NOT be sent to an SMTP server that does not
532 support UTF8SMTP. Such a message MAY be rejected by a server if it
533 lacks ALT-ADDRESSes as discussed in Section 3.2 of this
534 specification.
535
536 The three-digit reply codes used in this section are consistent with
537 their meanings as defined in RFC 2821.
538
539 When messages are rejected because the RCPT command requires an ALT-
540 ADDRESS, the response code 553 is used with the meaning "mailbox name
541 not allowed". When messages are rejected for other reasons, such as
542 the MAIL command requiring an ALT-ADDRESS, the response code 550 is
543 used with the meaning "mailbox unavailable". When the server
544 supports enhanced mail system status codes [RFC3463], response code
545 "X.6.7" [RFC5248] is used, meaning that "The ALT-ADDRESS is required
546 but not specified".
547
548 If the response code is issued after the final "." of the DATA
549 command, the response code "554" is used with the meaning
550 "Transaction failed". When the server supports enhanced mail system
551 status codes [RFC3463], response code "X.6.9" [RFC5248] is used,
552 meaning that "UTF8SMTP downgrade failed".
553
554
555
556
557
558
559
560
561
562Yao & Mao Experimental [Page 10]
563
564RFC 5336 EAI SMTP Extension September 2008
565
566
5673.6. Body Parts and SMTP Extensions
568
569 There is no ESMTP parameter to assert that a message is an
570 internationalized message. An SMTP server that requires accurate
571 knowledge of whether a message is internationalized is required to
572 parse all message header fields and MIME header fields in the message
573 body.
574
575 While this specification requires that servers support the 8BITMIME
576 extension [RFC1652] to ensure that servers have adequate handling
577 capability for 8-bit data and to avoid a number of complex encoding
578 problems, the use of internationalized addresses obviously does not
579 require non-ASCII body parts in the MIME message. The UTF8SMTP
580 extension MAY be used with the BODY=8BITMIME parameter if that is
581 appropriate given the body content or, with the BODY=BINARYMIME
582 parameter, if the server advertises BINARYMIME [RFC3030] and that is
583 appropriate.
584
585 Assuming that the server advertises UTF8SMTP and 8BITMIME, and
586 receives at least one non-ASCII address, with or without ALT-ADDRESS,
587 the precise interpretation of 'No BODY parameter', "BODY=8BITMIME",
588 and "BODY=BINARYMIME" in the MAIL command is:
589
590 1. If there is no BODY parameter, the header contains UTF-8
591 characters, but all the body parts are in ASCII (possibly as the
592 result of a content-transfer-encoding).
593
594 2. If a BODY=8BITMIME parameter is present, the header contains
595 UTF-8 characters, and some or all of the body parts contain 8-bit
596 line-oriented data.
597
598 3. If a BODY=BINARYMIME parameter is present, the header contains
599 UTF-8 characters, and some or all body parts contain binary data
600 without restriction as to line lengths or delimiters.
601
6023.7. Additional ESMTP Changes and Clarifications
603
604 The information carried in the mail transport process involves
605 addresses ("mailboxes") and domain names in various contexts in
606 addition to the MAIL and RCPT commands and extended alternatives to
607 them. In general, the rule is that, when RFC 2821 specifies a
608 mailbox, this specification expects UTF-8 to be used for the entire
609 string; when RFC 2821 specifies a domain name, the name SHOULD be in
610 the form of ACE labels if its raw form is non-ASCII.
611
612 The following subsections list and discuss all of the relevant cases.
613
614
615
616
617
618Yao & Mao Experimental [Page 11]
619
620RFC 5336 EAI SMTP Extension September 2008
621
622
6233.7.1. The Initial SMTP Exchange
624
625 When an SMTP connection is opened, the server normally sends a
626 "greeting" response consisting of the 220 response code and some
627 information. The client then sends the EHLO command. Since the
628 client cannot know whether the server supports UTF8SMTP until after
629 it receives the response from EHLO, any domain names that appear in
630 this dialogue, or in responses to EHLO, MUST be in the hostname form,
631 i.e., internationalized ones MUST be in the form of ACE labels.
632
6333.7.2. Mail eXchangers
634
635 Organizations often authorize multiple servers to accept mail
636 addressed to them. For example, the organization may itself operate
637 more than one server, and may also or instead have an agreement with
638 other organizations to accept mail as a backup. Authorized servers
639 are generally listed in MX records as described in RFC 2821. When
640 more than one server accepts mail for the domain-part of a mailbox,
641 it is strongly advised that either all or none of them support the
642 UTF8SMTP extension. Otherwise, surprising downgrades can happen
643 during temporary failures, which users might perceive as a serious
644 reliability issue.
645
6463.7.3. Trace Information
647
648 When an SMTP server receives a message for delivery or further
649 processing, it MUST insert trace ("time stamp" or "Received")
650 information at the beginning of the message content. "Time stamp" or
651 "Received" appears in the form of "Received:" lines. The most
652 important use of Received: lines is for debugging mail faults. When
653 the delivery SMTP server makes the "final delivery" of a message, it
654 inserts a Return-path line at the beginning of the mail data. The
655 primary purpose of the Return-path is to designate the address to
656 which messages indicating non-delivery or other mail system failures
657 are to be sent. For the trace information, this memo updates the
658 time stamp line and the return path line [RFC2821] formally defined
659 as follows:
660
661 uReturn-path-line = "Return-Path:" FWS uReverse-path <CRLF>
662 ; Replaces Return-path-line in Section 4.4 of RFC 2821
663 ; uReverse-path is defined in Section 3.3 of this document
664
665 uTime-stamp-line = "Received:" FWS uStamp <CRLF>
666 ; Replaces Time-stamp-line in Section 4.4 of RFC 2821
667
668 uStamp = From-domain By-domain uOpt-info ";" FWS date-time
669 ; Replaces Stamp in Section 4.4 of RFC 2821
670
671
672
673
674Yao & Mao Experimental [Page 12]
675
676RFC 5336 EAI SMTP Extension September 2008
677
678
679 uOpt-info = [Via] [With] [ID] [uFor]
680 ; Replaces Opt-info in Section 4.4 of RFC 2821
681 ; The protocol value for With will allow a UTF8SMTP value
682
683 uFor = "FOR" ( FWS (uPath / uMailbox) ) CFWS
684 ; Replaces For in Section 4.4 of RFC 2821
685 ; uPath and uMailbox are defined in Sections 2.4 and
686 ; 2.3, respectively, of this document
687
688 Note: The FOR parameter has been changed to match the definition in
689 [RFC2821bis], permitting only one address in the For clause. The
690 group working on that document reached mailing list consensus that
691 the syntax in [RFC2821] that permitted more than one address was
692 simply a mistake.
693
694 Except in the 'uFor' clause and 'uReverse-path' value where non-ASCII
695 domain names may be used, internationalized domain names in Received
696 fields MUST be transmitted in the form of ACE labels. The protocol
697 value of the WITH clause when this extension is used is one of the
698 UTF8SMTP values specified in the "IANA Considerations" section of
699 this document.
700
7013.7.4. UTF-8 Strings in Replies
702
7033.7.4.1. MAIL and RCPT Commands
704
705 If the client issues a RCPT command containing non-ASCII characters,
706 the SMTP server is permitted to use UTF-8 characters in the email
707 address associated with 251 and 551 response codes.
708
709 If an SMTP client follows this specification and sends any RCPT
710 commands containing non-ASCII addresses, it MUST be able to accept
711 and process 251 or 551 responses containing UTF-8 email addresses.
712 If a given RCPT command does not include a non-ASCII envelope
713 address, the server MUST NOT return a 251 or 551 response containing
714 a non-ASCII mailbox. Instead, it MUST transform such responses into
715 250 or 550 responses that do not contain addresses.
716
7173.7.4.2. VRFY and EXPN Commands and the UTF8REPLY Parameter
718
719 If the VRFY and EXPN commands are transmitted with an optional
720 parameter "UTF8REPLY", it indicates the client can accept UTF-8
721 strings in replies from those commands. This allows the server to
722 use UTF-8 strings in mailbox names and full names that occur in
723 replies without concern that the client might be confused by them.
724 An SMTP client that conforms to this specification MUST accept and
725 correctly process replies from the VRFY and EXPN commands that
726 contain UTF-8 strings. However, the SMTP server MUST NOT use UTF-8
727
728
729
730Yao & Mao Experimental [Page 13]
731
732RFC 5336 EAI SMTP Extension September 2008
733
734
735 strings in replies if the SMTP client does not specifically allow
736 such replies by transmitting this parameter. Most replies do not
737 require that a mailbox name be included in the returned text, and
738 therefore UTF-8 is not needed in them. Some replies, notably those
739 resulting from successful execution of the VRFY and EXPN commands, do
740 include the mailbox, making the provisions of this section important.
741
742 VERIFY (VRFY) and EXPAND (EXPN) command syntaxes are changed to:
743
744 "VRFY" SP (uLocal-part / uMailbox) [SP "UTF8REPLY"] CRLF
745 ; uLocal-part and uMailbox are defined in
746 ; Section 3.3 of this document.
747
748 "EXPN" SP ( uLocal-part / uMailbox ) [ SP "UTF8REPLY" ] CRLF
749 ; uLocal-part and uMailbox are defined in
750 ; Section 3.3 of this document.
751
752 The "UTF8REPLY" parameter does not use a value. If the reply to a
753 VERIFY (VRFY) or EXPAND (EXPN) command requires UTF-8, but the SMTP
754 client does not use the "UTF8REPLY" parameter, then the server MUST
755 use either the response code 252 or 550. Response code 252, defined
756 in [RFC2821], means "Cannot VRFY user, but will accept the message
757 and attempt the delivery". Response code 550, also defined in
758 [RFC2821], means "Requested action not taken: mailbox unavailable".
759 When the server supports enhanced mail system status codes [RFC3463],
760 the enhanced response code as specified below is used. Using the
761 "UTF8REPLY" parameter with a VERIFY (VRFY) or EXPAND (EXPN) command
762 enables UTF-8 replies for that command only.
763
764 If a normal success response (i.e., 250) is returned, the response
765 MAY include the full name of the user and MUST include the mailbox of
766 the user. It MUST be in either of the following forms:
767
768 User Name <uMailbox>
769 ; uMailbox is defined in Section 3.3 of this document.
770 ; User Name can contain non-ASCII characters.
771
772 uMailbox
773 ; uMailbox is defined in Section 3.3 of this document.
774
775 If the SMTP reply requires UTF-8 strings, but UTF-8 is not allowed in
776 the reply, and the server supports enhanced mail system status codes
777 [RFC3463], the enhanced response code is either "X.6.8" or "X.6.10"
778 [RFC5248], meaning "A reply containing a UTF-8 string is required to
779 show the mailbox name, but that form of response is not permitted by
780 the client".
781
782
783
784
785
786Yao & Mao Experimental [Page 14]
787
788RFC 5336 EAI SMTP Extension September 2008
789
790
791 If the SMTP client does not support the UTF8SMTP extension, but
792 receives a UTF-8 string in a reply, it may not be able to properly
793 report the reply to the user, and some clients might crash.
794 Internationalized messages in replies are only allowed in the
795 commands under the situations described above. Under any other
796 circumstances, UTF-8 text MUST NOT appear in the reply.
797
798 Although UTF-8 is needed to represent email addresses in responses
799 under the rules specified in this section, this extension does not
800 permit the use of UTF-8 for any other purposes. SMTP servers MUST
801 NOT include non-ASCII characters in replies except in the limited
802 cases specifically permitted in this section.
803
8044. IANA Considerations
805
806 IANA has added a new value "UTF8SMTP" to the SMTP Service Extension
807 subregistry of the Mail Parameters registry, according to the
808 following data:
809
810 +----------+---------------------------------+-----------+
811 | Keywords | Description | Reference |
812 +----------+---------------------------------+-----------+
813 | UTF8SMTP | Internationalized email address | [RFC5336] |
814 +----------+---------------------------------+-----------+
815
816 This document adds new values to the SMTP Enhanced Status Code
817 subregistry of the Mail Parameters registry, following the guidance
818 in Sections 3.5 and 3.7.4.2 of this document, and being based on
819 [RFC5248]. The registration data is as follows:
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842Yao & Mao Experimental [Page 15]
843
844RFC 5336 EAI SMTP Extension September 2008
845
846
847 Code: X.6.7
848 Sample Text: The ALT-ADDRESS is required but not specified
849 Associated basic status code: 553, 550
850 Description: This indicates the reception of a MAIL or RCPT
851 command that required an ALT-ADDRESS parameter
852 but such parameter was not present.
853 Defined: RFC 5336 (Experimental track)
854 Submitter: Jiankang YAO
855 Change controller: IESG.
856
857
858 Code: X.6.8
859 Sample Text: UTF-8 string reply is required,
860 but not permitted by the client
861 Associated basic status code: 553, 550
862 Description: This indicates that a reply containing a UTF-8
863 string is required to show the mailbox name,
864 but that form of response is not
865 permitted by the client.
866 Defined: RFC 5336. (Experimental track)
867 Submitter: Jiankang YAO
868 Change controller: IESG.
869
870
871 Code: X.6.9
872 Sample Text: UTF8SMTP downgrade failed
873 Associated basic status code: 550
874 Description: This indicates that transaction failed
875 after the final "." of the DATA command.
876 Defined: RFC 5336. (Experimental track)
877 Submitter: Jiankang YAO
878 Change controller: IESG.
879
880
881 Code: X.6.10
882 Sample Text: UTF-8 string reply is required,
883 but not permitted by the client
884 Associated basic status code: 252
885 Description: This indicates that a reply containing a UTF-8
886 string is required to show the mailbox name,
887 but that form of response is not
888 permitted by the client.
889 Defined: RFC 5336. (Experimental track)
890 Submitter: Jiankang YAO
891 Change controller: IESG.
892
893
894
895
896
897
898Yao & Mao Experimental [Page 16]
899
900RFC 5336 EAI SMTP Extension September 2008
901
902
903 The "Mail Transmission Types" registry under the Mail Parameters
904 registry is requested to be updated to include the following new
905 entries:
906
907 +---------------+----------------------------+----------------------+
908 | WITH protocol | Description | Reference |
909 | types | | |
910 +---------------+----------------------------+----------------------+
911 | UTF8SMTP | UTF8SMTP with Service | [RFC5336] |
912 | | Extensions | |
913 | UTF8SMTPA | UTF8SMTP with SMTP AUTH | [RFC4954] [RFC5336] |
914 | UTF8SMTPS | UTF8SMTP with STARTTLS | [RFC3207] [RFC5336] |
915 | UTF8SMTPSA | UTF8SMTP with both | [RFC3207] [RFC4954] |
916 | | STARTTLS and SMTP AUTH | [RFC5336] |
917 +---------------+----------------------------+----------------------+
918
9195. Security Considerations
920
921 See the extended security considerations discussion in the framework
922 document [RFC4952].
923
9246. Acknowledgements
925
926 Much of the text in the initial version of this specification was
927 derived or copied from [Emailaddr] with the permission of the author.
928 Significant comments and suggestions were received from Xiaodong LEE,
929 Nai-Wen Hsu, Yangwoo KO, Yoshiro YONEYA, and other members of the JET
930 team and were incorporated into the specification. Additional
931 important comments and suggestions, and often specific text, were
932 contributed by many members of the WG and design team. Those
933 contributions include material from John C Klensin, Charles Lindsey,
934 Dave Crocker, Harald Tveit Alvestrand, Marcos Sanz, Chris Newman,
935 Martin Duerst, Edmon Chung, Tony Finch, Kari Hurtta, Randall Gellens,
936 Frank Ellermann, Alexey Melnikov, Pete Resnick, S. Moonesamy, Soobok
937 Lee, Shawn Steele, Alfred Hoenes, Miguel Garcia, Magnus Westerlund,
938 and Lars Eggert. Of course, none of the individuals are necessarily
939 responsible for the combination of ideas represented here.
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954Yao & Mao Experimental [Page 17]
955
956RFC 5336 EAI SMTP Extension September 2008
957
958
9597. References
960
9617.1. Normative References
962
963 [ASCII] American National Standards Institute (formerly United
964 States of America Standards Institute), "USA Code for
965 Information Interchange", ANSI X3.4-1968, 1968.
966
967 [RFC1652] Klensin, J., Freed, N., Rose, M., Stefferud, E., and D.
968 Crocker, "SMTP Service Extension for 8bit-
969 MIMEtransport", RFC 1652, July 1994.
970
971 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
972 Requirement Levels", BCP 14, RFC 2119, March 1997.
973
974 [RFC2821] Klensin, J., "Simple Mail Transfer Protocol", RFC 2821,
975 April 2001.
976
977 [RFC2822] Resnick, P., "Internet Message Format", RFC 2822,
978 April 2001.
979
980 [RFC3461] Moore, K., "Simple Mail Transfer Protocol (SMTP)
981 Service Extension for Delivery Status Notifications
982 (DSNs)", RFC 3461, January 2003.
983
984 [RFC3463] Vaudreuil, G., "Enhanced Mail System Status Codes",
985 RFC 3463, January 2003.
986
987 [RFC3464] Moore, K. and G. Vaudreuil, "An Extensible Message
988 Format for Delivery Status Notifications", RFC 3464,
989 January 2003.
990
991 [RFC3490] Faltstrom, P., Hoffman, P., and A. Costello,
992 "Internationalizing Domain Names in Applications
993 (IDNA)", RFC 3490, March 2003.
994
995 [RFC3629] Yergeau, F., "UTF-8, a transformation format of ISO
996 10646", STD 63, RFC 3629, November 2003.
997
998 [RFC4409] Gellens, R. and J. Klensin, "Message Submission for
999 Mail", RFC 4409, April 2006.
1000
1001 [RFC4952] Klensin, J. and Y. Ko, "Overview and Framework for
1002 Internationalized Email", RFC 4952, July 2007.
1003
1004 [RFC5234] Crocker, D. and P. Overell, "Augmented BNF for Syntax
1005 Specifications: ABNF", STD 68, RFC 5234, January 2008.
1006
1007
1008
1009
1010Yao & Mao Experimental [Page 18]
1011
1012RFC 5336 EAI SMTP Extension September 2008
1013
1014
1015 [RFC5248] Hansen, T. and J. Klensin, "A Registry for SMTP
1016 Enhanced Mail System Status Codes", BCP 138, RFC 5248,
1017 June 2008.
1018
1019 [RFC5335] Abel, Y., Ed., "Internationalized Email Headers",
1020 RFC 5335, September 2008.
1021
1022 [RFC5337] Newman, C. and A. Melnikov, Ed., "Internationalized
1023 Delivery Status and Disposition Notifications",
1024 RFC 5337, September 2008.
1025
10267.2. Informative References
1027
1028 [Downgrade] Fujiwara, K. and Y. Yoneya, "Downgrading mechanism for
1029 Email Address Internationalization", Work in Progress,
1030 July 2008.
1031
1032 [Emailaddr] Klensin, J., "Internationalization of Email Addresses",
1033 Work in Progress, July 2005.
1034
1035 [RFC0974] Partridge, C., "Mail routing and the domain system",
1036 RFC 974, January 1986.
1037
1038 [RFC2033] Myers, J., "Local Mail Transfer Protocol", RFC 2033,
1039 October 1996.
1040
1041 [RFC2821bis] Klensin, J., "Simple Mail Transfer Protocol", Work
1042 in Progress, July 2008.
1043
1044 [RFC3030] Vaudreuil, G., "SMTP Service Extensions for
1045 Transmission of Large and Binary MIME Messages",
1046 RFC 3030, December 2000.
1047
1048 [RFC3207] Hoffman, P., "SMTP Service Extension for Secure SMTP
1049 over Transport Layer Security", RFC 3207,
1050 February 2002.
1051
1052 [RFC4954] Siemborski, R., Ed. and A. Melnikov, Ed., "SMTP Service
1053 Extension for Authentication", RFC 4954, July 2007.
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066Yao & Mao Experimental [Page 19]
1067
1068RFC 5336 EAI SMTP Extension September 2008
1069
1070
1071Appendix A. Material Updating RFC 4952
1072
1073 RFC 4952, the overview and framework document covering this set of
1074 extensions for internationalized email, was completed before this
1075 specification, which specifies a particular part of the protocol set.
1076 This appendix, which is normative, contains material that would have
1077 been incorporated into RFC 4952 had it been delayed until the work
1078 described in the rest of this specification was completed. This
1079 material should be included in any update to RFC 4952.
1080
1081A.1. Conventional Message and Internationalized Message
1082
1083 o A conventional message is one that does not use any extension
1084 defined in this document or in the UTF-8 header specification
1085 [RFC5335], and which is strictly conformant to RFC 2822 [RFC2822].
1086
1087 o An internationalized message is a message utilizing one or more of
1088 the extensions defined in this specification or in the UTF-8
1089 header specification [RFC5335], so that it is no longer conformant
1090 to the RFC 2822 specification of a message.
1091
1092A.2. LMTP
1093
1094 LMTP [RFC2033] may be used as the final delivery agent. In such
1095 cases, LMTP may be arranged to deliver the mail to the mail store.
1096 The mail store may not have UTF8SMTP capability. LMTP needs to be
1097 updated to deal with these situations.
1098
1099A.3. SMTP Service Extension for DSNs
1100
1101 The existing Draft Standard regarding delivery status notifications
1102 (DSNs) [RFC3461] is limited to ASCII text in the machine readable
1103 portions of the protocol. "International Delivery Status and
1104 Disposition Notifications" [RFC5337] adds a new address type for
1105 international email addresses so an original recipient address with
1106 non-ASCII characters can be correctly preserved even after
1107 downgrading. If an SMTP server advertises both the UTF8SMTP and the
1108 DSN extension, that server MUST implement EAI DSN [RFC5337] including
1109 support for the ORCPT parameter.
1110
1111A.4. Implementation Advice
1112
1113 In the absence of this extension, SMTP clients and servers are
1114 constrained to using only those addresses permitted by RFC 2821. The
1115 local parts of those addresses MAY be made up of any ASCII
1116 characters, although some of them MUST be quoted as specified there.
1117 It is notable in an internationalization context that there is a long
1118 history on some systems of using overstruck ASCII characters (a
1119
1120
1121
1122Yao & Mao Experimental [Page 20]
1123
1124RFC 5336 EAI SMTP Extension September 2008
1125
1126
1127 character, a backspace, and another character) within a quoted string
1128 to approximate non-ASCII characters. This form of
1129 internationalization SHOULD be phased out as this extension becomes
1130 widely deployed, but backward-compatibility considerations require
1131 that it continue to be supported.
1132
1133A.5. Applicability of SMTP Extension to Additional Uses
1134
1135 Among other protocol changes, the SMTP extension allows an optional
1136 alternate address to be supplied with the MAIL and RCPT commands.
1137 For the purposes of this set of specifications, this alternate
1138 address only has meaning when the primary address contains UTF-8
1139 characters and the message is downgraded. While it may be tempting
1140 to consider the alternate address as a general-purpose second-chance
1141 address to be used whenever the primary address is rejected, such
1142 behavior is not defined here. This restriction allows for future
1143 extensions to be developed which create such a general-purpose
1144 second-chance address, although no specific work on such an extension
1145 is currently anticipated. Note that any such extension needs to
1146 consider the question of what the [RFC0974] sequencing rules mean
1147 when different possible servers support different sets of ESMTP
1148 options (or, in this case, addresses). The answer to this question
1149 may also imply updates to [RFC2821].
1150
1151Authors' Addresses
1152
1153 Jiankang YAO (editor)
1154 CNNIC
1155 No.4 South 4th Street, Zhongguancun
1156 Beijing
1157
1158 Phone: +86 10 58813007
1159 EMail: yaojk@cnnic.cn
1160
1161
1162 Wei MAO (editor)
1163 CNNIC
1164 No.4 South 4th Street, Zhongguancun
1165 Beijing
1166
1167 Phone: +86 10 58812230
1168 EMail: maowei_ietf@cnnic.cn
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178Yao & Mao Experimental [Page 21]
1179
1180RFC 5336 EAI SMTP Extension September 2008
1181
1182
1183Full Copyright Statement
1184
1185 Copyright (C) The IETF Trust (2008).
1186
1187 This document is subject to the rights, licenses and restrictions
1188 contained in BCP 78, and except as set forth therein, the authors
1189 retain all their rights.
1190
1191 This document and the information contained herein are provided on an
1192 "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
1193 OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND
1194 THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS
1195 OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF
1196 THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
1197 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
1198
1199Intellectual Property
1200
1201 The IETF takes no position regarding the validity or scope of any
1202 Intellectual Property Rights or other rights that might be claimed to
1203 pertain to the implementation or use of the technology described in
1204 this document or the extent to which any license under such rights
1205 might or might not be available; nor does it represent that it has
1206 made any independent effort to identify any such rights. Information
1207 on the procedures with respect to rights in RFC documents can be
1208 found in BCP 78 and BCP 79.
1209
1210 Copies of IPR disclosures made to the IETF Secretariat and any
1211 assurances of licenses to be made available, or the result of an
1212 attempt made to obtain a general license or permission for the use of
1213 such proprietary rights by implementers or users of this
1214 specification can be obtained from the IETF on-line IPR repository at
1215 http://www.ietf.org/ipr.
1216
1217 The IETF invites any interested party to bring to its attention any
1218 copyrights, patents or patent applications, or other proprietary
1219 rights that may cover technology that may be required to implement
1220 this standard. Please address the information to the IETF at
1221 ietf-ipr@ietf.org.
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234Yao & Mao Experimental [Page 22]
1235
1236