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

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

Issue 2905343002: Show interstitial on a password on focus ping with PHISHING verdict. (Closed)
Patch Set: nit 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_service.h
diff --git a/components/safe_browsing/password_protection/password_protection_service.h b/components/safe_browsing/password_protection/password_protection_service.h
index 7060bb20c2f71ae93120f514335ffeb768fd89d8..4800ae9739fa5218cb7543626f299e8a033736a3 100644
--- a/components/safe_browsing/password_protection/password_protection_service.h
+++ b/components/safe_browsing/password_protection/password_protection_service.h
@@ -39,6 +39,7 @@ class PasswordProtectionRequest;
extern const base::Feature kPasswordFieldOnFocusPinging;
extern const base::Feature kProtectedPasswordEntryPinging;
+extern const base::Feature kPasswordProtectionInterstitial;
extern const char kPasswordOnFocusRequestOutcomeHistogramName[];
extern const char kPasswordEntryRequestOutcomeHistogramName[];
@@ -68,6 +69,7 @@ class PasswordProtectionService : public history::HistoryServiceObserver {
URL_NOT_VALID_FOR_REPUTATION_COMPUTING = 14,
MAX_OUTCOME
};
+
PasswordProtectionService(
const scoped_refptr<SafeBrowsingDatabaseManager>& database_manager,
scoped_refptr<net::URLRequestContextGetter> request_context_getter,
@@ -89,9 +91,9 @@ class PasswordProtectionService : public history::HistoryServiceObserver {
// Stores |verdict| in |settings| based on |url|, |verdict| and
// |receive_time|.
- void CacheVerdict(const GURL& url,
- LoginReputationClientResponse* verdict,
- const base::Time& receive_time);
+ virtual void CacheVerdict(const GURL& url,
+ LoginReputationClientResponse* verdict,
+ const base::Time& receive_time);
// Removes all the expired verdicts from cache.
void CleanUpExpiredVerdicts();
@@ -141,6 +143,7 @@ class PasswordProtectionService : public history::HistoryServiceObserver {
// itself from |requests_|.
virtual void RequestFinished(
PasswordProtectionRequest* request,
+ bool already_cached,
std::unique_ptr<LoginReputationClientResponse> response);
// Cancels all requests in |requests_|, empties it, and releases references to
@@ -181,6 +184,10 @@ class PasswordProtectionService : public history::HistoryServiceObserver {
virtual bool IsHistorySyncEnabled() = 0;
+ virtual void ShowPhishingInterstitial(const GURL& phishing_url,
+ const std::string& token,
+ content::WebContents* web_contents) = 0;
+
void CheckCsdWhitelistOnIOThread(const GURL& url, bool* check_result);
HostContentSettingsMap* content_settings() const { return content_settings_; }

Powered by Google App Engine
This is Rietveld 408576698