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

Side by Side Diff: components/proximity_auth/proximity_auth_pref_manager.h

Issue 2902093002: [EasyUnlock] Force user to enter their password after 20 hours. (Closed)
Patch Set: fix test Created 3 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 COMPONENTS_PROXIMITY_AUTH_PROXIMITY_AUTH_PREF_MANAGER_H 5 #ifndef COMPONENTS_PROXIMITY_AUTH_PROXIMITY_AUTH_PREF_MANAGER_H
6 #define COMPONENTS_PROXIMITY_AUTH_PROXIMITY_AUTH_PREF_MANAGER_H 6 #define COMPONENTS_PROXIMITY_AUTH_PROXIMITY_AUTH_PREF_MANAGER_H
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 52
53 // Queries the devices stored in |kProximityAuthRemoteBleDevices| pref by 53 // Queries the devices stored in |kProximityAuthRemoteBleDevices| pref by
54 // |bluetooth_address| or |public_key|. Virtual for testing. 54 // |bluetooth_address| or |public_key|. Virtual for testing.
55 virtual bool HasDeviceWithAddress(const std::string& bluetooth_address) const; 55 virtual bool HasDeviceWithAddress(const std::string& bluetooth_address) const;
56 virtual bool HasDeviceWithPublicKey(const std::string& public_key) const; 56 virtual bool HasDeviceWithPublicKey(const std::string& public_key) const;
57 virtual std::string GetDevicePublicKey( 57 virtual std::string GetDevicePublicKey(
58 const std::string& bluetooth_address) const; 58 const std::string& bluetooth_address) const;
59 virtual std::string GetDeviceAddress(const std::string& public_key) const; 59 virtual std::string GetDeviceAddress(const std::string& public_key) const;
60 virtual std::vector<std::string> GetPublicKeys() const; 60 virtual std::vector<std::string> GetPublicKeys() const;
61 61
62 // Setter and getter for the timestamp of the last password entry. This
63 // preference is used to enforce reauthing with the password after a given
64 // time period has elapsed.
65 virtual void SetLastPasswordEntryTimestampMs(int64_t timestamp_ms);
66 virtual int64_t GetLastPasswordEntryTimestampMs() const;
67
62 private: 68 private:
63 const base::DictionaryValue* GetRemoteBleDevices() const; 69 const base::DictionaryValue* GetRemoteBleDevices() const;
64 70
65 // Contains perferences that outlive the lifetime of this object and across 71 // Contains perferences that outlive the lifetime of this object and across
66 // process restarts. Not owned and must outlive this instance. 72 // process restarts. Not owned and must outlive this instance.
67 PrefService* pref_service_; 73 PrefService* pref_service_;
68 74
69 DISALLOW_COPY_AND_ASSIGN(ProximityAuthPrefManager); 75 DISALLOW_COPY_AND_ASSIGN(ProximityAuthPrefManager);
70 }; 76 };
71 77
72 } // namespace proximity_auth 78 } // namespace proximity_auth
73 79
74 #endif // COMPONENTS_PROXIMITY_AUTH_PROXIMITY_AUTH_PREF_MANAGER_H 80 #endif // COMPONENTS_PROXIMITY_AUTH_PROXIMITY_AUTH_PREF_MANAGER_H
OLDNEW
« no previous file with comments | « chrome/browser/signin/easy_unlock_service_regular.cc ('k') | components/proximity_auth/proximity_auth_pref_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698