Reverse proxy for mail server

emailemail-serverPROXYreverse-proxy

I'm looking for options of how to setup a reverse proxy for a mail server. Very similar to how apache can reverse proxy web traffic to hide the source of the web content, I want to hide the source of the mail server. I know this is an odd request, however it is definitely what I need.

Best Answer

I don't believe a proxy is what you need. Though if you must look into something proxy, there's a generic type of proxy called socks - google it. A web proxy will not work. Socks is... well, don't do it. Keep reading.

If you really want to hide your mail server you need to relay through another mail server, and modify your message headers.

There are many public mail relay services that you can pay for.

Incoming mail -> 3rd party relay -> your SMTP server -> destination

Outgoing mail -> your SMTP server -> 3rd party relay -> destination

The problem is with outbound mail, usually mail headers would contain things like this and you're smtp server would be listed as one of the "received" servers.

Received: from BAY169-W26 ([65.54.190.189]) by BAY004-OMC3S17.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.23008);

You can't remove that info, because it's added by the receiving SMTP server (3rd party). But maybe you can find a relay service that will keep you private. I use an outbound mail relay service that includes nothing about my server in it's headers. Inbound mail will not be an issue for you unless you bounce something back.

You'll also need to follow EEAA's directions to remove headers that your mail server has added before it goes out to the relay. Because it will also add things like Received: From example.com or x.x.x.x and the likes... though the hostname need not be a valid FQDN - in my case messages go out with an internal (not valid) domain name that can't be traced back to me in the headers and no IP addresses.

3rd party SMTP relays are nice in my opinion. They take some of the work out of dealing with the complexities of email. They often provide some lovely services to make your life easier.

FYI, I'm not hiding anything, it's just the way I'm setup!

Related Topic