Index: sync/util/cryptographer.h |
diff --git a/sync/util/cryptographer.h b/sync/util/cryptographer.h |
index f02875a41e69fdbcc5fbc22a8ce4a1d747309f9e..d66402037d1ce84d942e0ff49798258a2df6f29c 100644 |
--- a/sync/util/cryptographer.h |
+++ b/sync/util/cryptographer.h |
@@ -179,6 +179,15 @@ class Cryptographer { |
// stored in the |pending_keys_|. |
UpdateResult Update(const sync_pb::NigoriSpecifics& nigori); |
+ // Set the keystore-derived nigori from the provided key. |
+ // Returns true if we succesfully create the keystore derived nigori from the |
+ // provided key, false otherwise. |
+ bool SetKeystoreKey(const std::string& keystore_key); |
+ |
+ // Returns true if we currently have a keystore-derived nigori, false |
+ // otherwise. |
+ bool HasKeystoreKey(); |
+ |
// The set of types that are always encrypted. |
static ModelTypeSet SensitiveTypes(); |
@@ -237,6 +246,7 @@ class Cryptographer { |
NigoriMap nigoris_; // The Nigoris we know about, mapped by key name. |
NigoriMap::value_type* default_nigori_; // The Nigori used for encryption. |
+ NigoriMap::value_type* keystore_nigori_; // Nigori generated from keystore. |
scoped_ptr<sync_pb::EncryptedData> pending_keys_; |