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

Side by Side Diff: chrome/browser/password_manager/chrome_password_manager_client.h

Issue 2783773002: Link PasswordProtectionService to Profile and SB Service (Closed)
Patch Set: RemovePasswordProtectionService(..) Created 3 years, 8 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_PASSWORD_MANAGER_CHROME_PASSWORD_MANAGER_CLIENT_H_ 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_CHROME_PASSWORD_MANAGER_CLIENT_H_
6 #define CHROME_BROWSER_PASSWORD_MANAGER_CHROME_PASSWORD_MANAGER_CLIENT_H_ 6 #define CHROME_BROWSER_PASSWORD_MANAGER_CHROME_PASSWORD_MANAGER_CLIENT_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 void ShowPasswordGenerationPopup(const gfx::RectF& bounds, 97 void ShowPasswordGenerationPopup(const gfx::RectF& bounds,
98 int max_length, 98 int max_length,
99 const base::string16& generation_element, 99 const base::string16& generation_element,
100 bool is_manually_triggered, 100 bool is_manually_triggered,
101 const autofill::PasswordForm& form) override; 101 const autofill::PasswordForm& form) override;
102 void ShowPasswordEditingPopup(const gfx::RectF& bounds, 102 void ShowPasswordEditingPopup(const gfx::RectF& bounds,
103 const autofill::PasswordForm& form) override; 103 const autofill::PasswordForm& form) override;
104 void GenerationAvailableForForm(const autofill::PasswordForm& form) override; 104 void GenerationAvailableForForm(const autofill::PasswordForm& form) override;
105 void HidePasswordGenerationPopup() override; 105 void HidePasswordGenerationPopup() override;
106 106
107 #if defined(SAFE_BROWSING_DB_LOCAL) || defined(SAFE_BROWSING_DB_REMOTE)
108 safe_browsing::PasswordProtectionService* GetPasswordProtectionService()
Nathan Parker 2017/04/03 20:33:34 Re: SAFE_BROWSING_DB_REMOTE -- On Android we don't
Jialiu Lin 2017/04/03 20:45:12 Thanks for pointing this out. It completely slippe
109 const override;
110 #endif
111
107 static void CreateForWebContentsWithAutofillClient( 112 static void CreateForWebContentsWithAutofillClient(
108 content::WebContents* contents, 113 content::WebContents* contents,
109 autofill::AutofillClient* autofill_client); 114 autofill::AutofillClient* autofill_client);
110 115
111 // Observer for PasswordGenerationPopup events. Used for testing. 116 // Observer for PasswordGenerationPopup events. Used for testing.
112 void SetTestObserver(autofill::PasswordGenerationPopupObserver* observer); 117 void SetTestObserver(autofill::PasswordGenerationPopupObserver* observer);
113 118
114 static void BindCredentialManager( 119 static void BindCredentialManager(
115 content::RenderFrameHost* render_frame_host, 120 content::RenderFrameHost* render_frame_host,
116 password_manager::mojom::CredentialManagerRequest request); 121 password_manager::mojom::CredentialManagerRequest request);
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 // means that nothing was chosen. |one_local_credential| is true if there was 159 // means that nothing was chosen. |one_local_credential| is true if there was
155 // just one local credential to be chosen from. 160 // just one local credential to be chosen from.
156 void OnCredentialsChosen(const CredentialsCallback& callback, 161 void OnCredentialsChosen(const CredentialsCallback& callback,
157 bool one_local_credential, 162 bool one_local_credential,
158 const autofill::PasswordForm* form); 163 const autofill::PasswordForm* form);
159 164
160 // Returns true if this profile has metrics reporting and active sync 165 // Returns true if this profile has metrics reporting and active sync
161 // without custom sync passphrase. 166 // without custom sync passphrase.
162 static bool ShouldAnnotateNavigationEntries(Profile* profile); 167 static bool ShouldAnnotateNavigationEntries(Profile* profile);
163 168
164 #if defined(SAFE_BROWSING_DB_LOCAL) || defined(SAFE_BROWSING_DB_REMOTE)
165 // Return true if we can set PasswordProtectionService in
166 // |password_reuse_detection_manager_|.
167 static bool CanSetPasswordProtectionService();
168 #endif
169
170 Profile* const profile_; 169 Profile* const profile_;
171 170
172 password_manager::PasswordManager password_manager_; 171 password_manager::PasswordManager password_manager_;
173 172
174 password_manager::PasswordReuseDetectionManager 173 password_manager::PasswordReuseDetectionManager
175 password_reuse_detection_manager_; 174 password_reuse_detection_manager_;
176 175
177 password_manager::ContentPasswordManagerDriverFactory* driver_factory_; 176 password_manager::ContentPasswordManagerDriverFactory* driver_factory_;
178 177
179 // As a mojo service, will be registered into service registry 178 // As a mojo service, will be registered into service registry
(...skipping 20 matching lines...) Expand all
200 std::unique_ptr<password_manager::LogManager> log_manager_; 199 std::unique_ptr<password_manager::LogManager> log_manager_;
201 200
202 // Set during 'NotifyUserCouldBeAutoSignedIn' in order to store the 201 // Set during 'NotifyUserCouldBeAutoSignedIn' in order to store the
203 // form for potential use during 'NotifySuccessfulLoginWithExistingPassword'. 202 // form for potential use during 'NotifySuccessfulLoginWithExistingPassword'.
204 std::unique_ptr<autofill::PasswordForm> possible_auto_sign_in_; 203 std::unique_ptr<autofill::PasswordForm> possible_auto_sign_in_;
205 204
206 DISALLOW_COPY_AND_ASSIGN(ChromePasswordManagerClient); 205 DISALLOW_COPY_AND_ASSIGN(ChromePasswordManagerClient);
207 }; 206 };
208 207
209 #endif // CHROME_BROWSER_PASSWORD_MANAGER_CHROME_PASSWORD_MANAGER_CLIENT_H_ 208 #endif // CHROME_BROWSER_PASSWORD_MANAGER_CHROME_PASSWORD_MANAGER_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698