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

Side by Side Diff: net/quic/crypto/quic_crypto_server_config.cc

Issue 2187463004: Add a new flag to require QUIC handshake confirmation, but only for versions before 33 FLAGS_quic_r… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@128425078
Patch Set: Created 4 years, 4 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/crypto/crypto_server_test.cc ('k') | net/quic/quic_crypto_server_stream_test.cc » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/crypto/quic_crypto_server_config.h" 5 #include "net/quic/crypto/quic_crypto_server_config.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <memory> 10 #include <memory>
(...skipping 1201 matching lines...) Expand 10 before | Expand all | Expand 10 after
1212 if (!is_unique) { 1212 if (!is_unique) {
1213 info->reject_reasons.push_back(server_nonce_error); 1213 info->reject_reasons.push_back(server_nonce_error);
1214 } 1214 }
1215 DVLOG(1) << "Using server nonce, unique: " << is_unique; 1215 DVLOG(1) << "Using server nonce, unique: " << is_unique;
1216 helper.ValidationComplete(QUIC_NO_ERROR, ""); 1216 helper.ValidationComplete(QUIC_NO_ERROR, "");
1217 return; 1217 return;
1218 } 1218 }
1219 // If we hit this block, the server nonce was empty. If we're requiring 1219 // If we hit this block, the server nonce was empty. If we're requiring
1220 // handshake confirmation for DoS reasons and there's no server nonce present, 1220 // handshake confirmation for DoS reasons and there's no server nonce present,
1221 // reject the CHLO. 1221 // reject the CHLO.
1222 if (FLAGS_quic_require_handshake_confirmation) { 1222 if (FLAGS_quic_require_handshake_confirmation ||
1223 FLAGS_quic_require_handshake_confirmation_pre33) {
1223 info->reject_reasons.push_back(SERVER_NONCE_REQUIRED_FAILURE); 1224 info->reject_reasons.push_back(SERVER_NONCE_REQUIRED_FAILURE);
1224 helper.ValidationComplete(QUIC_NO_ERROR, ""); 1225 helper.ValidationComplete(QUIC_NO_ERROR, "");
1225 return; 1226 return;
1226 } 1227 }
1227 1228
1228 // We want to contact strike register only if there are no errors because it 1229 // We want to contact strike register only if there are no errors because it
1229 // is a RPC call and is expensive. 1230 // is a RPC call and is expensive.
1230 if (found_error) { 1231 if (found_error) {
1231 helper.ValidationComplete(QUIC_NO_ERROR, ""); 1232 helper.ValidationComplete(QUIC_NO_ERROR, "");
1232 return; 1233 return;
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after
2033 priority(0), 2034 priority(0),
2034 source_address_token_boxer(nullptr) {} 2035 source_address_token_boxer(nullptr) {}
2035 2036
2036 QuicCryptoServerConfig::Config::~Config() { 2037 QuicCryptoServerConfig::Config::~Config() {
2037 STLDeleteElements(&key_exchanges); 2038 STLDeleteElements(&key_exchanges);
2038 } 2039 }
2039 2040
2040 QuicCryptoProof::QuicCryptoProof() {} 2041 QuicCryptoProof::QuicCryptoProof() {}
2041 QuicCryptoProof::~QuicCryptoProof() {} 2042 QuicCryptoProof::~QuicCryptoProof() {}
2042 } // namespace net 2043 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/crypto/crypto_server_test.cc ('k') | net/quic/quic_crypto_server_stream_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698