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

Side by Side Diff: chrome/browser/safe_browsing/browser_feature_extractor.h

Issue 8400050: Include the HTTP status code as a feature in the ClientPhishingRequest. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/safe_browsing/browser_feature_extractor.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // BrowserFeatureExtractor computes various browser features for client-side 5 // BrowserFeatureExtractor computes various browser features for client-side
6 // phishing detection. For now it does a bunch of lookups in the history 6 // phishing detection. For now it does a bunch of lookups in the history
7 // service to see whether a particular URL has been visited before by the 7 // service to see whether a particular URL has been visited before by the
8 // user. 8 // user.
9 9
10 #ifndef CHROME_BROWSER_SAFE_BROWSING_BROWSER_FEATURE_EXTRACTOR_H_ 10 #ifndef CHROME_BROWSER_SAFE_BROWSING_BROWSER_FEATURE_EXTRACTOR_H_
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 // If a SafeBrowsing interstitial was shown for the current URL 42 // If a SafeBrowsing interstitial was shown for the current URL
43 // this will contain the UnsafeResource struct for that URL. 43 // this will contain the UnsafeResource struct for that URL.
44 scoped_ptr<SafeBrowsingService::UnsafeResource> unsafe_resource; 44 scoped_ptr<SafeBrowsingService::UnsafeResource> unsafe_resource;
45 45
46 // List of redirects that lead to the first page on the current host and 46 // List of redirects that lead to the first page on the current host and
47 // the current url respectively. These may be the same if the current url 47 // the current url respectively. These may be the same if the current url
48 // is the first page on its host. 48 // is the first page on its host.
49 std::vector<GURL> host_redirects; 49 std::vector<GURL> host_redirects;
50 std::vector<GURL> url_redirects; 50 std::vector<GURL> url_redirects;
51 51
52 // The HTTP status code from this navigation.
53 int http_status_code;
54
52 BrowseInfo(); 55 BrowseInfo();
53 ~BrowseInfo(); 56 ~BrowseInfo();
54 }; 57 };
55 58
56 // All methods of this class must be called on the UI thread (including 59 // All methods of this class must be called on the UI thread (including
57 // the constructor). 60 // the constructor).
58 class BrowserFeatureExtractor { 61 class BrowserFeatureExtractor {
59 public: 62 public:
60 // Called when feature extraction is done. The first argument will be 63 // Called when feature extraction is done. The first argument will be
61 // true iff feature extraction succeeded. The second argument is the 64 // true iff feature extraction succeeded. The second argument is the
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 std::set<ExtractionData> pending_extractions_; 156 std::set<ExtractionData> pending_extractions_;
154 157
155 // Set of pending queries (i.e., where history->Query...() was called but 158 // Set of pending queries (i.e., where history->Query...() was called but
156 // the history callback hasn't been invoked yet). 159 // the history callback hasn't been invoked yet).
157 PendingQueriesMap pending_queries_; 160 PendingQueriesMap pending_queries_;
158 161
159 DISALLOW_COPY_AND_ASSIGN(BrowserFeatureExtractor); 162 DISALLOW_COPY_AND_ASSIGN(BrowserFeatureExtractor);
160 }; 163 };
161 } // namespace safe_browsing 164 } // namespace safe_browsing
162 #endif // CHROME_BROWSER_SAFE_BROWSING_BROWSER_FEATURE_EXTRACTOR_H_ 165 #endif // CHROME_BROWSER_SAFE_BROWSING_BROWSER_FEATURE_EXTRACTOR_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/safe_browsing/browser_feature_extractor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698