| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 COMPONENTS_SYNC_TEST_FAKE_SYNC_ENCRYPTION_HANDLER_H_ | 5 #ifndef COMPONENTS_SYNC_TEST_FAKE_SYNC_ENCRYPTION_HANDLER_H_ |
| 6 #define COMPONENTS_SYNC_TEST_FAKE_SYNC_ENCRYPTION_HANDLER_H_ | 6 #define COMPONENTS_SYNC_TEST_FAKE_SYNC_ENCRYPTION_HANDLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| 11 #include "base/observer_list.h" | 11 #include "base/observer_list.h" |
| 12 #include "components/sync/base/cryptographer.h" | 12 #include "components/sync/base/cryptographer.h" |
| 13 #include "components/sync/base/fake_encryptor.h" | 13 #include "components/sync/base/fake_encryptor.h" |
| 14 #include "components/sync/core/sync_encryption_handler.h" | 14 #include "components/sync/engine/sync_encryption_handler.h" |
| 15 #include "components/sync/syncable/nigori_handler.h" | 15 #include "components/sync/syncable/nigori_handler.h" |
| 16 | 16 |
| 17 namespace syncer { | 17 namespace syncer { |
| 18 | 18 |
| 19 // A fake sync encryption handler capable of keeping track of the encryption | 19 // A fake sync encryption handler capable of keeping track of the encryption |
| 20 // state without opening any transactions or interacting with the nigori node. | 20 // state without opening any transactions or interacting with the nigori node. |
| 21 // Note that this only performs basic interactions with the cryptographer | 21 // Note that this only performs basic interactions with the cryptographer |
| 22 // (setting pending keys, installing keys). | 22 // (setting pending keys, installing keys). |
| 23 // Note: NOT thread safe. If threads attempt to check encryption state | 23 // Note: NOT thread safe. If threads attempt to check encryption state |
| 24 // while another thread is modifying it, races can occur. | 24 // while another thread is modifying it, races can occur. |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 PassphraseType passphrase_type_; | 62 PassphraseType passphrase_type_; |
| 63 | 63 |
| 64 FakeEncryptor encryptor_; | 64 FakeEncryptor encryptor_; |
| 65 Cryptographer cryptographer_; | 65 Cryptographer cryptographer_; |
| 66 std::string keystore_key_; | 66 std::string keystore_key_; |
| 67 }; | 67 }; |
| 68 | 68 |
| 69 } // namespace syncer | 69 } // namespace syncer |
| 70 | 70 |
| 71 #endif // COMPONENTS_SYNC_TEST_FAKE_SYNC_ENCRYPTION_HANDLER_H_ | 71 #endif // COMPONENTS_SYNC_TEST_FAKE_SYNC_ENCRYPTION_HANDLER_H_ |
| OLD | NEW |