mailscanner/spamassassin strangeness

Julian Field jkf at ecs.soton.ac.uk
Wed Jan 30 14:03:07 GMT 2002


At 13:46 30/01/2002, you wrote:
>after some comparing of stand-alone spamassassin to mailscanner+spamassassin
>and digging into spamassassin- and mailscanner-code I found that the
>email-data within mailscanner are handed over to spamassassin with their
>line-endings cut off, which gives a different input to spamassassin as with
>using stdin.
>
>Changing this in sendmail.pl puts away with the spam-hit-differences, at
>least for my host. I don't know if this is a perl-issue, since I am
>running 5.005;
>maybe in 5.6 the data are handled in a different way?

Well done! I've been trying to solve this one for ages, never got anywhere.
I'm trying out your suggested change now, it certainly doesn't seem to do
any harm...

BTW You did the diff the wrong way round. What he's doing here is to
comment out the 2 lines that say "chomp" and change the "" to "\n" in the
push() statement in the middle.

This change will get rolled into the next release unless I hear anything
bad about it.

>The changes in sendmail.pl are these:
>
>*** sendmail.pl Wed Jan 30 14:36:26 2002
>--- sendmail.pl.orig Mon Jan 28 13:46:10 2002
>***************
>*** 230,240 ****
>     return 0 unless $H;
>     foreach $_ (@$H) {
>! #    chomp;
>       push(@WholeMessage, $_);
>     }
>!   push(@WholeMessage, "\n");
>     open(DF, $dfilename) or return 0;
>     while(<DF>) {
>! #    chomp;
>       push(@WholeMessage, $_);
>     }
>--- 230,240 ----
>     return 0 unless $H;
>     foreach $_ (@$H) {
>!     chomp;
>       push(@WholeMessage, $_);
>     }
>!   push(@WholeMessage, "");
>     open(DF, $dfilename) or return 0;
>     while(<DF>) {
>!     chomp;
>       push(@WholeMessage, $_);
>     }
>
>Andreas
>
>________________________________________________________________________
>Dr. Andreas Piper, Hochschulrechenzentrum der Philipps-Univ. Marburg
>           Hans-Meerwein-Strasse, 35032 Marburg, Germany
>Phone: +49 6421 28-23521  Fax: -26994  Email: piper at HRZ.Uni-Marburg.DE

--
Julian Field                Teaching Systems Manager
jkf at ecs.soton.ac.uk         Dept. of Electronics & Computer Science
Tel. 023 8059 2817          University of Southampton
                             Southampton SO17 1BJ



More information about the MailScanner mailing list