Use a reverse proxy for SNI routing
mainA hardened architecture uses a reverse proxy (like nginx) to hide the proxy core (e.g., Xray) from direct internet exposure.
In the Meridian stack, nginx uses its stream module at port 443 to perform SNI Routing:
- It inspects the Server Name Indication (SNI) field of the incoming TLS connection.
- If the SNI matches a proxy target (e.g., a VLESS+Reality connection), it forwards the traffic to the Xray core.
- If the request is standard HTTPS, it passes it to the http module to serve a decoy webpage.
This allows the proxy to share port 443 with a normal website, making the server appear as a regular web server to outside observers.