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

Unified Diff: components/password_manager/core/browser/password_store.h

Issue 2777283004: Do not build Password Reuse on Android and iOS (Closed)
Patch Set: Introduced gn var Created 3 years, 9 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: components/password_manager/core/browser/password_store.h
diff --git a/components/password_manager/core/browser/password_store.h b/components/password_manager/core/browser/password_store.h
index dd34afc9bc94e4b4bec0294c74d500f5bb61394d..314aeefe86f0bc3e04284d85a7271fdd04b11260 100644
--- a/components/password_manager/core/browser/password_store.h
+++ b/components/password_manager/core/browser/password_store.h
@@ -17,12 +17,15 @@
#include "base/single_thread_task_runner.h"
#include "base/time/time.h"
#include "components/keyed_service/core/refcounted_keyed_service.h"
-#include "components/password_manager/core/browser/password_reuse_detector.h"
-#include "components/password_manager/core/browser/password_reuse_detector_consumer.h"
#include "components/password_manager/core/browser/password_store_change.h"
#include "components/password_manager/core/browser/password_store_sync.h"
#include "components/sync/model/syncable_service.h"
+#if defined(PASSWORD_REUSE_DETECTION_SUPPORT)
+#include "components/password_manager/core/browser/password_reuse_detector.h"
+#include "components/password_manager/core/browser/password_reuse_detector_consumer.h"
+#endif
+
class PasswordStoreProxyMac;
namespace autofill {
@@ -227,6 +230,7 @@ class PasswordStore : protected PasswordStoreSync,
base::WeakPtr<syncer::SyncableService> GetPasswordSyncableService();
+#if defined(PASSWORD_REUSE_DETECTION_SUPPORT)
// Checks that some suffix of |input| equals to a password saved on another
// registry controlled domain than |domain|.
// If such suffix is found, |consumer|->OnReuseFound() is called on the same
@@ -235,6 +239,7 @@ class PasswordStore : protected PasswordStoreSync,
virtual void CheckReuse(const base::string16& input,
const std::string& domain,
PasswordReuseDetectorConsumer* consumer);
+#endif
protected:
friend class base::RefCountedThreadSafe<PasswordStore>;
@@ -271,6 +276,7 @@ class PasswordStore : protected PasswordStoreSync,
DISALLOW_COPY_AND_ASSIGN(GetLoginsRequest);
};
+#if defined(PASSWORD_REUSE_DETECTION_SUPPORT)
// Represents a single CheckReuse() request. Implements functionality to
// listen to reuse events and propagate them to |consumer| on the thread on
// which CheckReuseRequest is created.
@@ -292,6 +298,7 @@ class PasswordStore : protected PasswordStoreSync,
DISALLOW_COPY_AND_ASSIGN(CheckReuseRequest);
};
+#endif
~PasswordStore() override;
@@ -386,10 +393,12 @@ class PasswordStore : protected PasswordStoreSync,
// may have been changed.
void NotifyLoginsChanged(const PasswordStoreChangeList& changes) override;
+#if defined(PASSWORD_REUSE_DETECTION_SUPPORT)
// Synchronous implementation of CheckReuse().
void CheckReuseImpl(std::unique_ptr<CheckReuseRequest> request,
const base::string16& input,
const std::string& domain);
+#endif
// TaskRunner for tasks that run on the main thread (usually the UI thread).
scoped_refptr<base::SingleThreadTaskRunner> main_thread_runner_;
@@ -541,7 +550,9 @@ class PasswordStore : protected PasswordStoreSync,
std::unique_ptr<PasswordSyncableService> syncable_service_;
std::unique_ptr<AffiliatedMatchHelper> affiliated_match_helper_;
+#if defined(PASSWORD_REUSE_DETECTION_SUPPORT)
std::unique_ptr<PasswordReuseDetector> reuse_detector_;
+#endif
bool is_propagating_password_changes_to_web_credentials_enabled_;
bool shutdown_called_;

Powered by Google App Engine
This is Rietveld 408576698