This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

NAT rule for static host not working

We have a server that is accessed externally by going to https://www.abcd.com:12345.

For convenience from within the LAN, we made the following static network definition:
Name: abdc.com
Type: Host
IPV4 Address: 192.168.1.10
Hostname: abcd.com

So we can access the server from within the LAN by going to https://abcd.com.

To access it from outside the LAN, we use the following DNAT rule:
Traffic from: ANY
Service: 12345
Going To: External WAN Address
Change destination to: 192.168.1.10
Change service to: HTTPS (443)

So all of that works fine, but entering https://abcd.com:12345 while we are internal doesn't work - we have to use it without the port number.

We also use some smartphone apps to access the server and we have to create two different profiles for them. One is for when we are external (https://abcd.com:12345) and one for when we are internal (https://abcd.com - without the port).

I tried creating a NAT rule to address this, but it didn't work:
Traffic from: Internal LAN Network
Service: 12345
Going To: Internal LAN Address
Change destination to: 192.168.1.10
Change service to: HTTPS (443)

I've also tried different "Going To" destinations: abcd.com, Internal LAN Network, and 192.168.1.10.

Any hep is greatly appreciated!


This thread was automatically locked due to age.
Parents
  •  entering https://abcd.com:12345 while we are internal doesn't work - we have to use it without the port number.


    Perhaps I've misunderstood but from what you've said I wouldn't expect it to, NAT will work for packets 'going through' the firewall that matches your criteria. 

    When you are internal you're _NOT_ going through the firewall so no PAT (Port Address Translation) is being done.

    You will need to either :

    Amend your web server to listen on 443 & 12345 or;

    Amend your web server to listen on 12345 instead of 443.

    Now best practice would be to install your web server into a separate DMZ network i.e. packets from your internal secure lan would be going through the firewall. In this scenario you need to add another rule to NAT Local Lan -> DMZ Lan with the required PAT of 12345->443.
  • OK- that's exactly what we were considering next - amending the web server to add port 12345 should be an easy fix since we're only dealing with one program on one server. It would be "cleaner" to have everything handled by the UTM if possible, but if this works that's good enough for now.

    Thanks!
Reply
  • OK- that's exactly what we were considering next - amending the web server to add port 12345 should be an easy fix since we're only dealing with one program on one server. It would be "cleaner" to have everything handled by the UTM if possible, but if this works that's good enough for now.

    Thanks!
Children
No Data