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

Side by Side Diff: chrome/browser/sync/glue/sync_backend_host.h

Issue 6902101: Refactor sync passphrase setup flow and fix passphrase tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix unit test. Created 9 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_ 5 #ifndef CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_
6 #define CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_ 6 #define CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 // changed in another synced client. if 85 // changed in another synced client. if
86 // |passphrase_required_for_decryption| is false, the passphrase is 86 // |passphrase_required_for_decryption| is false, the passphrase is
87 // required only for encryption. 87 // required only for encryption.
88 virtual void OnPassphraseRequired(bool for_decryption) = 0; 88 virtual void OnPassphraseRequired(bool for_decryption) = 0;
89 89
90 // Called when the passphrase provided by the user is 90 // Called when the passphrase provided by the user is
91 // accepted. After this is called, updates to sensitive nodes are 91 // accepted. After this is called, updates to sensitive nodes are
92 // encrypted using the accepted passphrase. 92 // encrypted using the accepted passphrase.
93 virtual void OnPassphraseAccepted() = 0; 93 virtual void OnPassphraseAccepted() = 0;
94 94
95 // The syncer has attempted to set a passphrase, but failed to decrypt the
96 // cryptographer's pending keys. A new passphrase is required.
97 virtual void OnPassphraseFailed() = 0;
tim (not reviewing) 2011/04/28 17:13:53 This is what OnPassphraseRequired is for above...
Raghu Simha 2011/04/28 17:44:21 ProfileSyncServiceHarness::OnStateChanged is calle
98
95 virtual void OnEncryptionComplete( 99 virtual void OnEncryptionComplete(
96 const syncable::ModelTypeSet& encrypted_types) = 0; 100 const syncable::ModelTypeSet& encrypted_types) = 0;
97 101
98 // Called to perform migration of |types|. 102 // Called to perform migration of |types|.
99 virtual void OnMigrationNeededForTypes( 103 virtual void OnMigrationNeededForTypes(
100 const syncable::ModelTypeSet& types) = 0; 104 const syncable::ModelTypeSet& types) = 0;
101 105
102 protected: 106 protected:
103 // Don't delete through SyncFrontend interface. 107 // Don't delete through SyncFrontend interface.
104 virtual ~SyncFrontend() { 108 virtual ~SyncFrontend() {
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after
645 649
646 // Whether we've processed the initialization complete callback. 650 // Whether we've processed the initialization complete callback.
647 bool syncapi_initialized_; 651 bool syncapi_initialized_;
648 652
649 DISALLOW_COPY_AND_ASSIGN(SyncBackendHost); 653 DISALLOW_COPY_AND_ASSIGN(SyncBackendHost);
650 }; 654 };
651 655
652 } // namespace browser_sync 656 } // namespace browser_sync
653 657
654 #endif // CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_ 658 #endif // CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/sync/glue/sync_backend_host.cc » ('j') | chrome/browser/sync/profile_sync_service.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698