Article View: news.software.nntp
Article #86461Re: Non-standard 'From' fields
From: Julien ÉLIE
Date: Thu, 26 Mar 2015 18:31
Date: Thu, 26 Mar 2015 18:31
76 lines
4519 bytes
4519 bytes
Hi Tim,
>>> Is there a formal definition of it anywhere, to enable me to create a
>>> robust parser to detect and handle it?
>
> I had missed that reference in RFC1036.
I also suggest to have a look at RFC1849, also called "Son of 1036".
Though it does not explain the origin of the syntax, it gives you a hint
to detect the address:
5.2. From
NOTE: The syntax here is a restricted subset of the MAIL From
syntax, with quoting particularly restricted, for simple parsing.
In particular, the presence of "<" in the From content indicates
that the second form is being used; otherwise, the first form is
being used. The major restrictions here are those already de
facto imposed by existing software.
NOTE: Overly lenient posting agents sometimes permit the second
form with a full name containing "(" or ")", but it is extremely
rare for a full name to contain "<" or ">", even in mail.
Accordingly, reading agents wishing to robustly determine which
form is in use in a particular article should key on the presence
or absence of "<", not the presence or absence of "(".
Other interesting parts:
From-content = address [ space "(" paren-phrase ")" ]
/ [ plain-phrase space ] "<" address ">"
The full name is
distinguished from the electronic address either by enclosing the
former in parentheses (making it resemble a MAIL comment, after the
address) or by enclosing the latter in angle brackets. The second
form is preferred. In the first form, encoded words inside the full
name MUST be composed entirely of <paren-char>s. In the second form,
encoded words inside the full name may not contain characters other
than letters (of either case), digits, and the characters "!", "*",
"+", "-", "/", "=", and "_". The local part is case-sensitive
(except that all case counterparts of "postmaster" are deemed
equivalent), the domain is case-insensitive, and all other parts of
the From content are comments that MUST be ignored by news software
(except insofar as reading agents may wish to display them to the
reader). Posters and posting agents MUST restrict themselves to this
subset of the MAIL From syntax; relayers MAY accept a broader subset,
but see the discussion in Section 9.1.
You will also find a documentation of a very obsolete form of this header:
A.2. Early "B News" Article Format
This obsolete pseudo-Internet article format, used briefly during the
transition between the A News format and the modern format, followed
the general outline of a MAIL message but with some non-standard
headers. For example:
From: cbosgd!mhuxj!mhuxt!eagle!jerry (Jerry Schwarz)
The From header contained the information now found in the Path
header, plus possibly the full name now typically found in the From
header.
--
Julien ÉLIE
« Mais dis à ton ami qu'il cesse de jeter notre argent par les
écoutilles ! » (Astérix)
Technical Details
Message-ID:
<mf1jag$9nq$1@news.trigofacile.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20150601.mbox.gz!border1.nntp.dca1.giganews.com!nntp.giganews.com!goblin2!goblin.stu.neva.ru!weretis.net!feeder4.news.weretis.net!news.trigofacile.com!.POSTED.aaubervilliers-651-1-281-72.w83-114.abo.wanadoo.fr!not-for-mailReferences:
<ukdvda99imjm7ba0j7o4u8hem7e8p79nbr@4ax.com> <8761b42f4o.fsf@hope.eyrie.org> <r5r0ea9bdrndondbalfnvr18v6s84u1kpu@4ax.com>Show Full Headers
Complete Article Headers
Message-ID: <mf1jag$9nq$1@news.trigofacile.com> Subject: Re: Non-standard 'From' fields Date: Thu, 26 Mar 2015 19:31:44 +0100 From: Julien ÉLIE <iulius@nom-de-mon-site.com.invalid> References: <ukdvda99imjm7ba0j7o4u8hem7e8p79nbr@4ax.com> <8761b42f4o.fsf@hope.eyrie.org> <r5r0ea9bdrndondbalfnvr18v6s84u1kpu@4ax.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20150601.mbox.gz!border1.nntp.dca1.giganews.com!nntp.giganews.com!goblin2!goblin.stu.neva.ru!weretis.net!feeder4.news.weretis.net!news.trigofacile.com!.POSTED.aaubervilliers-651-1-281-72.w83-114.abo.wanadoo.fr!not-for-mail Newsgroups: news.software.nntp Organization: TrigoFACILE -- http://www.trigofacile.com/ Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit Injection-Date: Thu, 26 Mar 2015 18:31:44 +0000 (UTC) Injection-Info: news.trigofacile.com; posting-account="julien"; posting-host="aaubervilliers-651-1-281-72.w83-114.abo.wanadoo.fr:83.114.80.72"; logging-data="9978"; mail-complaints-to="abuse@trigofacile.com" User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; In-Reply-To: <r5r0ea9bdrndondbalfnvr18v6s84u1kpu@4ax.com> Lines: 75