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

Side by Side Diff: net/quic/quic_utils.cc

Issue 1208933004: QUIC - disable QUIC under recent pathological connection errors. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revised after fourth round of review feedback. Created 5 years, 5 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 unified diff | Download patch
« no previous file with comments | « net/quic/quic_stream_factory_test.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/quic/quic_utils.h" 5 #include "net/quic/quic_utils.h"
6 6
7 #include <ctype.h> 7 #include <ctype.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 RETURN_STRING_LITERAL(QUIC_CRYPTO_SERVER_CONFIG_EXPIRED); 221 RETURN_STRING_LITERAL(QUIC_CRYPTO_SERVER_CONFIG_EXPIRED);
222 RETURN_STRING_LITERAL(QUIC_INVALID_CHANNEL_ID_SIGNATURE); 222 RETURN_STRING_LITERAL(QUIC_INVALID_CHANNEL_ID_SIGNATURE);
223 RETURN_STRING_LITERAL(QUIC_CRYPTO_SYMMETRIC_KEY_SETUP_FAILED); 223 RETURN_STRING_LITERAL(QUIC_CRYPTO_SYMMETRIC_KEY_SETUP_FAILED);
224 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_WHILE_VALIDATING_CLIENT_HELLO); 224 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_WHILE_VALIDATING_CLIENT_HELLO);
225 RETURN_STRING_LITERAL(QUIC_CRYPTO_UPDATE_BEFORE_HANDSHAKE_COMPLETE); 225 RETURN_STRING_LITERAL(QUIC_CRYPTO_UPDATE_BEFORE_HANDSHAKE_COMPLETE);
226 RETURN_STRING_LITERAL(QUIC_VERSION_NEGOTIATION_MISMATCH); 226 RETURN_STRING_LITERAL(QUIC_VERSION_NEGOTIATION_MISMATCH);
227 RETURN_STRING_LITERAL(QUIC_TOO_MANY_OUTSTANDING_SENT_PACKETS); 227 RETURN_STRING_LITERAL(QUIC_TOO_MANY_OUTSTANDING_SENT_PACKETS);
228 RETURN_STRING_LITERAL(QUIC_TOO_MANY_OUTSTANDING_RECEIVED_PACKETS); 228 RETURN_STRING_LITERAL(QUIC_TOO_MANY_OUTSTANDING_RECEIVED_PACKETS);
229 RETURN_STRING_LITERAL(QUIC_CONNECTION_CANCELLED); 229 RETURN_STRING_LITERAL(QUIC_CONNECTION_CANCELLED);
230 RETURN_STRING_LITERAL(QUIC_BAD_PACKET_LOSS_RATE); 230 RETURN_STRING_LITERAL(QUIC_BAD_PACKET_LOSS_RATE);
231 RETURN_STRING_LITERAL(QUIC_PUBLIC_RESETS_POST_HANDSHAKE);
232 RETURN_STRING_LITERAL(QUIC_TIMEOUTS_WITH_OPEN_STREAMS);
231 RETURN_STRING_LITERAL(QUIC_LAST_ERROR); 233 RETURN_STRING_LITERAL(QUIC_LAST_ERROR);
232 // Intentionally have no default case, so we'll break the build 234 // Intentionally have no default case, so we'll break the build
233 // if we add errors and don't put them here. 235 // if we add errors and don't put them here.
234 } 236 }
235 // Return a default value so that we return this when |error| doesn't match 237 // Return a default value so that we return this when |error| doesn't match
236 // any of the QuicErrorCodes. This can happen when the ConnectionClose 238 // any of the QuicErrorCodes. This can happen when the ConnectionClose
237 // frame sent by the peer (attacker) has invalid error code. 239 // frame sent by the peer (attacker) has invalid error code.
238 return "INVALID_ERROR_CODE"; 240 return "INVALID_ERROR_CODE";
239 } 241 }
240 242
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
338 } 340 }
339 return s; 341 return s;
340 } 342 }
341 343
342 // static 344 // static
343 QuicPriority QuicUtils::HighestPriority() { 345 QuicPriority QuicUtils::HighestPriority() {
344 return QuicWriteBlockedList::kHighestPriority; 346 return QuicWriteBlockedList::kHighestPriority;
345 } 347 }
346 348
347 } // namespace net 349 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_stream_factory_test.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698