diff --git a/quiche/quic/core/quic_flags_list.h b/quiche/quic/core/quic_flags_list.h index 3fd7ec03a..26861a1b9 100644 --- a/quiche/quic/core/quic_flags_list.h +++ b/quiche/quic/core/quic_flags_list.h @@ -55,8 +55,6 @@ QUIC_FLAG(quic_reloadable_flag_quic_allow_client_enabled_bbr_v2, true) QUIC_FLAG(quic_restart_flag_quic_opport_bundle_qpack_decoder_data, false) // If true, an endpoint does not detect path degrading or blackholing until handshake gets confirmed. QUIC_FLAG(quic_reloadable_flag_quic_no_path_degrading_before_handshake_confirmed, true) -// If true, check connected at the beginning of TlsHandshaker::SetReadSecret. -QUIC_FLAG(quic_reloadable_flag_quic_check_connected_before_set_read_secret, true) // If true, default-enable 5RTO blachole detection. QUIC_FLAG(quic_reloadable_flag_quic_default_enable_5rto_blackhole_detection2, true) // If true, disable QUIC version Q046. diff --git a/quiche/quic/core/tls_handshaker.cc b/quiche/quic/core/tls_handshaker.cc index 741544125..da4d06304 100644 --- a/quiche/quic/core/tls_handshaker.cc +++ b/quiche/quic/core/tls_handshaker.cc @@ -290,15 +290,11 @@ bool TlsHandshaker::SetReadSecret(EncryptionLevel level, absl::Span read_secret) { QUIC_DVLOG(1) << ENDPOINT << "SetReadSecret level=" << level << ", connection_closed=" << is_connection_closed(); - if (check_connected_before_set_read_secret_) { - if (is_connection_closed()) { - QUIC_RELOADABLE_FLAG_COUNT_N(quic_check_connected_before_set_read_secret, - 1, 2); - return false; - } - QUIC_RELOADABLE_FLAG_COUNT_N(quic_check_connected_before_set_read_secret, 2, - 2); + + if (is_connection_closed()) { + return false; } + std::unique_ptr decrypter = QuicDecrypter::CreateFromCipherSuite(SSL_CIPHER_get_id(cipher)); const EVP_MD* prf = Prf(cipher); diff --git a/quiche/quic/core/tls_handshaker.h b/quiche/quic/core/tls_handshaker.h index 71bede125..e2ee604ab 100644 --- a/quiche/quic/core/tls_handshaker.h +++ b/quiche/quic/core/tls_handshaker.h @@ -204,8 +204,6 @@ class QUICHE_EXPORT TlsHandshaker : public TlsConnection::Delegate, int expected_ssl_error_ = SSL_ERROR_WANT_READ; bool is_connection_closed_ = false; - const bool check_connected_before_set_read_secret_ = - GetQuicReloadableFlag(quic_check_connected_before_set_read_secret); QuicCryptoStream* stream_; HandshakerDelegateInterface* handshaker_delegate_;