Gnuru.org
Productive Linux


Subscribe

 Subscribe via Feedburner in a reader

Enter your email address:

Delivered by FeedBurner


Login
Login:
Password:



Don't have an account?
Sign up to Gnuru.org
Forgot your password?

Spamassassin and exim4
never
by Nomad

Using spamassassin with exim4 is a little different from exim3. This is because of the use of sa-exim a neat tool that plugs straight into exim and checks spam in one go. sa-exim is so easy to use that there is not much to write about it. It does however have one major disadvantage: it doesn't allow the use of user preferences such as black and white lists and Bayesian scoring.

That's why sometimes it's better to use the more heavyweight method. To do this these must be added in the transport section put this:

spamcheck:
	driver = pipe
	command = /usr/sbin/exim4 -oMr spam-scanned -bS
	transport_filter = /usr/bin/spamc -s60000 -u$local_part
	use_bsmtp = true
	home_directory = "/tmp"
	current_directory = "/tmp"
	user = mail
	group = mail
	return_path_add = false
	log_output = true
	return_fail_output = true
	message_prefix =
	message_suffix =

In the router section put:

spamcheck_director:
	no_verify
	check_local_user
	condition = "${if and { {!def:h_X-Spam-Flag:} {!eq {$received_protocol}{spam-scanned}} {!eq {$received_protocol}{local}} }{1}{0}}"
	driver = accept
	transport = spamcheck

Later I'll a description of what these actually do.

Tags: email exim spam



Comments disabled