Re: I-D ACTION:draft-ietf-sieve-variables-04.txt

Philip Guenther <guenther+mtafilters@sendmail.com> Mon, 25 July 2005 20:42 UTC

Received: from above.proper.com (localhost.vpnc.org [127.0.0.1]) by above.proper.com (8.12.11/8.12.9) with ESMTP id j6PKgCIe069742; Mon, 25 Jul 2005 13:42:12 -0700 (PDT) (envelope-from owner-ietf-mta-filters@mail.imc.org)
Received: (from majordom@localhost) by above.proper.com (8.12.11/8.12.9/Submit) id j6PKgCsS069741; Mon, 25 Jul 2005 13:42:12 -0700 (PDT)
X-Authentication-Warning: above.proper.com: majordom set sender to owner-ietf-mta-filters@mail.imc.org using -f
Received: from foon.sendmail.com (tls.sendmail.com [209.246.26.40]) by above.proper.com (8.12.11/8.12.9) with ESMTP id j6PKgCBi069735 for <ietf-mta-filters@imc.org>; Mon, 25 Jul 2005 13:42:12 -0700 (PDT) (envelope-from guenther@sendmail.com)
Received: from lab.smi.sendmail.com ([10.210.100.93]) by foon.sendmail.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id j6PKgBVb030558 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Mon, 25 Jul 2005 13:42:12 -0700
X-DomainKeys: Sendmail DomainKeys Filter v0.2.7 foon.sendmail.com j6PKgBVb030558
DomainKey-Signature: a=rsa-sha1; s=tls; d=sendmail.com; c=nofws; q=dns; b=AhMFXJrzSRfPdv8nwvtspwvLPJgzpwZw+HoKso5npkj+CfXrpyHdx19GQbvqfFCWZ F+TdwaYhb+t3EwliyPv+ZUEYcfYLxHWS8xoCP9HyQeURs978sG+sMhusUL9+pGPMz6W QZixqwQcb2QQyE2PkGUzOOVx9kxrfo+HYxFWsDA=
Received: from lab.smi.sendmail.com (localhost [127.0.0.1]) by lab.smi.sendmail.com (8.13.3/8.13.3) with ESMTP id j6PKgBuX083301; Mon, 25 Jul 2005 13:42:11 -0700 (PDT) (envelope-from guenther@lab.smi.sendmail.com)
Message-Id: <200507252042.j6PKgBuX083301@lab.smi.sendmail.com>
To: "Mark E. Mallett" <mem@mv.mv.com>
Cc: ietf-mta-filters@imc.org
From: Philip Guenther <guenther+mtafilters@sendmail.com>
Subject: Re: I-D ACTION:draft-ietf-sieve-variables-04.txt
In-reply-to: <20050725193745.GB5041@osmium.mv.net>
References: <E1DtRVp-0002k4-CW@newodin.ietf.org> <1121522976.8017.6.camel@chico.njus.no> <01LQUHIQ7UJA000092@mauve.mrochek.com> <1121886910.30434.93.camel@chico.njus.no> <200507202154.j6KLsoeW043863@lab.smi.sendmail.com> <1121898525.30434.122.camel@chico.njus.no> <20050725193745.GB5041@osmium.mv.net>
Date: Mon, 25 Jul 2005 13:42:11 -0700
Sender: owner-ietf-mta-filters@mail.imc.org
Precedence: bulk
List-Archive: <http://www.imc.org/ietf-mta-filters/mail-archive/>
List-ID: <ietf-mta-filters.imc.org>
List-Unsubscribe: <mailto:ietf-mta-filters-request@imc.org?body=unsubscribe>

"Mark E. Mallett" <mem@mv.mv.com> writes:
>On Thu, Jul 21, 2005 at 12:28:45AM +0200, Kjetil Torgrim Homme wrote:
>> Modifier ":quoteregex"
>> 
>>         Every character with special meaning for :regex (".", "*", "?"
>>         etc.) is prefixed with "\" in the expansion.  This modifier is
>>         only available when the "regex" extension is in effect.
>
>Do we want to more specifically say something like "Ensures that "
>[ ...every character with special meaning is prefixed with "\" ... ],
>i.e. if a character is already quoted, we don't want another quote
>character to be added (otherwise the quoted character would become
>unquoted, a literal quote character would be added, etc).

No!  :quotewildcard/:quoteregex must escape any backslash characters
that are already present so that the resulting pattern or regexp
will match them literally.  For example, the wildcard pattern for
matching the literal text
	foo\*bar
is
	foo\\\*bar
and _not_
	foo\*bar


Ergo, something like
	set :quotawildcard "b" text:
	foo\*bar
	.
must have the same result as
	set "b" text:
	foo\\\*bar
	.

(I used a multiline literal to avoid confusing the issue with the
extra round of backslash escaping that quoted-strings under go.)


Philip Guenther