Difference between revisions of "Spamassassin"
From Atomicorp Wiki
Line 1: | Line 1: | ||
− | + | ||
+ | == General Improvements == | ||
+ | |||
Add razor, dcc and pyzor | Add razor, dcc and pyzor | ||
Line 13: | Line 15: | ||
− | + | == Force spamassassin to scan messages from localhost, when using qmail-scanner == | |
+ | |||
vi /etc/xinetd.d/smtp_psa | vi /etc/xinetd.d/smtp_psa | ||
Line 30: | Line 33: | ||
− | + | == Mysql settings for whitelisting == | |
− | |||
− | |||
− | |||
− | |||
− | + | '''INSERT INTO userpref (username,preference,value) VALUES ('%tsginc.com','whitelist_from','*domain.com');''' | |
− | '''INSERT INTO userpref (username,preference,value) VALUES ('%tsginc.com','whitelist_from','* | + | '''INSERT INTO userpref (username,preference,value) VALUES ('%tsginc.com','whitelist_from','*@domain.com');''' |
− | '''INSERT INTO userpref (username,preference,value) VALUES ('%tsginc.com','whitelist_from','*@ | + | |
+ | |||
+ | |||
+ | == Limiting Load == | ||
+ | |||
+ | Add max_load to /etc/xinetd.d/smtp_psa. SMTP will throttle connections when load reaches a certain point. | ||
+ | |||
+ | service smtp | ||
+ | { | ||
+ | socket_type = stream | ||
+ | protocol = tcp | ||
+ | wait = no | ||
+ | disable = no | ||
+ | user = root | ||
+ | max_load = 5 | ||
+ | instances = UNLIMITED | ||
+ | env = QS_SPAMASSASSIN="on" | ||
+ | server = /var/qmail/bin/tcp-env | ||
+ | server_args = /usr/sbin/rblsmtpd -r sbl-xbl.spamhaus.org /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true | ||
+ | } |
Revision as of 12:26, 5 November 2008
Contents |
General Improvements
Add razor, dcc and pyzor
Step 1) Add atomic channel:
wget -q -O - http://www.atomicorp.com/installers/atomic.sh |sh
Step 2) Add razor, dcc, pyzor
yum install razor-agents dcc pyzor
Step 3) Restart spamassassin
/etc/init.d/spamassassin restart
Force spamassassin to scan messages from localhost, when using qmail-scanner
vi /etc/xinetd.d/smtp_psa
service smtp { socket_type = stream protocol = tcp wait = no disable = no user = root instances = UNLIMITED env = QS_SPAMASSASSIN="on" server = /var/qmail/bin/tcp-env server_args = /usr/sbin/rblsmtpd -r sbl-xbl.spamhaus.org /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true }
Mysql settings for whitelisting
INSERT INTO userpref (username,preference,value) VALUES ('%tsginc.com','whitelist_from','*domain.com'); INSERT INTO userpref (username,preference,value) VALUES ('%tsginc.com','whitelist_from','*@domain.com');
Limiting Load
Add max_load to /etc/xinetd.d/smtp_psa. SMTP will throttle connections when load reaches a certain point.
service smtp { socket_type = stream protocol = tcp wait = no disable = no user = root max_load = 5 instances = UNLIMITED env = QS_SPAMASSASSIN="on" server = /var/qmail/bin/tcp-env server_args = /usr/sbin/rblsmtpd -r sbl-xbl.spamhaus.org /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true }