http://bugzilla.spamassassin.org/show_bug.cgi?id=4108

           Summary: Missing Mail::SpamAssassin leads to mail corruption
           Product: Spamassassin
           Version: 3.0.2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P5
         Component: spamassassin
        AssignedTo: [email protected]
        ReportedBy: [EMAIL PROTECTED]


If the "spamassassin" executable is installed, but the Mail::SpamAssassin libs
are not, the resulting crash may lead to mail corruption in procmail
installations.  This is a rare case, but it is (fairly) easy to work around.

Steps to reproduce (a little too specific, but I hope you get the point):
 1) Install Mail::SpamAssassin under Perl 5.6.1
    (i.e. Mail::SpamAssassin goes in /usr/lib/perl5/site_perl/5.6.1)
 2) add 
      :0fw
      | /usr/bin/spamassassin
    to ~/.procmailrc
 3) upgrade Perl to 5.8.6, including /usr/bin/perl

Actual results:
 /usr/bin/spamassassin crashes because Mail::SpamAssassin can't be found in
/usr/lib/perl5/site_perl/5.8.6, mail gets corrupted

Expected results:
 /usr/bin/spamassassin detects a failure and returns the unaltered email

Proposed fix:
 Wrap the body of /usr/bin/spamassassin in something like the following (with
appropriate handling if STDIN has already been read):

eval {
  use Mail::SpamAssassin;
  ...
}
if ($@) {
  print <STDIN>;
}



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

Reply via email to