Module ngx_http_ssl_module ssl_reject_handshake
This directive appeared in version 1.19.4.
If enabled, SSL handshakes in the server block will be rejected.
For example, in the following configuration, SSL handshakes with server names other than example.com are rejected:
server {
listen 443 ssl default_server;
ssl_reject_handshake on;
}
server {
listen 443 ssl;
server_name example.com;
ssl_certificate example.com.crt;
ssl_certificate_key example.com.key;
}