| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #include "components/password_manager/core/browser/password_reuse_detection_mana
ger.h" | 5 #include "components/password_manager/core/browser/password_reuse_detection_mana
ger.h" |
| 6 | 6 |
| 7 #include "base/time/default_clock.h" | 7 #include "base/time/default_clock.h" |
| 8 #include "components/password_manager/core/browser/browser_save_password_progres
s_logger.h" | 8 #include "components/password_manager/core/browser/browser_save_password_progres
s_logger.h" |
| 9 #include "components/password_manager/core/browser/password_manager.h" | 9 #include "components/password_manager/core/browser/password_manager.h" |
| 10 #include "components/password_manager/core/browser/password_manager_client.h" | 10 #include "components/password_manager/core/browser/password_manager_client.h" |
| 11 #include "components/password_manager/core/browser/password_manager_metrics_util
.h" | 11 #include "components/password_manager/core/browser/password_manager_metrics_util
.h" |
| 12 #include "components/password_manager/core/browser/password_manager_util.h" | 12 #include "components/password_manager/core/browser/password_manager_util.h" |
| 13 #include "ui/events/keycodes/keyboard_codes_posix.h" | 13 #include "ui/events/keycodes/keyboard_codes_posix.h" |
| 14 #if defined(SAFE_BROWSING_DB_LOCAL) || defined(SAFE_BROWSING_DB_REMOTE) | |
| 15 #include "components/safe_browsing/password_protection/password_protection_servi
ce.h" | |
| 16 #endif | |
| 17 | 14 |
| 18 using base::Time; | 15 using base::Time; |
| 19 using base::TimeDelta; | 16 using base::TimeDelta; |
| 20 | 17 |
| 21 namespace password_manager { | 18 namespace password_manager { |
| 22 | 19 |
| 23 namespace { | 20 namespace { |
| 24 constexpr size_t kMaxNumberOfCharactersToStore = 30; | 21 constexpr size_t kMaxNumberOfCharactersToStore = 30; |
| 25 constexpr TimeDelta kMaxInactivityTime = TimeDelta::FromSeconds(10); | 22 constexpr TimeDelta kMaxInactivityTime = TimeDelta::FromSeconds(10); |
| 26 } | 23 } |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 client_->CheckProtectedPasswordEntry(legitimate_domain); | 97 client_->CheckProtectedPasswordEntry(legitimate_domain); |
| 101 #endif | 98 #endif |
| 102 } | 99 } |
| 103 | 100 |
| 104 void PasswordReuseDetectionManager::SetClockForTesting( | 101 void PasswordReuseDetectionManager::SetClockForTesting( |
| 105 std::unique_ptr<base::Clock> clock) { | 102 std::unique_ptr<base::Clock> clock) { |
| 106 clock_ = std::move(clock); | 103 clock_ = std::move(clock); |
| 107 } | 104 } |
| 108 | 105 |
| 109 } // namespace password_manager | 106 } // namespace password_manager |
| OLD | NEW |