Passthrough mailserver

I'm looking for suggestions and hair brained ideas.
I manage mail for a number of different domains.
I would like to setup a mailserver that archives/journals all traffic that passes through it.
Or to say it another way.
I want to setup a mailserver that
1. accepts message
2. creates a mailbox if one doesnt exist for this user
3. put the message in a certain predefined folder based on subject
4. forward message to recipient.

I'm basically trying to roll my own cloud spam filter.
I have the filtering down.  I have backup MX in place.
The last step is figuring a non labor intensive way to archive inbound mail for a few days in case the inhouse server is down they would still have web access to mail.

I'm fluent in Exchange but I don't think the licensing will be friendly to my pocket so opensource solution would be prefered.

I have looked at some archiving solutions  but most want LDAP to the main server or some other user verification.

throw your ideas at me.
Who is Participating?
jar3817Connect With a Mentor Commented:
Since you already this intermediate server that filters and forwards, you're just looking for the archiving part? Check out MailArchiva (, there's a free open source edition.
moorhouselondonConnect With a Mentor Commented:
2. creates a mailbox if one doesnt exist for this user

IMHO this is not practical (apart from licensing models which use quantity of mailboxes for their method of charging).  Spammers use random text to the left of the @ or probe likely combinations such as sales@ info@ etc.

Archive it by all means, and have a database of these attempts so that the user can sift and analyse them upon demand.  In some ways that's a research service you can market: commonly misspelled mailbox names et al.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.