nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

Postfix blacklist

This is a discussion on Postfix blacklist within the Mail Servers forums, part of the Mastering Servers category; I'd like to protect users from spam (UCE) using Postfix blacklist feature. Can any one describes methods that postfix provides ...


Go Back   nixCraft Linux Forum > Mastering Servers > Mail Servers

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 06-21-2007, 12:43 AM
sweta's Avatar
Contributors
User
 
Join Date: Feb 2005
Location: New Delhi
My distro: Suse, RHEL, Vista
Posts: 151
Rep Power: 4
sweta will become famous soon enough
Default Postfix blacklist

I'd like to protect users from spam (UCE) using Postfix blacklist feature. Can any one describes methods that postfix provides for the e-mail administrator to filter known spam sites and messages.

I want config for Relay control, junk mail control, and per-user policies etc

TIA
__________________
Friends - v-nessa - missyAdmin
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-26-2007, 03:41 PM
Junior Member
User
 
Join Date: Dec 2006
Posts: 2
Rep Power: 0
heX0R
Default

You can blacklist domains, IPs, IP blocks and hosts through regexp.

/etc/postfix/main.cf:

Code:
smtpd_recipient_restrictions =
	permit_mynetworks
	permit_sasl_authenticated
	reject_unauth_destination
	etc....
	check_client_access regexp:/etc/postfix/blacklist_clients
	etc..
	permit
/etc/postfix/blacklist_clients:

Code:
# IP
/^10\.10\.1\.2$/		REJECT UCE black-listed
# IP block
/^10\.10\.1/			REJECT UCE black-listed
# exact domain
/^example\.com$/		REJECT UCE black-listed
# everything in a domain
/example\.com$/			REJECT UCE black-listed
# specific hosts
/^uce-relay\.example\.com$/	REJECT UCE black-listed
Then reload postfix.

The best you can do is integrate postgrey, amavisd-new, spamassassin and clamav to make things easier for you and automatic. Postgrey would delay temporarily incoming mails to prevent zombies send their spam and while amavisd-new, spamassassin and clamav would check the messages and bring to quarantine junk ones.

Then from your quarantine, which I'm doing, I'm getting the lists of spam relay MTA/hosts to be listed in my regexp.

Also by adding the following simple parameters in your main.cf could reject several spam senders:

Code:
smtpd_helo_required = yes
smtpd_helo_restrictions =
        permit_mynetworks
        permit_sasl_authenticated
        reject_invalid_hostname
        reject_non_fqdn_hostname
-------------
Reply With Quote
  #3 (permalink)  
Old 07-27-2007, 06:55 AM
sweta's Avatar
Contributors
User
 
Join Date: Feb 2005
Location: New Delhi
My distro: Suse, RHEL, Vista
Posts: 151
Rep Power: 4
sweta will become famous soon enough
Smile

Thanks a lot!
__________________
Friends - v-nessa - missyAdmin
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
postfix rate limit blackhat_hk Mail Servers 3 05-03-2008 07:57 PM
postfix + google = headache. your help needed TECK Linux software 2 02-26-2008 04:45 PM
postfix ip whitelisting asim.mcp Mail Servers 1 10-12-2007 09:14 PM
POSTFIX Filtering for LAN and WAN matrix Mail Servers 0 02-06-2007 05:18 PM
regarding postfix mail server vishal Titre Linux software 2 09-28-2006 03:52 PM


All times are GMT +5.5. The time now is 04:30 AM.


Powered by vBulletin® Version 3.7.3 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36