changeset 8806:f8ad3dd142ad quic

QUIC: consider max_ack_delay=16384 invalid. As per RFC 9000: Values of 2^14 or greater are invalid.
author Roman Arutyunyan <arut@nginx.com>
date Wed, 30 Jun 2021 13:47:38 +0300
parents e96c20b6f655
children 0ac25efb2da3
files src/event/quic/ngx_event_quic.c src/http/modules/ngx_http_quic_module.c src/stream/ngx_stream_quic_module.c
diffstat 3 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/event/quic/ngx_event_quic.c	Wed Jun 23 13:22:00 2021 +0300
+++ b/src/event/quic/ngx_event_quic.c	Wed Jun 30 13:47:38 2021 +0300
@@ -176,7 +176,7 @@
         return NGX_ERROR;
     }
 
-    if (ctp->max_ack_delay > 16384) {
+    if (ctp->max_ack_delay >= 16384) {
         qc->error = NGX_QUIC_ERR_TRANSPORT_PARAMETER_ERROR;
         qc->error_reason = "invalid max_ack_delay";
 
--- a/src/http/modules/ngx_http_quic_module.c	Wed Jun 23 13:22:00 2021 +0300
+++ b/src/http/modules/ngx_http_quic_module.c	Wed Jun 30 13:47:38 2021 +0300
@@ -394,7 +394,7 @@
 {
     ngx_msec_t *sp = data;
 
-    if (*sp > 16384) {
+    if (*sp >= 16384) {
         ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
                            "\"quic_max_ack_delay\" must be less than 16384");
 
--- a/src/stream/ngx_stream_quic_module.c	Wed Jun 23 13:22:00 2021 +0300
+++ b/src/stream/ngx_stream_quic_module.c	Wed Jun 30 13:47:38 2021 +0300
@@ -354,7 +354,7 @@
 {
     ngx_msec_t *sp = data;
 
-    if (*sp > 16384) {
+    if (*sp >= 16384) {
         ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
                            "\"quic_max_ack_delay\" must be less than 16384");