Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(384)

Unified Diff: net/quic/quic_connection.cc

Issue 647923002: Allow the number of undecryptable QUIC packets buffered before the (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@merge_76636673
Patch Set: set max_undecryptable_packets_ to 100 Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_connection.h ('k') | net/quic/quic_connection_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_connection.cc
diff --git a/net/quic/quic_connection.cc b/net/quic/quic_connection.cc
index 770e42b6a8161e1bc609239f4511f9dfbb90aa44..b6aa2c00c538d2c776c32abe828c3e80488d6716 100644
--- a/net/quic/quic_connection.cc
+++ b/net/quic/quic_connection.cc
@@ -54,10 +54,6 @@ const QuicPacketSequenceNumber kMaxPacketGap = 5000;
// that this becomes limiting, we can revisit.
const size_t kMaxFecGroups = 2;
-// Limit the number of undecryptable packets we buffer in
-// expectation of the CHLO/SHLO arriving.
-const size_t kMaxUndecryptablePackets = 10;
-
// Maximum number of acks received before sending an ack in response.
const size_t kMaxPacketsReceivedBeforeAckSend = 20;
@@ -205,6 +201,7 @@ QuicConnection::QuicConnection(QuicConnectionId connection_id,
last_decrypted_packet_level_(ENCRYPTION_NONE),
largest_seen_packet_with_ack_(0),
largest_seen_packet_with_stop_waiting_(0),
+ max_undecryptable_packets_(0),
pending_version_negotiation_packet_(false),
received_packet_manager_(&stats_),
ack_queued_(false),
@@ -272,6 +269,7 @@ void QuicConnection::SetFromConfig(const QuicConfig& config) {
SetIdleNetworkTimeout(config.IdleConnectionStateLifetime());
}
sent_packet_manager_.SetFromConfig(config);
+ max_undecryptable_packets_ = config.max_undecryptable_packets();
}
bool QuicConnection::SelectMutualVersion(
@@ -1117,7 +1115,7 @@ void QuicConnection::ProcessUdpPacket(const IPEndPoint& self_address,
// because the CHLO or SHLO packet was lost.
if (framer_.error() == QUIC_DECRYPTION_FAILURE) {
if (encryption_level_ != ENCRYPTION_FORWARD_SECURE &&
- undecryptable_packets_.size() < kMaxUndecryptablePackets) {
+ undecryptable_packets_.size() < max_undecryptable_packets_) {
QueueUndecryptablePacket(packet);
} else if (debug_visitor_.get() != nullptr) {
debug_visitor_->OnUndecryptablePacket();
« no previous file with comments | « net/quic/quic_connection.h ('k') | net/quic/quic_connection_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698