Return-Path: Delivered-To: apmail-spamassassin-commits-archive@www.apache.org Received: (qmail 87045 invoked from network); 29 Sep 2004 14:02:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 29 Sep 2004 14:02:10 -0000 Received: (qmail 20099 invoked by uid 500); 29 Sep 2004 14:02:10 -0000 Delivered-To: apmail-spamassassin-commits-archive@spamassassin.apache.org Received: (qmail 20053 invoked by uid 500); 29 Sep 2004 14:02:10 -0000 Mailing-List: contact commits-help@spamassassin.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: "Spam Assassin Dev" List-Id: Delivered-To: mailing list commits@spamassassin.apache.org Received: (qmail 20040 invoked by uid 99); 29 Sep 2004 14:02:10 -0000 X-ASF-Spam-Status: No, hits=-10.0 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.28) with SMTP; Wed, 29 Sep 2004 07:02:09 -0700 Received: (qmail 86974 invoked by uid 65534); 29 Sep 2004 14:02:08 -0000 Date: 29 Sep 2004 14:02:08 -0000 Message-ID: <20040929140208.86966.qmail@minotaur.apache.org> From: felicity@apache.org To: commits@spamassassin.apache.org Subject: svn commit: rev 47485 - spamassassin/branches/3.0/lib/Mail/SpamAssassin X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Author: felicity Date: Wed Sep 29 07:02:07 2004 New Revision: 47485 Modified: spamassassin/branches/3.0/lib/Mail/SpamAssassin/Conf.pm Log: bug 3825: document that # characters must be escaped in RE, or else they're considered the start of a comment Modified: spamassassin/branches/3.0/lib/Mail/SpamAssassin/Conf.pm ============================================================================== --- spamassassin/branches/3.0/lib/Mail/SpamAssassin/Conf.pm (original) +++ spamassassin/branches/3.0/lib/Mail/SpamAssassin/Conf.pm Wed Sep 29 07:02:07 2004 @@ -41,6 +41,9 @@ directories. The C<#> character starts a comment, which continues until end of line. +B using the C<#> character in the regular expression rules requires +escaping. i.e.: C<\#> + Whitespace in the files is not significant, but please note that starting a line with whitespace is deprecated, as we reserve its use for multi-line rule definitions, at some point in the future. @@ -2069,7 +2072,9 @@ C is either C<=~> (contains regular expression) or C (does not contain regular expression), and C is a valid Perl regular expression, with C as regexp modifiers in the usual style. Note that multi-line -rules are not supported, even if you use C as a modifier. +rules are not supported, even if you use C as a modifier. Also note that +the C<#> character must be escaped (C<\#>) or else it will be considered to be +the start of a comment and not part of the regexp. If the C<[if-unset: STRING]> tag is present, then C will be used if the header is not found in the mail message. @@ -2213,7 +2218,9 @@ =item body SYMBOLIC_TEST_NAME /pattern/modifiers -Define a body pattern test. C is a Perl regular expression. +Define a body pattern test. C is a Perl regular expression. Note: +as per the header tests, C<#> must be escaped (C<\#>) or else it is considered +the beginning of a comment. The 'body' in this case is the textual parts of the message body; any non-text MIME parts are stripped, and the message decoded from @@ -2245,7 +2252,9 @@ =item uri SYMBOLIC_TEST_NAME /pattern/modifiers -Define a uri pattern test. C is a Perl regular expression. +Define a uri pattern test. C is a Perl regular expression. Note: as +per the header tests, C<#> must be escaped (C<\#>) or else it is considered +the beginning of a comment. The 'uri' in this case is a list of all the URIs in the body of the email, and the test will be run on each and every one of those URIs, adjusting the @@ -2272,6 +2281,8 @@ =item rawbody SYMBOLIC_TEST_NAME /pattern/modifiers Define a raw-body pattern test. C is a Perl regular expression. +Note: as per the header tests, C<#> must be escaped (C<\#>) or else it is +considered the beginning of a comment. The 'raw body' of a message is the raw data inside all textual parts. The text will be decoded from base64 or quoted-printable encoding, @@ -2301,6 +2312,8 @@ =item full SYMBOLIC_TEST_NAME /pattern/modifiers Define a full message pattern test. C is a Perl regular expression. +Note: as per the header tests, C<#> must be escaped (C<\#>) or else it is +considered the beginning of a comment. The full message is the pristine message headers plus the pristine message body, including all MIME data such as images, other attachments, MIME