Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 1st April 2009, 07:25
sank1800 sank1800 is offline
Junior Member
 
Join Date: Apr 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Exclamation Best way to filter email attachments for multiple domains

Hi,

I want to setup a email gateway to block different types of attachments (ex: exe, dll, bat, mov, mpeg etc..) for emails coming to different domains and then forward them with a message (append to the original message) to the down stream MTA using a single linux installation (no need to scan for viruses / SPAMs, however ability drop connections at RBL level is highly preferable because it'll reduce some load of the server).

Can someone please suggest and provide configuration info to a such solution?

If some one can come with a how to style doc that would be great. However detailed explanation is enough at the moment.

Thanks in advance.
Reply With Quote
Sponsored Links
  #2  
Old 1st April 2009, 08:55
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

Use mailscanner.
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #3  
Old 1st April 2009, 12:04
sank1800 sank1800 is offline
Junior Member
 
Join Date: Apr 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

thanks for the quick reply. however i have no experience with that product. i can setup postfix using Ubuntu and it would be great if you can kindly guide me from there.

1) configure postfix for multiple domians (tutorials I see here use mysql database for domains and i think i might not need that because there will be few domains the system will be handling)

2) configuring mailscanner with postfix to strip the attachments and append a message to the original mail.

another question is can we configure postfix to accept emails without having us to create users in the local system?

To be more clear the mail flow would be like this

Internet --> proposed system (strips attachments on per domain basis)---> final MTA with inbuilt A/V , SPAM detection and user mailboxes.

I know the setup is bit strange but unfortunately the final server DOES NOT support attachment blocking

No issues with outbound email. they'll be directly sent by the email server with email boxes.

thanks again
Reply With Quote
  #4  
Old 1st April 2009, 12:16
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

Take a look at the spam snake howto on this site, it will give you pointers. Mailscanner is capable of doing spam filtering, blacklists and whitelists, message alteration, virus checks, rbl checks, attachment blocking the list goes on and on.

You will have to read the documentation and look at the configs to run a proper system.
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #5  
Old 1st April 2009, 12:18
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

Quote:
Originally Posted by sank1800 View Post

another question is can we configure postfix to accept emails without having us to create users in the local system?
You use the relay_domains option as well as an entry in the transport file to send the mail to the correct backend mail server.
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #6  
Old 4th April 2009, 18:58
sank1800 sank1800 is offline
Junior Member
 
Join Date: Apr 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for all the answers and I was able to make the spam snake setup to work upto some level and now I need some instructions from you.

1) How can I totally disable SPAM and Virus scanning and just filter the attachments?

2) How can I configure attachments on per domain basis?

3) Since it logs every thing to MySQL DB my guess is DB will grow quickly in an production environment. Is there any way we can clean the DB say every 5 days?

Thanks
Reply With Quote
  #7  
Old 15th April 2009, 11:11
sank1800 sank1800 is offline
Junior Member
 
Join Date: Apr 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
 
Default

Hi after some digging around the net I was able to solve 3 questions I had in the earlier post. However now there is another problem.

Front end mail scanner (separate server) is configured to do attachment filtering only and then pass email to end server which has anti spam, anti virus and mail boxes (all 3 in same server). Now since spam filter is getting emails from the front end mail scanner RBL function is not working.

Is there a way I can set postfix (or sendmail / qmail) with mail scanner in some sort of "transparent" manner so that I can take advantage of the RBL function in spam filter?

thanks in advance
Reply With Quote
Reply

Bookmarks

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ISP Config hesitation when opening web pages frankb Installation/Configuration 7 15th December 2008 13:06
Postfix - Relay access denied gotting Server Operation 3 23rd April 2008 14:06
network issues now it says "401 The web site is blocked by administrator" Check General 3 26th February 2008 14:22
Apache2 Freezes celtic Server Operation 31 28th May 2007 17:18
php script injections Grizzly General 21 18th July 2006 08:55


All times are GMT +2. The time now is 11:50.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.