My ISP has started blocking port 25 so I can not send email through my dedicated server any more.

I have several options:

  1. Send email through the SMTP server provided by my ISP. Any problems with this?
  2. Setup mu server so that it receives email on another port instead of port 25 No one else sends email through my server so it should be OK. How do I do this on a Linux server?
  3. Buy a static client IP - these are not being blocked so far.

Which one is preferable?


Solution 1:

  1. This is usually OK, though some ISPs configure their mail system to only transport mail for domains explicitly hosted through their services.

  2. Exactly how to do this will depend on the MTA ("Mail Transfer Agent") you are using and (if you are using an MTA from your Liunx distributions standard repositories) which distro you have, though in most cases it would be a simple edit of as text file somewhere in /etc. A more generic option would be to use something like rinetd, leaving your MTA listening on the standard port and having rinetd forward connections from a non-standard port to it.

  3. This would be my preferred option unless getting a static IP from your is too expensive.

Solution 2:

If I understand correctly, your SMTP server is remote to your local network. Is your ISP blocking the SMTP submission port (port 587) defined by RFC2476?

Solution 3:

Presuming they don't block smtps you could use stunnel to wrap port 25 on your server as below

http://www.octaldream.com/~scottm/talks/ssl/stunnel.html

and connect to that

GoDaddy do very cheap SMTP certs.

Solution 4:

Well...if ethical questions are brought into play, you should probably buy the static IP, since you're probably working against your terms of service. They won't be too sympathetic to users trying to work around their terms of service that you agreed to in the first place, assuming those are in your terms of service. If not you could try calling and complaining about it, or switch providers, but most responsible ones are blocking 25 now because of worms and trojans spamming people.

Otherwise you might have to bite the bullet and use your service provider's SMTP server.

Solution 5:

The answer that is preferable depends on your parameters.

  1. This works, but you give up a measure of privacy and confidentiality since the mails are now routed via your ISP's server. This is the easiest method, and if privacy isn't a particular concern then I would go with this.
  2. Depends on your server. Search on here for it's name for specific directions.
  3. I wouldn't do this unless you have some other reason for it. Many time blacklists add these "ISP" IPs even if they are static.

Alternatively, you could tunnel traffic to your server. If running SSH with key access set up, a tunnel is as simple as:

ssh -f username -L 25:YOUR.SERVER.IP:25 -N

This will forward port 25 on your local machine to port 25 on your server via ssh in the background. You would then set up your mail client to use localhost as the mail server.