Community discussions

MikroTik App
 
krwi
just joined
Topic Author
Posts: 9
Joined: Mon Aug 21, 2017 3:49 pm

dstnat and local (from router) packet

Sun Oct 22, 2017 8:03 pm

I need to change dst address in some outgoing connection originated from router itself (eg fetch command):
chain=dstnat action=dst-nat to-addresses=some_ip protocol=tcp dst-address=some_ip src-address-type=local 
      dst-port=80 log=no log-prefix=""
but it not working, any packets hitting this rule.
So my question is: for packets originated from router itself, NAT table (especially dstnat chain) is not processed?
 
mali2003
newbie
Posts: 26
Joined: Sat Oct 21, 2017 1:15 am

Re: dstnat and local (from router) packet

Wed Oct 25, 2017 9:35 pm

Hi,

sry, but i do nat really understand what do u really want too.
Give us a liitle more information...

dstnat will not work for outgoing traffic.

dstnat will only transfer traffic, which comes in router to your destination ip, so this would not work for u.
try output instead of dstnat.
 
krwi
just joined
Topic Author
Posts: 9
Joined: Mon Aug 21, 2017 3:49 pm

Re: dstnat and local (from router) packet

Thu Oct 26, 2017 10:01 pm

Thanks for explanation, looks like Mikrotik firewall is quiet different than Linux iptables where OUTPUT traffic passing through NAT table and changing dst ip address in packets generated on localhost is easy (ex. when ping 1.1.1.1 packets goes to 2.2.2.2). Another example, how force local traffic to pass through web proxy, in Mikrotik is not possible?