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

Unified Diff: net/quic/crypto/quic_crypto_server_config.cc

Issue 1660533002: Landing Recent QUIC changes until 01/26/2016 18:14 UTC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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/crypto/quic_crypto_server_config.h ('k') | net/quic/quic_arena_scoped_ptr_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/crypto/quic_crypto_server_config.cc
diff --git a/net/quic/crypto/quic_crypto_server_config.cc b/net/quic/crypto/quic_crypto_server_config.cc
index d04b44cdd5386c20cda9399d94007f019862c12f..ab8202a605674ebb9f43f3a9173c748932945081 100644
--- a/net/quic/crypto/quic_crypto_server_config.cc
+++ b/net/quic/crypto/quic_crypto_server_config.cc
@@ -522,7 +522,11 @@ void QuicCryptoServerConfig::ValidateClientHello(
requested_config = GetConfigWithScid(requested_scid);
primary_config = primary_config_;
- crypto_proof->primary_scid = primary_config->id;
+ if (FLAGS_quic_crypto_proof_use_ref) {
+ crypto_proof->config = primary_config_;
+ } else {
+ crypto_proof->primary_scid = primary_config->id;
+ }
}
if (result->error_code == QUIC_NO_ERROR) {
@@ -582,7 +586,11 @@ QuicErrorCode QuicCryptoServerConfig::ProcessClientHello(
// Use the config that the client requested in order to do key-agreement.
// Otherwise give it a copy of |primary_config_| to use.
- primary_config = GetConfigWithScid(crypto_proof->primary_scid);
+ if (FLAGS_quic_crypto_proof_use_ref) {
+ primary_config = crypto_proof->config;
+ } else {
+ primary_config = GetConfigWithScid(crypto_proof->primary_scid);
+ }
if (!primary_config) {
*error_details = "Configuration not found";
QUIC_BUG << "Primary config not found";
@@ -744,7 +752,7 @@ QuicErrorCode QuicCryptoServerConfig::ProcessClientHello(
&plaintext_length, kMaxPacketSize);
if (!success) {
*error_details = "CETV decryption failure";
- return QUIC_PACKET_TOO_LARGE;
+ return QUIC_INVALID_CRYPTO_MESSAGE_PARAMETER;
}
scoped_ptr<CryptoHandshakeMessage> cetv(
CryptoFramer::ParseMessage(StringPiece(plaintext, plaintext_length)));
@@ -1803,4 +1811,6 @@ QuicCryptoServerConfig::Config::~Config() {
STLDeleteElements(&key_exchanges);
}
+QuicCryptoProof::QuicCryptoProof() : certs(nullptr) {}
+QuicCryptoProof::~QuicCryptoProof() {}
} // namespace net
« no previous file with comments | « net/quic/crypto/quic_crypto_server_config.h ('k') | net/quic/quic_arena_scoped_ptr_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698