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
3 // found in the LICENSE file.
5 #include "components/password_manager/core/browser/password_manager_client.h"
7 namespace password_manager {
9 bool PasswordManagerClient::IsAutomaticPasswordSavingEnabled() const {
13 bool PasswordManagerClient::IsPasswordManagerEnabledForCurrentPage() const {
17 base::FieldTrial::Probability
18 PasswordManagerClient::GetProbabilityForExperiment(
19 const std::string& experiment_name) {
23 bool PasswordManagerClient::IsPasswordSyncEnabled(CustomPassphraseState state) {
27 void PasswordManagerClient::OnLogRouterAvailabilityChanged(
28 bool router_can_be_used) {
31 void PasswordManagerClient::LogSavePasswordProgress(const std::string& text) {
34 bool PasswordManagerClient::IsLoggingActive() const {
38 PasswordStore::AuthorizationPromptPolicy
39 PasswordManagerClient::GetAuthorizationPromptPolicy(
40 const autofill::PasswordForm& form) {
41 // Password Autofill is supposed to be a convenience. If it creates a
42 // blocking dialog, it is no longer convenient. We should only prompt the
43 // user after a full username has been typed in. Until that behavior is
44 // implemented, never prompt the user for keychain access.
45 // Effectively, this means that passwords stored by Chrome still work,
46 // since Chrome can access those without a prompt, but passwords stored by
47 // Safari, Firefox, or Chrome Canary will not work. Note that the latest
48 // build of Safari and Firefox don't create keychain items with the
49 // relevant tags anyways (7/11/2014).
50 // http://crbug.com/178358
51 return PasswordStore::DISALLOW_PROMPT;
54 } // namespace password_manager