Browse Source

Fix strict-sni bug.

master
Hakase 5 months ago
parent
commit
d27fbc0aee
Signed by: Hakase <hakase@hakase.app> GPG Key ID: BB2821A9E0DF48C9
1 changed files with 5 additions and 5 deletions
  1. 5
    5
      nginx_strict-sni.patch

+ 5
- 5
nginx_strict-sni.patch View File

@@ -1,5 +1,5 @@
1 1
 diff --git a/src/event/ngx_event_openssl.c b/src/event/ngx_event_openssl.c
2
-index 75129134..e9ea5231 100644
2
+index 75129134..30c236b4 100644
3 3
 --- a/src/event/ngx_event_openssl.c
4 4
 +++ b/src/event/ngx_event_openssl.c
5 5
 @@ -2547,6 +2547,9 @@ ngx_ssl_connection_error(ngx_connection_t *c, int sslerr, ngx_err_t err,
@@ -25,8 +25,8 @@ index 75129134..e9ea5231 100644
25 25
 +            f = ERR_GET_FUNC(ERR_peek_error());
26 26
 +            if (f == SSL_F_FINAL_SERVER_NAME) {
27 27
 +                while (ERR_peek_error()) {
28
-+                    ngx_log_debug0(NGX_LOG_DEBUG_EVENT, c->log, 0,
29
-+                                   "ignoring ssl error at STRICT SNI block");
28
++                    ngx_ssl_error(NGX_LOG_DEBUG, c->log, 0,
29
++                                  "ignoring ssl error at STRICT SNI block");
30 30
 +                }
31 31
 +                ERR_clear_error();
32 32
 +                return;
@@ -38,7 +38,7 @@ index 75129134..e9ea5231 100644
38 38
          if (n == SSL_R_BAD_CHANGE_CIPHER_SPEC                        /*  103 */
39 39
  #ifdef SSL_R_NO_SUITABLE_KEY_SHARE
40 40
 diff --git a/src/http/ngx_http_core_module.c b/src/http/ngx_http_core_module.c
41
-index c57ec00c..a14d68a9 100644
41
+index c57ec00c..be60d375 100644
42 42
 --- a/src/http/ngx_http_core_module.c
43 43
 +++ b/src/http/ngx_http_core_module.c
44 44
 @@ -441,6 +441,20 @@ static ngx_command_t  ngx_http_core_commands[] = {
@@ -94,7 +94,7 @@ index 4c6da7c0..04e14d09 100644
94 94
      ngx_flag_t    tcp_nodelay;             /* tcp_nodelay */
95 95
      ngx_flag_t    reset_timedout_connection; /* reset_timedout_connection */
96 96
 diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c
97
-index 7dd28b8c..1901129d 100644
97
+index 7dd28b8c..0e4fc6ae 100644
98 98
 --- a/src/http/ngx_http_request.c
99 99
 +++ b/src/http/ngx_http_request.c
100 100
 @@ -846,14 +846,18 @@ ngx_http_ssl_servername(ngx_ssl_conn_t *ssl_conn, int *ad, void *arg)

Loading…
Cancel
Save