Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

My ISP block pop3 port 110 & smtp port 25. I have own VPS mail server and i would like to use pop3 email. How can i listen pop3 on both 443 & 110. I have enable the forwarding in /proc/sys/net/ipv4/ip_forward file. Type this command in shell >> iptables -A FORWARD -p tcp --sport 443 -i eth0 -o eth0 --dport 110 -j ACCEPT

Here is result in iptables

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination
ACCEPT     tcp  --  anywhere             anywhere            tcp spt:https dpt:pop3

When i access pop3 mail from Outlook got an error. Please check screenshot:

share|improve this question

4 Answers 4

Tell your ISP to unblock the default ports ports for you. If they won't, get a new ISP.

share|improve this answer
    
if need to get new ISP, won't post here –  LoRdiE Jan 7 '10 at 5:45
    
Just because you don't like the answer, doesn't mean it isn't the correct one. –  womble Jan 7 '10 at 6:30

If I understand correctly, you wish to redirect traffic that is coming for the port 443 of your email server to be redirected to port 110 instead.

If that's the case, doing so with iptables rules is a bit more complex than what you've just described. I would suggest to modify the configuration of your mail server for it to listen to another port than 110. Most mail server will allow you to change that. Without knowing what mail system you use it's difficult to tell you where to change the configuration however.

share|improve this answer
    
Thanks for reply. I'm using CentOS 5.4 with cPanel. Mail server is Dovecat/Exim/cPPOP –  LoRdiE Jan 7 '10 at 5:56
    
+1: Much easier to change the port in the mail program than to do ass-around-your-elbow with iptables. –  Satanicpuppy Jan 7 '10 at 14:18
    
How do i change port? Need to configure the firewall to allow traffic on port 443? How can i check which port is use by which service? –  LoRdiE Jan 8 '10 at 2:58

Why don't you just run POP3 on a different port? Configure a suitable port on each end and do away with all that complication.

share|improve this answer

I agree w/ the other posters re: just chaging your POP3 daemon to listen on another port.

If you really want to do this with iptables, though, the iptables REDIRECT target is what you're looking for:

iptables -t nat -A PREROUTING -d x.x.x.x -p tcp --dport 443 -j REDIRECT --to-port 110

Substitute the IP address of the machine in for x.x.x.x and incoming traffic to TCP port 443 will be redirected to TCP port 110.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.