Thanks Ed,

I already had something similar checked in to CVS.

C

On Mon, 2002-02-04 at 06:39, Edward Fang wrote:
> 
> One of our users who is heavy into Debian Linux (Ben Collins - giving
> credit) found a problem where SA would start tagging Bad RFC822 header
> formatting into the headers if there was a tab/nospace in the Subject line.
> He changed the regex for it, and it looks like it works.  I'm submitting
> this to the list for others to test as well.   Not sure if the RFC specifies
> allowing \t's in the Subject line, but at least this prevents it from
> constantly mangling it.  It appears several lists insert them into Subj
> lines as well. . . 
> 
> Ed
> 
> In the file perl5/Mail/SpamAssassin/NoMailAudit.pm (whereever you
> installed this), you will find these lines (starting at around 118 in my
> file):
> 
>     } elsif (/^([^\x00-\x1f\x7f-\xff :]+): (.*)$/) {
>       $hdr = $1; $val = $2;
>       $val =~ s/\r+//gs;          # trim CRs, we don't want them
>       $entry = $self->_get_or_create_header_object ($hdr);
>       $entry->{original} = 1;
> 
>     } else {
>       $hdr = "X-Mail-Format-Warning";
>       $val = "Bad RFC822 header formatting in $_";
>       $entry = $self->_get_or_create_header_object ($hdr);
>       $entry->{added} = 1;
>     }
> 
> The regex in the first line is the problem. It expects a space after the
> first colon, which our header does not have. So change it to this regex:
> 
>       (/^([^\x00-\x1f\x7f-\xff :]+):[\t ]+(.*)$/)
> 
> This allows 1 or more spaces/tabs in front of the actual content. This
> is more correct, and I have even checked it out with some of our mail
> guru's.
> 
> 
> 
> _______________________________________________
> Spamassassin-talk mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/spamassassin-talk
> 
> 


_______________________________________________
Spamassassin-talk mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/spamassassin-talk

Reply via email to