| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 #ifndef SYNC_INTERNAL_API_SYNC_ENCRYPTION_HANDLER_IMPL_H_ | 5 #ifndef SYNC_INTERNAL_API_SYNC_ENCRYPTION_HANDLER_IMPL_H_ |
| 6 #define SYNC_INTERNAL_API_SYNC_ENCRYPTION_HANDLER_IMPL_H_ | 6 #define SYNC_INTERNAL_API_SYNC_ENCRYPTION_HANDLER_IMPL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 258 // Helper to enable encrypt everything, notifying observers if necessary. | 258 // Helper to enable encrypt everything, notifying observers if necessary. |
| 259 // Will not perform re-encryption. | 259 // Will not perform re-encryption. |
| 260 void EnableEncryptEverythingImpl(syncable::BaseTransaction* const trans); | 260 void EnableEncryptEverythingImpl(syncable::BaseTransaction* const trans); |
| 261 | 261 |
| 262 // If an explicit passphrase is in use, returns the time at which it was set | 262 // If an explicit passphrase is in use, returns the time at which it was set |
| 263 // (if known). Else return base::Time(). | 263 // (if known). Else return base::Time(). |
| 264 base::Time GetExplicitPassphraseTime() const; | 264 base::Time GetExplicitPassphraseTime() const; |
| 265 | 265 |
| 266 base::ThreadChecker thread_checker_; | 266 base::ThreadChecker thread_checker_; |
| 267 | 267 |
| 268 base::WeakPtrFactory<SyncEncryptionHandlerImpl> weak_ptr_factory_; | |
| 269 | |
| 270 ObserverList<SyncEncryptionHandler::Observer> observers_; | 268 ObserverList<SyncEncryptionHandler::Observer> observers_; |
| 271 | 269 |
| 272 // The current user share (for creating transactions). | 270 // The current user share (for creating transactions). |
| 273 UserShare* user_share_; | 271 UserShare* user_share_; |
| 274 | 272 |
| 275 // Container for all data that can be accessed from multiple threads. Do not | 273 // Container for all data that can be accessed from multiple threads. Do not |
| 276 // access this object directly. Instead access it via UnlockVault(..) and | 274 // access this object directly. Instead access it via UnlockVault(..) and |
| 277 // UnlockVaultMutable(..). | 275 // UnlockVaultMutable(..). |
| 278 Vault vault_unsafe_; | 276 Vault vault_unsafe_; |
| 279 | 277 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 300 int nigori_overwrite_count_; | 298 int nigori_overwrite_count_; |
| 301 | 299 |
| 302 // The time the nigori was migrated to support keystore encryption. | 300 // The time the nigori was migrated to support keystore encryption. |
| 303 base::Time migration_time_; | 301 base::Time migration_time_; |
| 304 | 302 |
| 305 // The time the custom passphrase was set for this account. Not valid | 303 // The time the custom passphrase was set for this account. Not valid |
| 306 // if there is no custom passphrase or the custom passphrase was set | 304 // if there is no custom passphrase or the custom passphrase was set |
| 307 // before support for this field was added. | 305 // before support for this field was added. |
| 308 base::Time custom_passphrase_time_; | 306 base::Time custom_passphrase_time_; |
| 309 | 307 |
| 308 base::WeakPtrFactory<SyncEncryptionHandlerImpl> weak_ptr_factory_; |
| 309 |
| 310 DISALLOW_COPY_AND_ASSIGN(SyncEncryptionHandlerImpl); | 310 DISALLOW_COPY_AND_ASSIGN(SyncEncryptionHandlerImpl); |
| 311 }; | 311 }; |
| 312 | 312 |
| 313 } // namespace syncer | 313 } // namespace syncer |
| 314 | 314 |
| 315 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_ENCRYPTION_HANDLER_IMPL_H_ | 315 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_ENCRYPTION_HANDLER_IMPL_H_ |
| OLD | NEW |