Home > SAP software/management Tips > SAP tips and best practices > Eliminating spam with SpamAssassin, DSPAM and ClamAV
SAP Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

SAP TIPS AND BEST PRACTICES

Eliminating spam with SpamAssassin, DSPAM and ClamAV


James Turnbull
07.15.2005
Rating: -1.62- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


Security consultant James Turnbull scrutinizes every facet of Linux security in his book, Hardening Linux. Here, the author explores three open source antispam tools that can be used in conjunction to secure e-mail and ultimately stanch the flow of spam.

SpamAssassin and DSPAM are both open source antispam tools designed to filter your e-mail and weed out spam. ClamAV is an open source antivirus package which uses regularly updated signature files to detect viruses both on your host and in your e-mail. They are each standalone packages but can be used together if you wish. Indeed, you will almost certainly need to combine both an antispam package and an antivirus package. Let's look at each package individually.

SpamAssassin (SA) is a mail filter written in Perl. It can be executed via mail processors like procmail or Maildrop, integrated into your mail server, run against a remote mailbox using IMAP, or incorporated into a third-party tool like AMaViS. It uses Bayesian spam filtering to tell which e-mail is spam and which is not spam (non-spam is also called ham). It can also incorporate tools like DCC, Razor, Pyzor and black and white listing as well as heuristic rules to detect spam. It is also capable of learning from the e-mails it filters to sharpen its detection ability.

I have used SA extensively and found it powerful and effective. For...


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   



RELATED CONTENT
SAP tips and best practices
Minimizing business disruptions during an SAP upgrade or implementation
Retrieving content from an SAP workflow attachment
Updating URLs in SAP SRM
How to change default settings in SAP SRM
What are the benefits of implementing SAP SRM?
Increase column width in a transaction screen
Updating an RT table entry in SAP HR Payroll -- without the ADDWTE option
Is this the quickest way to find a BADI?
Adding custom fields for retail product comparisons in SAP BW
Improving performance with ABAP Objects in SAP Workflow

SAP security administration
SAP TechEd 2009 Phoenix: SearchSAP.com Special Report
How to stop SAP users from displaying SAP HR tables content
Locating user email addresses in SAP SU01 transaction code
How to map multiple SAP roles and profiles
Viewing SAP transaction codes and profiles
Managing SAP user access and password expirations
Can SAP developer include authority check for S_TCODE in a called transaction?
Cisco and SAP integrate technologies to create data privacy application
SAP administration information for a Basis interview
Transferring R/3 Admin skills to SAP NetWeaver

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary


a smaller environment you would probably use SA in a procmail recipe to check incoming mail for spam. In a larger environment, you can run SA as a daemon and conduct your e-mail checking as part of your Mail Transfer Agent (MTA) mail processing and delivery. SA incorporates easily into MTAs like Sendmail, Postfix and Exim. You can learn how to do this using the SA documentation that comes with the package and on the SA website.

DSPAM is written in C and claims it is designed and optimized with large-scale mail enterprise environments in mind. It also utilizes Bayesian filtering, but unlike SA, it relies on machine-learning and artificial intelligence to detect spam. It can be integrated easily into Sendmail, Postfix, Qmail, Courier and Exim or run as a Simple Mail Transfer Protocol (SMTP) pre-processing gateway to process your e-mail for spam and then relay it to your MTA. DSPAM also has a backend storage database which keeps track of spam processed and Bayesian keywords learned. This back-end can utilize a variety of database back-ends including MySQL, SQLite, PostgreSQL, Berkeley DB and others.

DSPAM setup can be slightly tricky, but most issues tend to occur around permissions and authorization. DSPAM creates a default directory which must be writeable by the user who runs your MTA (if you've integrated DSPAM with an MTA). Additionally, the dspam binary occasionally needs to be getuid or setuid root in order to function correctly. This is generally dependent on how you have configured DSPAM, and error messages will usually indicate that there is a permission or ownership problem. Lastly, DSPAM has a list of trusted users who are allowed to maintain its settings. This list of trusted users is stored in the dspam.conf file (installed into /usr/local/etc by default) and you need to ensure your MTA users and other related users are included.

ClamAV combines a virus scanning daemon, a command line scanner and a milter interface to integrate with Sendmail. It includes the ability to scan mbox, Maildir and raw e-mail and also has support for scanning inside archives and scanning executables. It can be called via mail processors like procmail and Maildrop, integrated into MTAs or called from a third-party application like AMaViS. It includes a daemon called Freshclam that regularly checks and downloads antivirus signature updates.

So which antispam package is better? It is hard to say, and it greatly depends on your requirements and how you integrate, configure and tweak each package. The best way forward with antispam packages is to test how effective each is by seeing how much spam is detected and how many false positives are erroneously trapped by the package.

Many companies use SA and DSPAM in combination (or other combinations of multiple antispam tools) and then add an antivirus scanner like ClamAV to handle virus detection. The use of two antispam packages can reduce the volume of spam you receive by increasing the chance of detection through the use of multiple different spam detection methods. Obviously this can increase the processing time taken to evaluate your e-mail and the load on your mail environment, but the additional spam detected is often worth the additional load.


James Turnbull is the author of Hardening Linux and a security consultant at the Commonwealth Bank of Australia. He is also the resident security expert for SearchEnterpriseLinux.com.

Rate this Tip
To rate tips, you must be a member of SearchSAP.com.
Register now to start rating these tips. Log in if you are already a member.




DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



NetWeaver SAP White Papers
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 2000 - 2009, TechTarget | Read our Privacy Policy
SearchSAP.com is a search service provided by TechTarget and is completely
independent of and not affiliated with SAP AG.
  TechTarget - The IT Media ROI Experts