LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxAnswers Discussion
User Name
Password
LinuxAnswers Discussion This forum is to discuss articles posted to LinuxAnswers.

Notices

Reply
 
Search this Thread
Old 12-04-2006, 04:59 PM   #1
jeremy
root
 
Registered: Jun 2000
Distribution: Debian, Red Hat, Slackware, Fedora, Ubuntu
Posts: 10,316

Rep: Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612
DISCUSSION: Stop More Spam


This thread is to discuss the article titled:
Stop More Spam

Quote:
Stop More Spam Features - Power Tools Written by Jeremy Garcia The December 2003
 
Old 12-04-2006, 05:22 PM   #2
derxob
Member
 
Registered: Apr 2006
Location: Los Angeles, California
Distribution: Slackware, Ubuntu
Posts: 68

Rep: Reputation: 15
Here's a small script I wrote for automatically fetching and updating some SA rule files that update often. It's nice to keep these rule files up to date because as we know, spammers are finding new ways to outsmart spam filters on a daily basis.

I add this script to my daily cron jobs.


Code:
#!/bin/sh

# adam@foogazi.com
# http://www.foogazi.com

# DO NOT IMPLEMENT THIS WITHOUT CHOOSING WHICH RULES TO USE AND DECIDING IF THEY WILL BE OF BENEFIT OR NOT.
# This script was created on a Slackware 10.0 machine.

# Implementing:
# CONFIG_PATH should be changed to the path of your local.cf file
# BACKUP_PATH should be changed to the path you want files to be backed up to - this path must be present before executing # this script.
# SCRIPT_PATH should be changed to the location of your spamd init script, used to start/restart spamassassin.


CONFIG_PATH=/etc/mail/spamassassin
BACKUP_PATH=/etc/mail/spamassassin/backup
SCRIPT_PATH=/etc/rc.d/rc.spamd

# Back up the current configs

cd $CONFIG_PATH
cp * $BACKUP_PATH

# Stop spamassassin
$SCRIPT_PATH stop

rm *.*

#Download rules:
# Uncomment the rules you want - see http://www.rulesemporium.com/ for more info.
# NOTE: You must uncomment at least one for this to work.

#wget http://www.rulesemporium.com/rules/70_sare_stocks.cf

#wget http://mywebpages.comcast.net/mkettler/sa/antidrug.cf

#wget http://www.emtinc.net/includes/backhair.cf

#wget http://www.timj.co.uk/linux/bogus-virus-warnings.cf

#wget http://www.sa-blacklist.stearns.org/sa-blacklist/sa-blacklist.current.uri.cf

#wget http://www.emtinc.net/includes/chickenpox.cf

#wget http://www.rulesemporium.com/rules/72_sare_redirect_post3.0.0.cf

#wget http://www.rulesemporium.com/rules/70_sare_evilnum0.cf

#wget http://www.rulesemporium.com/rules/70_sare_evilnum1.cf

#wget http://www.rulesemporium.com/rules/70_sare_evilnum2.cf

#wget http://www.rulesemporium.com/rules/70_sare_html.cf

#wget http://www.rulesemporium.com/rules/70_sare_html4.cf

#wget http://www.rulesemporium.com/rules/70_sare_html_arc.cf

#wget http://www.rulesemporium.com/rules/70_sare_html_eng.cf

#wget http://www.rulesemporium.com/rules/70_sare_bayes_poison_nxm.cf

#wget http://www.ccert.edu.cn/spam/sa/Chinese_rules.cf

#wget http://www.geewhiz.ca/images/b/b2/99_geewhizg_zh.cf

#wget http://www.geewhiz.ca/images/3/35/50_scores_geewhizg_zh.cf

#wget http://www.nospamtoday.com/download/mime_validate.cf

#wget http://www.rulesemporium.com/rules/70_sare_bayes_poison_nxm.cf

#wget http://www.sa-blacklist.stearns.org/sa-blacklist/random.current.cf

#wget http://www.rulesemporium.com/rules/99_FVGT_Tripwire.cf

#wget http://maxime.ritter.eu.org/Spam/french_rules.cf

#wget http://www.rulesemporium.com/rules/70_sare_header0.cf

#wget http://www.rulesemporium.com/rules/70_sare_specific.cf

#wget http://www.rulesemporium.com/rules/70_sare_ratware.cf

#wget http://www.rulesemporium.com/rules/70_sare_adult.cf

#wget http://www.rulesemporium.com/rules/72_sare_bml_post25x.cf

#wget http://www.rulesemporium.com/rules/99_sare_fraud_post25x.cf

#wget http://www.rulesemporium.com/rules/70_sare_spoof.cf

#wget http://www.rulesemporium.com/rules/70_sare_random.cf

#wget http://www.rulesemporium.com/rules/70_sc_top200.cf

#wget http://www.rulesemporium.com/rules/70_sare_oem.cf

#wget http://www.rulesemporium.com/rules/70_sare_genlsubj.cf

#wget http://www.rulesemporium.com/rules/70_sare_highrisk.cf

#wget http://www.rulesemporium.com/rules/70_sare_unsub.cf

#wget http://www.rulesemporium.com/rules/70_sare_uri0.cf

#wget http://www.rulesemporium.com/rules/70_sare_whitelist.cf

cp $BACKUP_PATH/local.cf .
cp $BACKUP_PATH/init.pre .
cp $BACKUP_PATH/rolex.cf .
cp $BACKUP_PATH/stock.cf .
cp $BACKUP_PATH/v310.pre .

# Start Spamassassin
$SCRIPT_PATH start
Side note:
Jeremy, fix: "...additional SA rules. he best place for this is http://www.rulesemporium.com/, .."

Nice article!

Last edited by derxob; 12-04-2006 at 05:25 PM.
 
Old 12-04-2006, 07:23 PM   #3
jeremy
root
 
Registered: Jun 2000
Distribution: Debian, Red Hat, Slackware, Fedora, Ubuntu
Posts: 10,316

Original Poster
Rep: Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612
Updated - thanks derxob.

--jeremy
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
stop outgoing spam zovres Linux - General 5 04-28-2009 07:16 AM
LXer: How to stop more spam LXer Syndicated Linux News 0 05-07-2006 01:33 AM
Stop Spam p_test Linux - Security 3 03-01-2006 08:43 AM
Stop Spam namit Linux - Software 2 12-08-2005 06:17 AM
how to stop spam:sendmail nabil Linux - General 3 09-10-2002 06:17 PM


All times are GMT -5. The time now is 02:10 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration