From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/49894 Path: main.gmane.org!not-for-mail From: kai.grossjohann@uni-duisburg.de (Kai =?iso-8859-1?q?Gro=DFjohann?=) Newsgroups: gmane.emacs.gnus.general Subject: Re: road warrior trying to simplify a mail setup Date: Fri, 07 Feb 2003 16:52:49 +0100 Organization: University of Duisburg, Germany Sender: owner-ding@hpc.uh.edu Message-ID: <84adh86qb2.fsf@lucy.is.informatik.uni-duisburg.de> References: <86fzr2ek0j.fsf@red.stonehenge.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1044633137 5927 80.91.224.249 (7 Feb 2003 15:52:17 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Fri, 7 Feb 2003 15:52:17 +0000 (UTC) Return-path: Original-Received: from malifon.math.uh.edu ([129.7.128.13]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18hAnD-0001Vt-00 for ; Fri, 07 Feb 2003 16:51:55 +0100 Original-Received: from sina.hpc.uh.edu ([129.7.128.10] ident=lists) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 18hAol-00087S-00; Fri, 07 Feb 2003 09:53:31 -0600 Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Fri, 07 Feb 2003 09:54:27 -0600 (CST) Original-Received: from sclp3.sclp.com (sclp3.sclp.com [66.230.238.2]) by sina.hpc.uh.edu (8.9.3/8.9.3) with SMTP id JAA22173 for ; Fri, 7 Feb 2003 09:54:13 -0600 (CST) Original-Received: (qmail 53324 invoked by alias); 7 Feb 2003 15:53:12 -0000 Original-Received: (qmail 53319 invoked from network); 7 Feb 2003 15:53:12 -0000 Original-Received: from quimby.gnus.org (80.91.224.244) by 66.230.238.6 with SMTP; 7 Feb 2003 15:53:12 -0000 Original-Received: from news by quimby.gnus.org with local (Exim 3.12 #1 (Debian)) id 18hAw2-0005qY-00 for ; Fri, 07 Feb 2003 17:01:02 +0100 Original-To: ding@gnus.org Original-Path: not-for-mail Original-Newsgroups: gnus.ding Original-Lines: 59 Original-NNTP-Posting-Host: pd951f1c2.dip.t-dialin.net Original-X-Trace: quimby.gnus.org 1044633662 21853 217.81.241.194 (7 Feb 2003 16:01:02 GMT) Original-X-Complaints-To: usenet@quimby.gnus.org Original-NNTP-Posting-Date: 7 Feb 2003 16:01:02 GMT User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.3.50 (i686-pc-linux-gnu) Cancel-Lock: sha1:PC3FLhXfaeEIUZZro0CBU1Q/JKA= Precedence: list X-Majordomo: 1.94.jlt7 Xref: main.gmane.org gmane.emacs.gnus.general:49894 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:49894 Michel Schinz writes: > The major one is mail splitting. Gnus, Mail.app and IMP all have ways > to sort mail, but of course they are not compatible. Which means that > you either have to install an IMAP server with server-side splitting, > or have to find another way. I didn't experiment with server-side > splitting, but I fear that the solutions available now (i.e. SIEVE) > are not powerful enough to filter SPAM using external tools > (SpamAssassin or whatever). I'm not a SpamAssassin poweruser (in fact, I just installed it and then forgot about it until a few seconds ago), but my setup works nicely with this: incoming mail is passed by Postfix through SA, before ending up in the Cyrus server. There, Sieve can be used to split based on the headers added by SA. I didn't know what I was doing, so I'm rather surprised it works. In /etc/postfix/master.cf, augment the smtp line as follows: smtp inet n - - - - smtpd -o content_filter=filter: And also add a filter line (okay, two lines), like this: filter unix - n n - - pipe flags=Rq user=spamassassin argv=/etc/postfix/spamassassin.sh -f ${sender} -- ${recipient} Hm. I'm not sure if the script does the right thing. It seems it should just frob the headers and dump the message to standard out. But it invokes sendmail. Hm. I got the script from some readme or other, or maybe from the web: #!/bin/sh INSPECT_DIR=/var/spool/spamassassin SENDMAIL="/usr/sbin/sendmail -i" # Exit codes (snarfed from sysexists.h) EX_TEMPFAIL=75 EX_UNAVAILABLE=69 # Clean up when done or when aborting. trap "rm -f in.$$ out.$$" 0 1 2 3 15 # Start processing. cd $INSPECT_DIR || { echo $INSPECT_DIR does not exist; exit $EX_TEMPFAIL; } cat >in.$$ || { echo Cannot save mail to file; exit $EX_TEMPFAIL; } #( echo "X-Filtered: yes" ; cat in.$$ ) > out.$$ || \ # { echo Filter failure; exit $EX_UNAVAILABLE; } /usr/bin/spamc -f out.$$ || \ { echo Message content rejected; exit $EX_UNAVAILABLE; } $SENDMAIL "$@"