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

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

Issue 181483006: PACKET_NBYTE_GUID -> PACKET_NBYTE_CONNECTION_ID (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: small comment fix Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « net/quic/crypto/crypto_handshake.h ('k') | net/quic/crypto/quic_crypto_client_config.h » ('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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 "base/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/strings/string_number_conversions.h" 6 #include "base/strings/string_number_conversions.h"
7 #include "crypto/secure_hash.h" 7 #include "crypto/secure_hash.h"
8 #include "net/quic/crypto/crypto_utils.h" 8 #include "net/quic/crypto/crypto_utils.h"
9 #include "net/quic/crypto/quic_crypto_server_config.h" 9 #include "net/quic/crypto/quic_crypto_server_config.h"
10 #include "net/quic/crypto/quic_random.h" 10 #include "net/quic/crypto/quic_random.h"
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 message, client_address_, &clock_, 171 message, client_address_, &clock_,
172 new ValidateCallback(this, false, error_substr, called)); 172 new ValidateCallback(this, false, error_substr, called));
173 } 173 }
174 174
175 void ProcessValidationResult(const CryptoHandshakeMessage& message, 175 void ProcessValidationResult(const CryptoHandshakeMessage& message,
176 const ValidateCallback::Result& result, 176 const ValidateCallback::Result& result,
177 bool should_succeed, 177 bool should_succeed,
178 const char* error_substr) { 178 const char* error_substr) {
179 string error_details; 179 string error_details;
180 QuicErrorCode error = config_.ProcessClientHello( 180 QuicErrorCode error = config_.ProcessClientHello(
181 result, 1 /* GUID */, client_address_, 181 result, 1 /* ConnectionId */, client_address_,
182 supported_versions_.front(), supported_versions_, &clock_, rand_, 182 supported_versions_.front(), supported_versions_, &clock_, rand_,
183 &params_, &out_, &error_details); 183 &params_, &out_, &error_details);
184 184
185 if (should_succeed) { 185 if (should_succeed) {
186 ASSERT_EQ(error, QUIC_NO_ERROR) 186 ASSERT_EQ(error, QUIC_NO_ERROR)
187 << "Message failed with error " << error_details << ": " 187 << "Message failed with error " << error_details << ": "
188 << message.DebugString(); 188 << message.DebugString();
189 } else { 189 } else {
190 ASSERT_NE(error, QUIC_NO_ERROR) 190 ASSERT_NE(error, QUIC_NO_ERROR)
191 << "Message didn't fail: " << message.DebugString(); 191 << "Message didn't fail: " << message.DebugString();
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
502 502
503 strike_register_client_->RunPendingVerifications(); 503 strike_register_client_->RunPendingVerifications();
504 ASSERT_TRUE(called); 504 ASSERT_TRUE(called);
505 EXPECT_EQ(0, strike_register_client_->PendingVerifications()); 505 EXPECT_EQ(0, strike_register_client_->PendingVerifications());
506 // The message should be rejected now. 506 // The message should be rejected now.
507 EXPECT_EQ(kREJ, out_.tag()); 507 EXPECT_EQ(kREJ, out_.tag());
508 } 508 }
509 509
510 } // namespace test 510 } // namespace test
511 } // namespace net 511 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/crypto/crypto_handshake.h ('k') | net/quic/crypto/quic_crypto_client_config.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698