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

Unified Diff: chrome/browser/password_manager/password_manager_util.cc

Issue 23140005: Added of new UMA signals in order to be able to discover early if the "save password" feature gets … (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Additional minor changes Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/password_manager/password_manager_util.cc
diff --git a/chrome/browser/password_manager/password_manager_util.cc b/chrome/browser/password_manager/password_manager_util.cc
new file mode 100644
index 0000000000000000000000000000000000000000..a586f894b0ddbf784e30a8bd49472a2961e14699
--- /dev/null
+++ b/chrome/browser/password_manager/password_manager_util.cc
@@ -0,0 +1,24 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/password_manager/password_manager_util.h"
+
+#include "base/strings/string_util.h"
+
+namespace PasswordManagerUtil {
+
+bool IsDomainNameMonitored(const std::string& url_host,
+ std::string& domain_name) {
+ domain_name.clear();
+
+ for (std::string::size_type i = 0; i < kMonitoredDomainNameLength; ++i) {
+ if (EndsWith(url_host, kMonitoredDomainName[i], true)) {
+ domain_name = kMonitoredDomainName[i];
+ return true;
+ }
+ }
+ return false;
+}
+
+} // namespace PasswordManagerUtil

Powered by Google App Engine
This is Rietveld 408576698