水無月ばけらのえび日記

bakera.jp > 水無月ばけらのえび日記 > RFC2821 と RFC2822

RFC2821 と RFC2822

2004年10月29日(金曜日)

RFC2821 と RFC2822

メールアドレスの仕様については RFC2821RFC2822 の両方に記述があるのですが、どの記述がどちらにあるのか良く混同します。

長さの定義は RFC2821

local-part

The maximum total length of a user name or other local-part is 64 characters.

domain

The maximum total length of a domain name or number is 255 characters.

以上、RFC2821 4.5.3.1 Size limits and minimums より

使える文字の定義は RFC2822

atext = ALPHA / DIGIT / ; Any character except controls,

"!" / "#" / ; SP, and specials.

"$" / "%" / ; Used for atoms

"&" / "'" /

"*" / "+" /

"-" / "/" /

"=" / "?" /

"^" / "_" /

"`" / "{" /

"|" / "}" /

"~"

以上、RFC2822 3.2.4. Atom より

……ということで。

local-part には意外な記号が使えることになっているので注意。

関連する話題: RFC / メール

最近の日記

関わった本など