How do you serve multiple HTTPS domains on one IP?
IntermediateScenarioTLS, HTTP & Application Layer
Answer
Situation read → SNI allows the client to say which hostname it wants during the handshake.
What I'd do →
- Configure one server block per domain with its own certificate in Nginx
server_name - On an ALB attach multiple certificates to the listener, and it picks by SNI
- Test with
openssl s_client -connect IP:443 -servername a.example.comand again with another name - Use wildcard or SAN certificates to reduce certificate count
Why → SNI is sent in the ClientHello, before encryption begins.
Interview tip → Mention that very old clients without SNI get the default certificate.
More on TLS, HTTP & Application Layer
Explain what happens in a TLS 1.3 handshake in a few sentences.BeginnerYour site must redirect all HTTP traffic to HTTPS. How do you do it?BeginnerWhat is the difference between 4xx and 5xx errors, and which ones do you see most in networking problems?BeginnerHTTP/1.1, HTTP/2 and HTTP/3: what changed and why does it matter in operations?BeginnerThe browser console shows a CORS error when your frontend calls your API. What is it and how do you fix it?BeginnerHow do you check which certificate a server presents and when it expires?Beginner