[Postfixbuch-users] Reject bei Procmail
Andreas Winkelmann
ml at awinkelmann.de
Sa Jan 28 16:46:51 CET 2006
Am Friday 27 January 2006 12:49 schrieb Sebastian Deiszner:
> meine .procmailrc sieht folgendermaßen aus:
>
> DROPPRIVS=yes
>
> :0fw: spamassassin.lock
>
> * < 256000
>
> | spamassassin -u bauer
> |
> :0:
>
> * ^X-Spam-Status: Yes
> ! spamkonto at localhost
>
>
> Wie könnte ich Mail rejecten (ob es sinnvoll ist oder nicht ist hierbei
> erstmal irrelevant) anstatt sie auf das Spamkonto weiterzuleiten.
Setz in Procmail einen entsprechenden Rückgabewert. Siehe "EXITCODE" z.B. in
"man procmailrc". Setz einen Wert, den Postfix handelt wie Du es willst.
src/global/sys_exits.c:
EX_USAGE, "5.3.0", "command line usage error",
EX_DATAERR, "5.6.0", "data format error",
EX_NOINPUT, "5.3.0", "cannot open input",
EX_NOUSER, "5.1.1", "user unknown",
EX_NOHOST, "5.1.2", "host name unknown",
EX_UNAVAILABLE, "5.3.0", "service unavailable",
EX_SOFTWARE, "5.3.0", "internal software error",
EX_OSERR, "4.3.0", "system resource problem",
EX_OSFILE, "5.3.0", "critical OS file missing",
EX_CANTCREAT, "5.2.0", "can't create user output file",
EX_IOERR, "5.3.0", "input/output error",
EX_TEMPFAIL, "4.3.0", "temporary failure",
EX_PROTOCOL, "5.5.0", "remote error in protocol",
EX_NOPERM, "5.7.0", "permission denied",
EX_CONFIG, "5.3.5", "local configuration error",
Die Zahlen dazu (/usr/include/sysexits.h):
#define EX_USAGE 64 /* command line usage error */
#define EX_DATAERR 65 /* data format error */
#define EX_NOINPUT 66 /* cannot open input */
#define EX_NOUSER 67 /* addressee unknown */
#define EX_NOHOST 68 /* host name unknown */
#define EX_UNAVAILABLE 69 /* service unavailable */
#define EX_SOFTWARE 70 /* internal software error */
#define EX_OSERR 71 /* system error (e.g., can't fork) */
#define EX_OSFILE 72 /* critical OS file missing */
#define EX_CANTCREAT 73 /* can't create (user) output file */
#define EX_IOERR 74 /* input/output error */
#define EX_TEMPFAIL 75 /* temp failure; user is invited to retry */
#define EX_PROTOCOL 76 /* remote error in protocol */
#define EX_NOPERM 77 /* permission denied */
#define EX_CONFIG 78 /* configuration error */
--
Andreas
Mehr Informationen über die Mailingliste Postfixbuch-users