Community discussions

MUM Europe 2020
 
mabe
just joined
Topic Author
Posts: 2
Joined: Fri Nov 23, 2012 11:02 am

IMAP from in and outside

Fri Nov 23, 2012 11:34 am

Hi,

i operate my own IMAP server (192.168.1.20) on an static IP (213.135.x.x). Access from outside works fine. But access from inside the network to the IMAP Server is not possible.

Does anybody has an idea from access from inside the network?

0   chain=srcnat action=masquerade out-interface=pppoe-out1 

1   chain=dstnat action=dst-nat to-addresses=192.168.1.20 to-ports=993 
     protocol=tcp dst-address=213.135.xx.xx dst-port=993 

2   chain=dstnat action=dst-nat to-addresses=192.168.1.20 protocol=tcp 
     dst-address=213.135.xx.xx dst-port=80 
Flags: X - disabled, I - invalid, D - dynamic 
0   ;;; default configuration
     chain=input action=accept protocol=icmp 

1   ;;; default configuration
     chain=input action=accept connection-state=established 

2   ;;; default configuration
     chain=input action=accept connection-state=related 

3   ;;; default configuration
     chain=input action=drop dst-address=213.135.12.xx


Greetings

Markus
 
User avatar
janisk
MikroTik Support
MikroTik Support
Posts: 6283
Joined: Tue Feb 14, 2006 9:46 am
Location: Riga, Latvia

Re: IMAP from in and outside

Fri Nov 23, 2012 12:10 pm

you have to create DMZ (put your server in another network due to NAT problem, or, you can set router with static DNS entry that will resolve to your local address from your local network. And use router as your DNS resolver.

More about NAT problem you have:

when you connect to router from same network, you still attempt to connect to external IP and in one moment server and client starts to communicate directly while they expect packets to come from different source.
 
mabe
just joined
Topic Author
Posts: 2
Joined: Fri Nov 23, 2012 11:02 am

Re: IMAP from in and outside

Fri Nov 23, 2012 12:25 pm


you can set router with static DNS entry that will resolve to your local address from your local network
this solved the problem. Thank you.
 
User avatar
che
Frequent Visitor
Frequent Visitor
Posts: 94
Joined: Fri Oct 07, 2005 1:04 pm

Re: IMAP from in and outside

Fri Nov 23, 2012 12:31 pm

Just a side-note, in Cisco teminology this is called "DNS doctoring".
 
User avatar
janisk
MikroTik Support
MikroTik Support
Posts: 6283
Joined: Tue Feb 14, 2006 9:46 am
Location: Riga, Latvia

Re: IMAP from in and outside

Fri Nov 23, 2012 12:46 pm

oh, all those fancy names, i like to call things by cause not by remedy. In this case there are more than one solution how to resolve the issue.
 
User avatar
che
Frequent Visitor
Frequent Visitor
Posts: 94
Joined: Fri Oct 07, 2005 1:04 pm

Re: IMAP from in and outside

Fri Nov 23, 2012 4:42 pm

Didn't mean to cause frustration, you gave complete answer regarding the problem.

Who is online

Users browsing this forum: No registered users and 45 guests