How does SSL certificate map to server IP when it is issued for domain name? [closed]

I have an apache webserver on say a public IP address x.x.x.x

I have purchased a domain name somename.com

My administrator has mapped the IP address to the domain name.

I have a SSL certificate issued for the domain name and this is installed on the web server.

When a user (browser) enters the web url, the request will go to the IP address (web server, via the DNS server). The web server will respond to the user (browser).

But the SSL certificate is mapped only to domain name, not IP address. So how does SSL certificate map to server IP when it is issued for domain name?


So how does SSL certificate map to server IP when it is issued for domain name?

it doesn't. If certificate is issued to some domain name, then no one cares web server's IP address where resource is located. TLS client checks if requested address (in address bar, for example), matches the name in server certificate. No one cares about IP address, because it is used only for transport and routing purposes.

If there would be a map to IP address, then you would have to acquire a new certificate every time your IP is changed. This is why DNS was invented.