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

Unified Diff: chrome/browser/safe_browsing/safe_browsing_blocking_page.h

Issue 4822002: Send malware reports when a user opts-in from the safe browsing interstitial ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years 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: chrome/browser/safe_browsing/safe_browsing_blocking_page.h
===================================================================
--- chrome/browser/safe_browsing/safe_browsing_blocking_page.h (revision 68800)
+++ chrome/browser/safe_browsing/safe_browsing_blocking_page.h (working copy)
@@ -39,6 +39,7 @@
class DictionaryValue;
class MessageLoop;
class SafeBrowsingBlockingPageFactory;
+class MalwareDetails;
class TabContents;
class SafeBrowsingBlockingPage : public InterstitialPage {
@@ -104,6 +105,16 @@
// SBInterstitial[Phishing|Malware|Multiple][Show|Proceed|DontProceed].
void RecordUserAction(BlockingPageEvent event);
+ // See if we should even show the malware details option. For example, we
+ // don't show it in incognito mode.
+ bool CanShowMalwareDetailsOption();
+
+ // Called when the insterstitial is going away. If there is a
+ // pending malware details object, we look at the user's
+ // preferences, and if the option to send malware details is
+ // enabled, the report is scheduled to be sent on the |sb_service_|.
+ void FinishMalwareDetails();
+
// A list of SafeBrowsingService::UnsafeResource for a tab that the user
// should be warned about. They are queued when displaying more than one
// interstitial at a time.
@@ -136,6 +147,11 @@
// The list of unsafe resources this page is warning about.
UnsafeResourceList unsafe_resources_;
+ // A MalwareDetails object that we start generating when the
+ // blocking page is shown. The object will be sent when the warning
+ // is gone (if the user enables the feature).
+ scoped_refptr<MalwareDetails> malware_details_;
+
// The factory used to instanciate SafeBrowsingBlockingPage objects.
// Usefull for tests, so they can provide their own implementation of
// SafeBrowsingBlockingPage.
« no previous file with comments | « chrome/browser/safe_browsing/report.proto ('k') | chrome/browser/safe_browsing/safe_browsing_blocking_page.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698