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

Unified Diff: components/safe_browsing/password_protection/password_protection_request.h

Issue 2892093003: Don't trigger Phishguard pings if we cannot compute URL reputation. (Closed)
Patch Set: update comments Created 3 years, 7 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/safe_browsing/password_protection/password_protection_request.h
diff --git a/components/safe_browsing/password_protection/password_protection_request.h b/components/safe_browsing/password_protection/password_protection_request.h
index 4995b3d4c3ea09db84a194db39e06d9500023187..89fcf772f4106149d7f3a54b8968350b20fcfc67 100644
--- a/components/safe_browsing/password_protection/password_protection_request.h
+++ b/components/safe_browsing/password_protection/password_protection_request.h
@@ -40,7 +40,8 @@ class PasswordProtectionRequest : public base::RefCountedThreadSafe<
content::BrowserThread::DeleteOnUIThread>,
public net::URLFetcherDelegate {
public:
- PasswordProtectionRequest(const GURL& main_frame_url,
+ PasswordProtectionRequest(content::WebContents* web_contents,
+ const GURL& main_frame_url,
const GURL& password_form_action,
const GURL& password_form_frame_url,
const std::string& saved_domain,
@@ -103,6 +104,9 @@ class PasswordProtectionRequest : public base::RefCountedThreadSafe<
void Finish(PasswordProtectionService::RequestOutcome outcome,
std::unique_ptr<LoginReputationClientResponse> response);
+ // WebContents of the password protection event.
+ content::WebContents* web_contents_;
+
// Main frame URL of the login form.
const GURL main_frame_url_;
@@ -128,10 +132,6 @@ class PasswordProtectionRequest : public base::RefCountedThreadSafe<
// Can only be accessed on UI thread.
PasswordProtectionService* password_protection_service_;
- // Safe Browsing database manager used to look up CSD whitelist.
- // Can only be accessed on IO thread.
- scoped_refptr<SafeBrowsingDatabaseManager> database_manager_;
-
// If we haven't receive response after this period of time, we cancel this
// request.
const int request_timeout_in_ms_;

Powered by Google App Engine
This is Rietveld 408576698