Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/parser.php on line
66
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
292
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
22
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
44
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
208
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
236
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
290
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
323
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/handler.php on line
560
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Function split() is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/lexer.php on line
510
Deprecated: Assigning the return value of new by reference is deprecated in
/home/www/web535/html/dokuwiki/inc/parser/xhtml.php on line
980
Ein kleines HowTo wie man eine Mail Server für Spamassassin configuriert.
Diese HowTo bezieht sich auf Debian testing etch (4.0-pre)
mit:
Achtung: Diesese Beispiele beziehen sich auf meine Server, und müssen eventuell angepasst werden
SpamAssassin Installieren
unter Debian reicht ein
apt-get install spamassassin
als root eine Datei /usr/bin/postfixfilter mit dem folgendem Inhalt erstellen
#!/bin/bash
/usr/bin/spamc | /usr/sbin/sendmail -i "$@"
exit $?
Rechte auf ausführbar setzen
chmod 755 /usr/bin/postfixfilter
einen Benutzer “spamfilter” mit loginshell und home verzeichnis anlegen (mit adduser zB)
In /etc/postfix/master.cf in der Section “Services” folgendes einfügen (-o in neuer Zeile !)
# -----------------------------------------------------------------------------------
smtp inet n - n - - smtpd
-o content_filter=spamfilter:
# -----------------------------------------------------------------------------------
wieder in /etc/postfix/master.cf in der Section “Interfaces to non-Postfix software” hinzufügen
# -----------------------------------------------------------------------------------
spamfilter unix - n n - - pipe
flags=Rq user=spamfilter argv=/usr/bin/postfixfilter -f ${sender} -- ${recipient}
# -----------------------------------------------------------------------------------
postfix neu starten und kontrollieren ob der mailemfang immernoch funktiniert
Globals Spamfiltern sollte nun schon Funktionieren!
Aller spamm wird jetzt Markiert. Für die weitere configuration vom spamassassin die Seite http://www.spamassassin.org besuchen.
Möchte man nun das die als Spam Markierten mails aussortiert werden hier fortfahren.
wenn noch nicht installiert, procmail installieren
Für jeden User dessen Mails gefiltert werden sollen eine Datei ~/.procmail erstellen
Die Mails werden im Maildir Format abgelegt und spam wird in den unterordner junk-mail sortiert. Am besten verwendet man ab jetzt IMAP um die mails abzurufen, das unter umständen der Ordner junk-mail vom POP3 nicht berücksichtigt wird.
Auch muss man unter Mozilla das Verzeichnis explizit Abonieren um diese Mails zu erhalten.
# -----------------------------------------------------------------------------------
#VERBOSE=yes
#LOGABSTRACT=all
# add to see more logging
#
#MAILDIR=$HOME/Mail
#PROCMAILDIR=$HOME/.Procmail
MAILDIR=$HOME/Maildir/
DEFAULT=$HOME/Maildir/
LOGFILE=$HOME/Maildir/proc.log
# Catch SPAM
# :0
# * ^X-Spam-Flag: YES
# * ^X-Spam-Level: \*\*\*\*\*\*
# $MAILDIR/.junk-mail/
# add to catch spam in an extra folder
# it has to be "abonomentet" if youll see the spam
# not usabele with pop3!!
# bernd http://berndlux.de 2006.12.05
# # -----------------------------------------------------------------------------------
Explanation of the above -
MAILDIR is the location of mailbox folders
DEFAULT is the default mailbox.
“* ^X-Spam-Flag: YES” makes sure the email is marked as spam before doing anything with it.
“* ^X-Spam-Level: \*\*\*\*\*\*” make sure the spam received a ‘spam score’ of at least 6 before doing anything with it. This ensures that ‘borderline’ cases that are more likely to be ‘false positives’ (meaning they have been falsely marked as spam) do not go into the spam mailbox.
‘junk-mail’ is the name of the mailbox they are going into.
Create a file in their home directory, owned by them, called ‘.forward’. Enter the following into it, changing eventually ‘$USER’ to their username. Include the quotes and the pound (”#”) symbol!
"|IFS=' ' && exec /usr/bin/procmail || exit 75 #$USER"
eventuell beide Dateien nach /etc/skel/ kopieren, so werden diese beim erstellen neuer Benutzer gleich in deren Home Verzeichnisse kopiert.