Iis – Forwarding all mail to a single dev box on IIS via virtual SMTP

iisiis-6smtp

I am trying to set up a development environment for our web server. I would like all emails that are relayed by the server go to a specific mailbox, regardless of who they were sent to. For example, some application on the server sends an email to shopper@yahoo.com. I want that email to go to devbox@mysite.com. Is that possible to do with IIS/Virtual SMTP? Is there some other way of doing this? I don't have exchange server running, if that makes a difference.

Any help would be greatly appreciated. Thanks a lot!

Best Answer

IIS' SMTP server isn't particularly bright. I'd recommend using a more intelligent mail server that you control perform the address munging and/or forwarding to a specific address, and having IIS' SMTP server "smart host" to it.

The "more intelligent" mail server need not be a normal mail MTA application; a simple script that opens a network socket, implements just enough SMTP to catch the mail from IIS and write it out to a log file would work just fine.