Hostname-based (FQDN/SNI) NAT / Virtual Server on a single public IP: any news in uOS?
Ally Member
Hello,
I have a USG FLEX H series behind an ISP router that forwards port 8443 to the firewall. I have a single public IP (45.23.1.1) and two DNS records pointing to it: test.it and test2.it. Both reach the firewall on port 8443 and I would like to route them to two different internal servers:
- test.it:8443 → 10.10.1.5:8443
- test2.it:8443 → 10.10.1.6:8443
From what I could find, NAT / Virtual Server only works at IP and port level and cannot distinguish traffic by requested hostname (HTTP Host header or TLS SNI). Previous discussions about USG/ZLD models suggested using a reverse proxy behind the firewall or different external ports.
Could you please:
- Confirm that on the H Series (uOS) it is not possible to do NAT or routing based on FQDN/SNI, even with SSL Inspection, Application Patrol or any other feature?
- If not available, let me know whether it is planned for upcoming releases or on the roadmap?
- Tell me whether there is an officially supported or recommended solution from Zyxel besides an external reverse proxy or using different ports?
Thank you.
Accepted Solution
-
Hi @Alex_91,
Thank you for the detailed description. Please find our answers below.
1. FQDN/SNI-based NAT on the H Series (uOS)
Your understanding is correct. On the USG FLEX H Series, NAT / Virtual Server rules match traffic only by IP address, protocol and port. Hostname-based forwarding (HTTP Host header or TLS SNI) is not supported, and uOS does not include a built-in reverse proxy.
This is not possible with SSL Inspection or Application Patrol either. NAT decides which host to forward the traffic to when the first TCP packet (SYN) arrives, but the hostname only appears after the TCP handshake, in the TLS ClientHello (SNI) or the HTTP request (Host header). To route by hostname, the device has to terminate the connection first and then open a new connection to the correct server, which is the job of a reverse proxy.
SSL Inspection and Application Patrol can inspect, allow or block traffic, but they cannot change the NAT destination.
2. Roadmap
Unfortunately, we currently have no plans to add hostname-based (FQDN/SNI) forwarding or a built-in reverse proxy to uOS.
For this use case with a single public IP, we recommend the following:
- Deploy a web reverse proxy behind the firewall (recommended).
- Use different external ports. For example, test.it:8443 → 10.10.1.5:8443 and test2.it:8444 → 10.10.1.6:8443. This is the simplest setup, but users have to include the port in the URL.
If you need any assistance, please let us know. Thank you.
0
All Replies
-
I was thinking you meant something else but from what I read maybe not? I feature I was thinking of was NAT / Virtual Server to have FQDN support for Source IP
so that you have rule 1
Source IP example1.com DNS lookup 2.2.2.2
External IP WAN1
Internal IP 192.168.1.100
Port Mapping Type
External Port 80
Internal Port 80
rule 2
Source IP example2.com DNS lookup 3.3.3.3
External IP WAN1
Internal IP 192.168.1.200
Port Mapping Type
External Port 80
Internal Port 80but reading more to your post you likely need to use a reverse proxy like nginx
0 -
Hi @Alex_91,
Thank you for the detailed description. Please find our answers below.
1. FQDN/SNI-based NAT on the H Series (uOS)
Your understanding is correct. On the USG FLEX H Series, NAT / Virtual Server rules match traffic only by IP address, protocol and port. Hostname-based forwarding (HTTP Host header or TLS SNI) is not supported, and uOS does not include a built-in reverse proxy.
This is not possible with SSL Inspection or Application Patrol either. NAT decides which host to forward the traffic to when the first TCP packet (SYN) arrives, but the hostname only appears after the TCP handshake, in the TLS ClientHello (SNI) or the HTTP request (Host header). To route by hostname, the device has to terminate the connection first and then open a new connection to the correct server, which is the job of a reverse proxy.
SSL Inspection and Application Patrol can inspect, allow or block traffic, but they cannot change the NAT destination.
2. Roadmap
Unfortunately, we currently have no plans to add hostname-based (FQDN/SNI) forwarding or a built-in reverse proxy to uOS.
For this use case with a single public IP, we recommend the following:
- Deploy a web reverse proxy behind the firewall (recommended).
- Use different external ports. For example, test.it:8443 → 10.10.1.5:8443 and test2.it:8444 → 10.10.1.6:8443. This is the simplest setup, but users have to include the port in the URL.
If you need any assistance, please let us know. Thank you.
0
Categories
- All Categories
- 442 Beta Program
- 3.1K Nebula
- 243 Nebula Ideas
- 6.8K Security
- 783 USG FLEX H Series
- 389 Security Ideas
- 1.8K Switch
- 87 Switch Ideas
- 1.5K Wireless
- 58 Wireless Ideas
- 7.2K Consumer Product
- 325 Service & License
- 527 News and Release
- 101 Security Advisories
- 31 Education Center
- 10 [Campaign] Zyxel Network Detective
- 5.3K FAQ
- 34 Documents
- 91 About Community
- 122 Security Highlight
Zyxel Employee
Guru Member