2

In the D-Link router configuration, I found two notions, NAT Forwarding that pairs A Local IP Address with A Remote IP Address:

enter image description here

And at the same time there is Port Forwarding that pairs A WAN Interface/IP and WAN Port with A LAN Port and LAN IP:

enter image description here

I don't understand the difference between them and which one of them I have to use to forward requests from Internet/public IP to local/LAN IP.

What is the difference and which one do I need?

TiyebM
  • 131

2 Answers2

1

You undoubtedly require port forwarding.

Port Forwarding allows you to direct a port to a specifc IP. So say you have following setup:

  • Public IP -> 80.100.100.100
  • Private Machine 1 -> 192.168.1.2
  • CCTV -> 192.168.1.3

If your CCTV required port 8080 to work to view this from the outside world your router would require the following details:

  • Protocol -> TCP
  • WAN Port -> 8080
  • LAN Open Port -> 8080
  • LAN IP Address -> 192.168.1.3

This would allow you to view the cameras on the internet by using https://80.100.100.100:8080

Alternatives to port forwarding are DMZ mode, but this would forward all traffic on the IP to the local internal IP (and to a large extent negates the benefits of the router blocking unwanted traffic) or uPnP which allows devices to tell the router to open a port (if a device can tell it to do it so, so can a virus or any other malicious software/hardware).

The documentation on NAT Forwarding from DLink seems to be lacking but I suspect this feature is in fact if you had multiple IP's assigned from your ISP and you wished to use one of the IP's for the device (maintining a local IP address within the router). NAT forwarding would not open the firewall to allow traffic into the network.

Peter
  • 158
0

What I wanted, was to use my visible public IP to be accessible from an external website, I was looking at port forwarding to communicate with gateway and try to forward requests from public gateway-IP to local/LAN IP in the router configuration.

The previous approach did not work, alternatively, I simply bridged the router connection, and set the public IP manually to the server.

TiyebM
  • 131