Welcome! Log In Create A New Profile


Default ssl server and sni

December 17, 2014 12:06PM
I have a bunch of https websites available over a single IP working with sni on nginx 1.0.15.

Currently, anyone accessing a domain name that resolves to the same IP is greeted with a certificate mismatch error due to nginx choosing the first server as the default.

Instead of using the first server as the default, I'd like to create a catch-all https server that drops/resets the tcp connection. As such all domain names that have an associated server block would still work using sni, but IPs or other domain names would simply result in a dropped connection.

Unfortunately, I can't seem to get this to work. If I define the server block below, all requests are handled by the catch-all server, and all the websites become inaccessible. Here is the server block I've defined:

server {
listen 443 default_server;
return 443;

Does anyone know how I could achieve this?


Subject Author Posted

Default ssl server and sni

rthur December 17, 2014 12:06PM

Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 63
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready