找回密码
 新建账号

支持TLS SNI的浏览器和服务器 虚拟主机配置HTTPS SSL加密证书

[复制链接]
php 发表于 2016/9/28 21:27 | 显示全部楼层 |阅读模式
TLS SNI,全称为the Transport Layer Security protocol Server Name Indication,支持在同一个服务器上面为不同的域名部署不同的SSL证书,实现多个虚拟主机HTTPS SSL站点共用一个服务器。SHA-1证书即将被SHA256证书取代,SHA-224、SHA-256、SHA-384,和SHA-512并称为SHA-2。

早期的SSL(the Secure Sockets Layer protocol)设计使得一个服务器只能提供一份加密证书,在同一服务器上面为不同的域名分配不同的SSL证书,对于不支持SNI的服务器,只有第一个虚拟主机的SSL证书能够被浏览器识别,用其他域名访问其他虚拟主机建立的SSL加密HTTPS站点,浏览器会告知SSL安全证书有问题不属于对应网站的警告。比如Windows XP IE7 IE8 IE9 此网站的安全证书有问题

支持SNI的浏览器
Windows XP中,IE6, IE7, IE8都不支持SNI,一个服务器配置了多个HTTPS站点时,只有第一个能正常访问,另外的会报SSL证书有问题。
Windows Vista, Windows 7, Windows 8, Windows 8.1, Windows 10中的Internet Explorer 7-11, Microsoft Edge都支持SNI
Google Chrome, Mozilla Firefox, Opera, Safari等现代浏览器都支持SNI,
至于国内的360, 百度, 搜狗之类的伪浏览器,只要内核支持,他们都支持……

支持SNI的服务器软件
Apache httpd 2.2.12 + mod_ssl
Nginx
lighttpd 1.4.24+
Microsoft IIS 8 (Internet Information Server 8)
参见:SNI Apache httpd SSL VirtualHost 多站点https协议虚拟主机配置

nginx可以运行nginx -V,如果有TLS SNI support enabled,则支持SNI
  1. C:\Users\Administrator>nginx -V
  2. nginx version: nginx/1.10.1
  3. built by cl 16.00.30319.01 for 80x86
  4. built with OpenSSL 1.0.2h  3 May 2016
  5. TLS SNI support enabled
  6. configure arguments: --with-cc=cl --builddir=objs.msvc8 --with-debug --prefix= -
  7. -conf-path=conf/nginx.conf --pid-path=logs/nginx.pid --http-log-path=logs/access
  8. .log --error-log-path=logs/error.log --sbin-path=nginx.exe --http-client-body-te
  9. mp-path=temp/client_body_temp --http-proxy-temp-path=temp/proxy_temp --http-fast
  10. cgi-temp-path=temp/fastcgi_temp --http-scgi-temp-path=temp/scgi_temp --http-uwsg
  11. i-temp-path=temp/uwsgi_temp --with-cc-opt=-DFD_SETSIZE=1024 --with-pcre=objs.msv
  12. c8/lib/pcre-8.38 --with-zlib=objs.msvc8/lib/zlib-1.2.8 --with-select_module --wi
  13. th-http_realip_module --with-http_addition_module --with-http_sub_module --with-
  14. http_dav_module --with-http_stub_status_module --with-http_flv_module --with-htt
  15. p_mp4_module --with-http_gunzip_module --with-http_gzip_static_module --with-htt
  16. p_auth_request_module --with-http_random_index_module --with-http_secure_link_mo
  17. dule --with-http_slice_module --with-mail --with-stream --with-openssl=objs.msvc
  18. 8/lib/openssl-1.0.2h --with-openssl-opt=no-asm --with-http_ssl_module --with-mai
  19. l_ssl_module --with-stream_ssl_module --with-ipv6
复制代码

手机版|轻松E站

GMT+8, 2024/3/28 22:54

快速回复 返回顶部 返回列表