| Index: chrome/browser/chromeos/cros/cryptohome_library.cc
|
| diff --git a/chrome/browser/chromeos/cros/cryptohome_library.cc b/chrome/browser/chromeos/cros/cryptohome_library.cc
|
| index 8655f3650d6846b7ff21e110168e6d99d68887fa..19b799a5737330ee7a220f16786844432f7002e7 100644
|
| --- a/chrome/browser/chromeos/cros/cryptohome_library.cc
|
| +++ b/chrome/browser/chromeos/cros/cryptohome_library.cc
|
| @@ -11,12 +11,10 @@
|
| #include "base/string_util.h"
|
| #include "chromeos/dbus/cryptohome_client.h"
|
| #include "chromeos/dbus/dbus_thread_manager.h"
|
| -#include "crypto/sha2.h"
|
|
|
| namespace {
|
|
|
| const char kStubSystemSalt[] = "stub_system_salt";
|
| -const int kPassHashLen = 32;
|
|
|
| }
|
|
|
| @@ -127,21 +125,6 @@ class CryptohomeLibraryImpl : public CryptohomeLibrary {
|
| return result;
|
| }
|
|
|
| - virtual std::string HashPassword(const std::string& password) OVERRIDE {
|
| - // Get salt, ascii encode, update sha with that, then update with ascii
|
| - // of password, then end.
|
| - std::string ascii_salt = GetSystemSalt();
|
| - char passhash_buf[kPassHashLen];
|
| -
|
| - // Hash salt and password
|
| - crypto::SHA256HashString(ascii_salt + password,
|
| - &passhash_buf, sizeof(passhash_buf));
|
| -
|
| - return StringToLowerASCII(base::HexEncode(
|
| - reinterpret_cast<const void*>(passhash_buf),
|
| - sizeof(passhash_buf) / 2));
|
| - }
|
| -
|
| virtual std::string GetSystemSalt() OVERRIDE {
|
| LoadSystemSalt(); // no-op if it's already loaded.
|
| return StringToLowerASCII(base::HexEncode(
|
| @@ -234,12 +217,6 @@ class CryptohomeLibraryStubImpl : public CryptohomeLibrary {
|
| return !locked_;
|
| }
|
|
|
| - virtual std::string HashPassword(const std::string& password) OVERRIDE {
|
| - return StringToLowerASCII(base::HexEncode(
|
| - reinterpret_cast<const void*>(password.data()),
|
| - password.length()));
|
| - }
|
| -
|
| virtual std::string GetSystemSalt() OVERRIDE {
|
| return kStubSystemSalt;
|
| }
|
|
|