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

Unified Diff: net/quic/crypto/quic_crypto_client_config.h

Issue 154933003: Persist server's crypto config data to disk cache for 0-RTT (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update with TOT and handle multiple tabs loading same URL Created 6 years, 10 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
Index: net/quic/crypto/quic_crypto_client_config.h
diff --git a/net/quic/crypto/quic_crypto_client_config.h b/net/quic/crypto/quic_crypto_client_config.h
index b11c197fa612921128125189a63d241385c2ef82..601f3854ea81668340330a943e51b0392bcb56fc 100644
--- a/net/quic/crypto/quic_crypto_client_config.h
+++ b/net/quic/crypto/quic_crypto_client_config.h
@@ -83,6 +83,7 @@ class NET_EXPORT_PRIVATE QuicCryptoClientConfig : public QuicCryptoConfig {
bool proof_valid() const;
uint64 generation_counter() const;
const ProofVerifyDetails* proof_verify_details() const;
+ QuicServerInfo* quic_server_info() const;
void set_source_address_token(base::StringPiece token);
@@ -95,6 +96,14 @@ class NET_EXPORT_PRIVATE QuicCryptoClientConfig : public QuicCryptoConfig {
// unchanged.
void InitializeFrom(const CachedState& other);
+ // Fill out the |server_config_|, |source_address_token_|, |certs_| and
+ // |server_config_sig_| fields of |this| from |quic_server_info_|.
wtc 2014/02/07 00:54:11 Nit: remove "of |this|". That is implied. Nit: th
ramant (doing other things) 2014/02/07 20:30:51 Done.
+ void LoadQuicServerInfo();
+
+ // Save the server config information so that we can perform 0-RTT handshake
+ // with a server.
+ void SaveQuicServerInfo();
+
private:
std::string server_config_id_; // An opaque id from the server.
std::string server_config_; // A serialized handshake message.
@@ -105,6 +114,7 @@ class NET_EXPORT_PRIVATE QuicCryptoClientConfig : public QuicCryptoConfig {
bool server_config_valid_; // True if |server_config_| is correctly
// signed and |certs_| has been
// validated.
+ bool need_to_persist_; // Persist to disk if True.
// Generation counter associated with the |server_config_|, |certs_| and
// |server_config_sig_| combination. It is incremented whenever we set
// server_config_valid_ to false.

Powered by Google App Engine
This is Rietveld 408576698