2016-06-09 124 views
0

我有我的ConfigEd nginx的一個http2服務的Chrome 51.0.2704.84沒有請求HTTP/2.0,但Safari瀏覽器的火狐做

worker_processes 2; 
    events { 
     worker_connections 1024; 
     multi_accept on; 
     use epoll; 
    } 

http { 
    sendfile on; 

    server { 
     listen 80; 
     location/{ 
      return 301 https://$host$request_uri; 
     } 
    } 

    server { 
     listen 443 ssl http2; 

     ssl_certificate  /usr/cer/server.cer; 
     ssl_certificate_key /usr/cer/server.key; 

     location/{ 
      root /usr/share/nginx/html; 
      index index.html; 
     } 
    } 
} 

與日誌消息

  • 的Chrome 51.0.2704.84
  • 的Safari 9.1.1
  • 火狐47.0

+1

https://www.nginx.com/blog/supporting-http2-google-鍍鉻的用戶/ –

回答

0

原因:

爲了解決這個問題,谷歌開發了名爲SPDY新的傳輸層。 SPDY通過SSL/TLS訪問,並且Google開發了名爲Next Protocol Negotiation(NPN)的SSL/TLS修改,允許客戶將其SSL/TLS連接從HTTP/1升級到HTTP/2。主要的網絡服務器(如NGINX)實施了SPDY; OpenSSL和其他SSL/TLS堆棧實施了NPN。

從源

溶液

重新編譯NGINX和使用私有構建使用OpenSSL 1.0.2

相關問題