#676 closed defect (wontfix)
Different ssl_protocols per server won`t work
Reported by: | Roman Pavlík | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | |
Component: | nginx-core | Version: | 1.6.x |
Keywords: | Cc: | ||
uname -a: | Linux office-server 3.2.0-4-amd64 #1 SMP Debian 3.2.54-2 x86_64 GNU/Linux | ||
nginx -V: |
nginx version: nginx/1.6.2
TLS SNI support enabled configure arguments: --with-cc-opt='-g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2' --with-ld-opt=-Wl,-z,relro --prefix=/usr/share/nginx --conf-path=/etc/nginx/nginx.conf --http-log-path=/var/log/nginx/access.log --error-log-path=/var/log/nginx/error.log --lock-path=/var/lock/nginx.lock --pid-path=/run/nginx.pid --http-client-body-temp-path=/var/lib/nginx/body --http-fastcgi-temp-path=/var/lib/nginx/fastcgi --http-proxy-temp-path=/var/lib/nginx/proxy --http-scgi-temp-path=/var/lib/nginx/scgi --http-uwsgi-temp-path=/var/lib/nginx/uwsgi --with-debug --with-pcre-jit --with-ipv6 --with-http_ssl_module --with-http_stub_status_module --with-http_realip_module --with-http_auth_request_module --with-http_addition_module --with-http_dav_module --with-http_geoip_module --with-http_gzip_static_module --with-http_image_filter_module --with-http_spdy_module --with-http_sub_module --with-http_xslt_module --with-mail --with-mail_ssl_module --add-module=/tmp/buildd/nginx-1.6.2/debian/modules/nginx-auth-pam --add-module=/tmp/buildd/nginx-1.6.2/debian/modules/nginx-dav-ext-module --add-module=/tmp/buildd/nginx-1.6.2/debian/modules/nginx-echo --add-module=/tmp/buildd/nginx-1.6.2/debian/modules/nginx-upstream-fair --add-module=/tmp/buildd/nginx-1.6.2/debian/modules/ngx_http_substitutions_filter_module |
Description
I configured Nginx for two TLS virtualhost 'example.one' and 'example.two' with two different certficates.
I need to setup TLS1.0+ for the first one and only TLS1.2 for the second one. However the second one (example.two) configuration ignores ssl_protocols directive and takes ssl_procolols from first server directive.
So both server directive uses the first configured ssl_protocols directive.
server { listen 443 default_server ssl spdy; server_name example.one; ssl_protocols TLSv1 TLSv1.1 TLSv1.2; ssl_certificate /certs/cert-for-example.one.pem; ssl_certificate_key /certs/privkey-for-example.one.pem; # another ssl_* directives ... }
server { listen 443 ssl spdy; server_name example.two; ssl_protocols TLSv1.2; ssl_certificate /certs/cert-for-example.two.pem; ssl_certificate_key /certs/privkey-for-example.two.pem; # another ssl_* directives ... }
I don't want to use SSL3 so the TLS SNI should work fine and I believe Nginx can decide which ssl_protocols directive to use based on server name provided in client Hello packet.
Change History (5)
comment:1 by , 10 years ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
comment:2 by , 8 years ago
As a workaround, there are a possible to restrict TLS protocol version using "ssl_ciphers" directive. Supplying TLSv1.2 specific cipher suites will effectively prevent handshake for lower TLS versions. So, for above example,
ssl_ciphers 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-SHA256';
instead "ssl_protocols TLSv1.2;" will do the trick.
This is per OpenSSL behaviour, and there isn't much nginx can do to fix this. See detailed explanation and previous discussion in this thread.