# HG changeset patch # User Roman Arutyunyan # Date 1612460387 -10800 # Node ID 88c9c868a7c965ca8e48d88e86f514c854828ee9 # Parent 0b3d70fbba99b58c8287a0c9c94c167e4128ff21 QUIC: disabled non-immediate ACKs for Initial and Handshake. As per quic-transport-33: An endpoint MUST acknowledge all ack-eliciting Initial and Handshake packets immediately If a packet carrying Initial or Handshake ACK was lost, a non-immediate ACK should not be sent later. Instead, client is expected to send a new packet to acknowledge. Sending non-immediate ACKs for Initial packets can cause the client to generate an inflated RTT sample. diff --git a/src/event/quic/ngx_event_quic.c b/src/event/quic/ngx_event_quic.c --- a/src/event/quic/ngx_event_quic.c +++ b/src/event/quic/ngx_event_quic.c @@ -5527,8 +5527,11 @@ ngx_quic_resend_frames(ngx_connection_t switch (f->type) { case NGX_QUIC_FT_ACK: case NGX_QUIC_FT_ACK_ECN: - /* force generation of most recent acknowledgment */ - ctx->send_ack = NGX_QUIC_MAX_ACK_GAP; + if (ctx->level == ssl_encryption_application) { + /* force generation of most recent acknowledgment */ + ctx->send_ack = NGX_QUIC_MAX_ACK_GAP; + } + ngx_quic_free_frame(c, f); break;