views:

93

answers:

2

I need a cross platform (at least windows and mac) development utility that runs as an SMTP server that acts as an SMTP server but will redirect all mail to a single address that's configurable. It would also be helpful if it wrote the contents out to a file or gui. Long ago I configured Apache James to do this but it wasn't that straight forward to figure out. Hoping there's something really simple out there.

I need the emails to be forwarded (to the single address) so I can see how they are rendered on different clients (gmail, outlook, etc.)

Thanks! -Mike

+1  A: 

It doesn't do the forwarding you are looking for, but for most of my testing I make use of fakemail (http://www.lastcraft.com/fakemail.php) it's simply a script that listens on a port an acts as an smtp server, writing any incoming mail to a directory.

Brenton Alker
A: 

You could use Python's smtpd library and override the process_message function to only send to the desired address -- i.e. replace the "to" field with your desired constant email address.

Here's a page with some examples of using smtpd (with asyncore) to actually send out mail.

Mark Rushakoff