I have two external parties needing to connect (using Remote Desktop RDP on port 3389) to two different internal servers.
Also, only user1 should be able to connect to server1; and only user2 should connect to server2.
There are two parts to this:
- Firstly, the Vigor's Firewall will examine the incoming packets, and decide whether to block or allow them according to their Source and Destination IP Addresses and port numbers.
- Those packets which are allowed will then be passed to the Vigor's NAT function which will redirect them to the appropriate internal server.Â
Lets start with the NAT step...
Routers are unable to forward one port to two different computers, and so we must use 2 different public port numbers.Â Fortunately the Vigor's NAT > Port Redirection allows us to translate port numbers transparently to the application.
Index 1 - Any packets received at the Vigor's public port 3389 will be forwarded to server1 at 192.168.1.8 port 3389.
Index 2 - Any packets received at the Vigor's public port 3390 will be forwarded to server2 at 192.168.1.9 port 3389.
Note that both servers will receive the incoming packets to their port 3389, so no server re-configuration is required.
At this point we can test.Â If we open Remote Desktop connection on a PC connected to the internet and enter our Vigor's public IP Address, the RDC will use the default port (3389) and connect to server1.Â If we enter our Vigor's public IP Address, a colon (:) and port number 3390, the PCÂ should connect to server2.
But anyone who knows our Vigor's public IP address, the port numbers (and any username/password on the servers) can connect. We want to allow only user1 to connect to server1.
On to the Firewall step...
Since the Firewall examines the incoming packets, the IP Addresses will still be the Public Source and Destination IP Addresses.Â So if our Vigor has a static public IP of 126.96.36.199, and user1's router has a static public IP address of 188.8.131.52 (note that this is not a private 192.168.*.* address), theÂ new firewall rule would be :Â
- Add new Filter Set .Â Rule 1sets up the default action of blocking all access to Vigor's public IP address (184.108.40.206) and port 3389
- Now add rule 2 for the case where the packet is coming from user1 (source = 220.127.116.11) and destination is Vigor's port 3389
Now you will have to add another Firewall rule at Filter set 6 rule 3 - similar to Filter set 6 rule 2 above, except with user2's public IP as the Source Address and with port number 3390 (instead of 3389).
Finally you will need to link the new rule set into the existing rules.Â Go back to Filter Setup, where you should now see filter sets 1 (Default Sall Filter), 2 (Default Data Filter) , and 6 (the one we just created).Â Â Select Set 2 (Default Data Filter" and in the bottom right corner is a field for "Next Filter Set".Â Select the value "Set#6" and click [OK].