comparison src/http/ngx_http_request.c @ 8176:8964cc6ecc4a quic

Transport parameters stub, to complete handshake.
author Sergey Kandaurov <pluknet@nginx.com>
date Fri, 28 Feb 2020 13:09:52 +0300
parents 72f632f90a17
children 76e29ff31cd3
comparison
equal deleted inserted replaced
8175:72f632f90a17 8176:8964cc6ecc4a
1356 { 1356 {
1357 ngx_http_close_connection(c); 1357 ngx_http_close_connection(c);
1358 return; 1358 return;
1359 } 1359 }
1360 1360
1361 static const uint8_t params[12] = "\x00\x0a\x00\x3a\x00\x01\x00\x00\x09\x00\x01\x03";
1362
1363 if (SSL_set_quic_transport_params(c->ssl->connection, params,
1364 sizeof(params)) == 0)
1365 {
1366 ngx_log_error(NGX_LOG_INFO, rev->log, 0,
1367 "SSL_set_quic_transport_params() failed");
1368 ngx_http_close_connection(c);
1369 return;
1370 }
1371
1361 n = SSL_do_handshake(c->ssl->connection); 1372 n = SSL_do_handshake(c->ssl->connection);
1362 1373
1363 ngx_log_debug1(NGX_LOG_DEBUG_EVENT, c->log, 0, "SSL_do_handshake: %d", n); 1374 ngx_log_debug1(NGX_LOG_DEBUG_EVENT, c->log, 0, "SSL_do_handshake: %d", n);
1364 1375
1365 if (n == -1) { 1376 if (n == -1) {
1745 "quic packet payload: %*s%s, len: %uz", 1756 "quic packet payload: %*s%s, len: %uz",
1746 m, buf, m < 512 ? "" : "...", cleartext_len); 1757 m, buf, m < 512 ? "" : "...", cleartext_len);
1747 } 1758 }
1748 #endif 1759 #endif
1749 1760
1750 ngx_http_close_connection(c);
1751 } 1761 }
1752 1762
1753 1763
1754 static void 1764 static void
1755 ngx_http_ssl_handshake(ngx_event_t *rev) 1765 ngx_http_ssl_handshake(ngx_event_t *rev)