summaryrefslogtreecommitdiffstats
path: root/chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc
diff options
context:
space:
mode:
authorrvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-14 17:37:14 +0000
committerrvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-14 17:37:14 +0000
commit4b559b4ddffc0b7f688019bcb80658f05e063af7 (patch)
tree0be21d8914de707f5125d2cb66733cbcf088606c /chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc
parent056dd45d610de34312344445d7b078a31f4a1e20 (diff)
downloadchromium_src-4b559b4ddffc0b7f688019bcb80658f05e063af7.zip
chromium_src-4b559b4ddffc0b7f688019bcb80658f05e063af7.tar.gz
chromium_src-4b559b4ddffc0b7f688019bcb80658f05e063af7.tar.bz2
Move crypto files out of base, to a top level directory.
src/crypto is now an independent project that contains our cryptographic primitives (except md5 and sha1). This removes the base dependency from nss, openssl and sqlite. BUG=76996 TEST=none Review URL: http://codereview.chromium.org/6805019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81611 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc')
-rw-r--r--chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc b/chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc
index dbb72f5..251cc75 100644
--- a/chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc
+++ b/chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 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.
@@ -10,10 +10,10 @@
#include "base/compiler_specific.h"
#include "base/logging.h"
#include "base/message_loop.h"
-#include "base/sha2.h"
#include "base/metrics/histogram.h"
#include "base/time.h"
#include "base/utf_string_conversions.h"
+#include "crypto/sha2.h"
#include "chrome/renderer/safe_browsing/feature_extractor_clock.h"
#include "chrome/renderer/safe_browsing/features.h"
#include "ui/base/l10n/l10n_util.h"
@@ -200,7 +200,7 @@ void PhishingTermFeatureExtractor::ExtractFeaturesWithTimeout() {
void PhishingTermFeatureExtractor::HandleWord(const string16& word) {
std::string word_lower = UTF16ToUTF8(l10n_util::ToLower(word));
- std::string word_hash = base::SHA256HashString(word_lower);
+ std::string word_hash = crypto::SHA256HashString(word_lower);
// Quick out if the word is not part of any term, which is the common case.
if (page_word_hashes_->find(word_hash) == page_word_hashes_->end()) {
@@ -234,7 +234,7 @@ void PhishingTermFeatureExtractor::HandleWord(const string16& word) {
std::string current_term = state_->previous_words;
for (std::list<size_t>::iterator it = state_->previous_word_sizes.begin();
it != state_->previous_word_sizes.end(); ++it) {
- hashes_to_check[base::SHA256HashString(current_term)] = current_term;
+ hashes_to_check[crypto::SHA256HashString(current_term)] = current_term;
current_term.erase(0, *it);
}