Disable view source for Developer Tools.
[chromium-blink-merge.git] / chrome / browser / password_manager / password_manager_util.h
blob69b633b8d9891c3693845f89ca3f6f98c49355af
1 // Copyright 2013 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 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_MANAGER_UTIL_H_
6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_MANAGER_UTIL_H_
8 #include "base/basictypes.h"
9 #include "ui/gfx/native_widget_types.h"
11 namespace password_manager_util {
13 enum OsPasswordStatus {
14 PASSWORD_STATUS_UNKNOWN = 0,
15 PASSWORD_STATUS_UNSUPPORTED,
16 PASSWORD_STATUS_BLANK,
17 PASSWORD_STATUS_NONBLANK,
18 PASSWORD_STATUS_WIN_DOMAIN,
19 // NOTE: Add new status types only immediately above this line. Also,
20 // make sure the enum list in tools/histogram/histograms.xml is
21 // updated with any change in here.
22 MAX_PASSWORD_STATUS
25 // Attempts to (re-)authenticate the user of the OS account. Returns true if
26 // the user was successfully authenticated, or if authentication was not
27 // possible. On platforms where reauthentication is not possible or does not
28 // make sense, the default implementation always returns true.
29 bool AuthenticateUser(gfx::NativeWindow window);
31 // Query the system to determine whether the current logged on user has a
32 // password set on their OS account. Returns one of the OsPasswordStatus
33 // enum values.
34 OsPasswordStatus GetOsPasswordStatus();
36 } // namespace password_manager_util
38 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_MANAGER_UTIL_H_