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

Unified Diff: components/autofill/browser/password_generator.h

Issue 17392006: In components/autofill, move browser/ to core/browser/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to fix conflicts Created 7 years, 6 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: components/autofill/browser/password_generator.h
diff --git a/components/autofill/browser/password_generator.h b/components/autofill/browser/password_generator.h
deleted file mode 100644
index 0872bee023b7f4622962d400acc2254c83c2da95..0000000000000000000000000000000000000000
--- a/components/autofill/browser/password_generator.h
+++ /dev/null
@@ -1,48 +0,0 @@
-// Copyright (c) 2012 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.
-
-#ifndef COMPONENTS_AUTOFILL_BROWSER_PASSWORD_GENERATOR_H_
-#define COMPONENTS_AUTOFILL_BROWSER_PASSWORD_GENERATOR_H_
-
-#include <string>
-
-#include "base/basictypes.h"
-#include "base/gtest_prod_util.h"
-
-namespace autofill {
-
-// Class to generate random passwords. Currently we just use a generic algorithm
-// for all sites, but eventually we can incorporate additional information to
-// determine passwords that are likely to be accepted (i.e. use pattern field,
-// previous generated passwords, crowdsourcing, etc.)
-class PasswordGenerator {
- public:
- // |max_length| is used as a hint for the generated password's length.
- explicit PasswordGenerator(size_t max_length);
- ~PasswordGenerator();
-
- // Returns a random password such that:
- // (1) Each character is guaranteed to be a non-whitespace printable ASCII
- // character.
- // (2) The generated password will contain AT LEAST one upper case letter, one
- // lower case letter, one digit, and EXACTLY one other symbol.
- // (3) The password length will be equal to |password_length_| (see comment
- // for the constructor).
- // Not thread safe.
- std::string Generate() const;
-
- private:
- // Unit test also need to access |kDefaultPasswordLength|.
- static const size_t kDefaultPasswordLength;
- FRIEND_TEST_ALL_PREFIXES(PasswordGeneratorTest, PasswordLength);
-
- // The length of the generated password.
- const size_t password_length_;
-
- DISALLOW_COPY_AND_ASSIGN(PasswordGenerator);
-};
-
-} // namespace autofill
-
-#endif // COMPONENTS_AUTOFILL_BROWSER_PASSWORD_GENERATOR_H_
« no previous file with comments | « components/autofill/browser/password_autofill_manager_unittest.cc ('k') | components/autofill/browser/password_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698