Re: Re: Quoted pairs in the test suite

"Stuart D. Gathman" <[email protected]> Mon, 14 Apr 2008 17:59:50 -0400 (EDT)
Newsgroups gmane.mail.spam.spf.devel
Message-ID <[email protected]>
On Mon, 14 Apr 2008, Frank Ellermann wrote:

> Julian Mehnle wrote:
> 
> > SPF implementations aren't supposed to perform quote removal
> > in e-mail addresses or localparts.
> 
> I don't believe it, we discussed this for months here, it was
> you who said that ".do..ts." degenerate into .do..ts. and hit
> the res_mkquery() wall.

I think Julian is forgetting about the use of %{l} in exists
queries, and similar things.  You are correct that handling of
quoted localpart needs to be consistent for %{l} to work with
such queries and a quoted localpart.

You could argue that a sender (who controls valid localparts) should
avoid such quoted localparts to avoid any inconsistencies in
receivers.  However, it *is* our job to specify the correct behaviour
in the test suite - provided the spec is unambiguous (however obscure).

I will admit that I am still trying to figure out what the required
behaviour should be.  Which is why I asked.  

I think you are saying that all quoting should be completely removed for %{l}
so as to have a consistent DNS label regardless of how the sender (redundantly)
quoted the localpart.  It doesn't matter if %{l}@%{o} is a valid email anymore.

But what about %{s}?  Should that preserve quoting so as to remain a valid
email?  I am assuming that %{s} would never be used as an actual DNS label.
But maybe I'm wrong.  The spec says, "The 's' macro expands to the <sender>
argument. It is an E-Mail address ...", which says to me that it should
remain a valid email address and preserve quoting.

It is possible that you have uncovered yet another errata (fortunately
just another obscure corner case).

I think we are missing a test case to ensure that %{o} (and %{s}) stays
unchanged across recursive queries.

-- 
	      Stuart D. Gathman <[email protected]>
    Business Management Systems Inc.  Phone: 703 591-0911 Fax: 703 591-6154
"Confutatis maledictis, flammis acribus addictis" - background song for
a Microsoft sponsored "Where do you want to go from here?" commercial.