Mercurial > hg > nginx
comparison src/event/quic/ngx_event_quic_ssl.c @ 9076:5dcea9f91482 quic
QUIC: using NGX_QUIC_ERR_CRYPTO macro in ALPN checks.
Patch by Jiuzhou Cui.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Thu, 23 Feb 2023 15:49:59 +0400 |
parents | 3c98fa8fef6f |
children | cb7dc35ed428 |
comparison
equal
deleted
inserted
replaced
9075:12b756caaf16 | 9076:5dcea9f91482 |
---|---|
188 #if defined(TLSEXT_TYPE_application_layer_protocol_negotiation) | 188 #if defined(TLSEXT_TYPE_application_layer_protocol_negotiation) |
189 | 189 |
190 SSL_get0_alpn_selected(ssl_conn, &alpn_data, &alpn_len); | 190 SSL_get0_alpn_selected(ssl_conn, &alpn_data, &alpn_len); |
191 | 191 |
192 if (alpn_len == 0) { | 192 if (alpn_len == 0) { |
193 qc->error = 0x100 + SSL_AD_NO_APPLICATION_PROTOCOL; | 193 qc->error = NGX_QUIC_ERR_CRYPTO(SSL_AD_NO_APPLICATION_PROTOCOL); |
194 qc->error_reason = "unsupported protocol in ALPN extension"; | 194 qc->error_reason = "unsupported protocol in ALPN extension"; |
195 | 195 |
196 ngx_log_error(NGX_LOG_INFO, c->log, 0, | 196 ngx_log_error(NGX_LOG_INFO, c->log, 0, |
197 "quic unsupported protocol in ALPN extension"); | 197 "quic unsupported protocol in ALPN extension"); |
198 return 0; | 198 return 0; |