Community discussions

MikroTik App
 
fbuster
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 56
Joined: Sat May 02, 2015 12:52 pm
Location: BE

Cannot access IP camera from lan but from outside

Sun Sep 25, 2016 10:33 am

I have an Ip camera inside my lan connected to my RB951
I have a port forward NAT rule to forward outside traffic to my camera.
I have an app on my phone that points to myexternalip:port and that works fine from the internet.

When i use the app to view my camera when i'm connected with my phone on the wireless lan
it doesnt work.

Can I make this work somehow by changing some settings on the router?

Below is my NAT config:
/ip firewall nat
add action=masquerade chain=srcnat comment="Lets masquerade all local IP's so they can go on the internet" out-interface=ether1-wan src-address=\
    192.168.2.0/24
add action=dst-nat chain=dstnat comment="Forward Incoming traffic on port 50002 to my Ip camera on 192.168.2.103:88" dst-port=50002 in-interface=\
    ether1-wan log=yes protocol=tcp to-addresses=192.168.2.103 to-ports=88
add action=dst-nat chain=dstnat comment="Forward Incoming traffic on port 50443 to my Ip camera on 192.168.2.103:443 https" dst-port=50443 in-interface=\
    ether1-wan log=yes protocol=tcp to-addresses=192.168.2.103 to-ports=443
Last edited by fbuster on Sun Sep 25, 2016 11:01 am, edited 3 times in total.
 
User avatar
razavim
Trainer
Trainer
Posts: 99
Joined: Sun Sep 27, 2015 1:43 pm
Location: Turkey
Contact:

Re: Cannot access IP camera from lan but from outside

Sun Sep 25, 2016 10:40 am

since this issue is depend on so many factors, Specially your firewall confog. i highly recommend to send your export config for better troubleshooting ,but if your camera is in different subnet than your wireless then do the same NAT for your internal network as well

Sent from my SM-N910C using Tapatalk
 
rjscomms
Member Candidate
Member Candidate
Posts: 132
Joined: Fri Jan 28, 2011 12:22 pm

Re: Cannot access IP camera from lan but from outside

Sun Sep 25, 2016 12:56 pm

Sounds like a Hairpin NAT problem.

Have a search for something like "mikrotik hairpin nat".

There is also a presentation in the Thailand MUM recently. Have a look at mum.mikrotik.com, archive, Thailand
 
User avatar
razavim
Trainer
Trainer
Posts: 99
Joined: Sun Sep 27, 2015 1:43 pm
Location: Turkey
Contact:

Re: Cannot access IP camera from lan but from outside

Sun Sep 25, 2016 1:19 pm

use the same port. if your camera is working on 88
put dst-port=88 as well if it doesnt help try to add firewall rule
/add action= accept chain=forward src-address=192.168.2.0/24

then try again

Sent from my SM-N910C using Tapatalk