I presume you restarted spamd, right?

{^_^}

On 2015-09-08 23:46, Marc Richter wrote:
Hi everyone,

I'm running SA 3.4.1 with Perl 5.22.0 .
It works quite well, but since a few weeks, it looks like my user_prefs isn't
taken into account by SA anymore. Let's show this by example:

There are *lots* of blacklist_from entries in there; one of them is:

blacklist_from          *@neuronation.*

Today, I got another mail with the following (relevant) headers:

X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on
     tango012.marc-richter.info
X-Spam-Level: ***
X-Spam-Status: No, score=3.6 required=4.0 tests=BAYES_99,BAYES_999,DKIM_SIGNED,
  DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,HTML_MESSAGE,
  RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,RP_MATCHES_RCVD,SPF_PASS,URIBL_BLOCKED
     autolearn=no autolearn_force=no version=3.4.1
From: NeuroNation <mai...@neuronation.de>
Date: Wed, 09 Sep 2015 06:05:02 +0000 (UTC)

Thus, this mail should get +100 for matching my blacklist_from entry. But, as
you can see, it isn't.

When I'm running "spamassassin --test-mode < my_maildir_file", I get expected
results:

spamassassin --test-mode < .maildir/cur/msg.SbGC\:2\,S

[...]
Inhaltsanalyse im Detail:   (99.9 Punkte, 3.0 ben�tigt)

Pkte Regelname              Beschreibung
---- ---------------------- --------------------------------------------------
  0.0 URIBL_BLOCKED          ADMINISTRATOR NOTICE: The query to URIBL was 
blocked.
                             See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
                              for more information.
                             [URIs: neuronation.de]
-0.0 RCVD_IN_MSPIKE_H3      RBL: Good reputation (+3)
                             [192.254.116.16 listed in wl.mailspike.net]
  100 USER_IN_BLACKLIST      From: address is in the user's black-list
  0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail
                             domains are different
-0.0 SPF_PASS               SPF: Senderechner entspricht SPF-Datensatz
  0.0 RP_MATCHES_RCVD        Envelope sender domain matches handover relay 
domain
  0.0 HTML_MESSAGE           BODY: Nachricht enth�lt HTML
-0.1 DKIM_VALID_AU          Message has a valid DKIM or DK signature from 
author's
                             domain
  0.1 DKIM_SIGNED            Message has a DKIM or DK signature, not necessarily
valid
-0.1 DKIM_VALID             Message has at least one valid DKIM or DK signature
-0.0 RCVD_IN_MSPIKE_WL      Mailspike good senders

SA is started by postfix; in the master.cf of postfix there are these lines:

smtp      inet  n    -    n    -    -    smtpd -o content_filter=spamassassin
spamassassin
     unix  -    n    n    -    -    pipe
     flags=Rq user=spamfilter argv=/home/spamfilter/filter.sh -oi -f ${sender}
${recipient}

/home/spamfilter/filter.sh contains:

#!/bin/sh
# filter.sh
#
# This script redirects mail flagged as spam to a separate account
# You must first create a user account named "spamvac" to hold the flagged mail
SENDMAIL="/usr/sbin/sendmail -i"
SPAMASSASSIN=/usr/bin/vendor_perl/spamc
COMMAND="$SENDMAIL $@"
USER=`echo $COMMAND | awk '{ print $NF }' | sed 's/@.*$//'`
NEW_COMMAND=`echo $COMMAND | awk '{ $6 = "spamfilter"; NF = 6; print }'`
# Exit codes from <sysexits.h>
EX_TEMPFAIL=75
EX_UNAVAILABLE=69
umask 077
OUTPUT="`mktemp /tmp/mailfilter.XXXXXXXXXX`"
if [ "$?" != 0 ]; then
         /usr/bin/logger -s -p mail.warning -t filter "Unable to create
temporary file."
         exit $EX_TEMPFAIL
fi
# Clean up when done or when aborting.
trap "rm -f $OUTPUT" EXIT SIGTERM
$SPAMASSASSIN -x -E -u $USER > $OUTPUT
return="$?"
if [ "$return" == 1 ]; then
         $NEW_COMMAND < $OUTPUT
         exit $?
elif [ "$return" != 0 ]; then
         /usr/bin/logger -s -p mail.warning -t filter "Temporary SpamAssassin
failure (spamc return $return)"
         exit $EX_TEMPFAIL
fi
$SENDMAIL "$@" < $OUTPUT
exit $?

SA should have access to my user_prefs; these are the groups for the user
"spamfilter":
tango012 ~ # groups spamfilter
users spamd
tango012 ~ #

The full path-permission to my user_prefs are:
ww@tango012 ~ $ ls -ld /home /home/Whitewolf_Fox
/home/Whitewolf_Fox/.spamassassin /home/Whitewolf_Fox/.spamassassin/user_prefs
drwxr-xr-x 13 root root  4096 23. Jul 10:36 /home
drwxr-xr-x 27 ww   users 4096  9. Sep 08:32 /home/Whitewolf_Fox
drwxrwx---  2 ww   spamd 4096  9. Sep 08:32 /home/Whitewolf_Fox/.spamassassin
-rw-rw----  1 ww   spamd 8622  4. Sep 15:15
/home/Whitewolf_Fox/.spamassassin/user_prefs
ww@tango012 ~ $

Standing here, I'm out of ideas, since this looks all good to me.

Can somebody imagine what's wrong here?

Best regards,
Marc

Reply via email to