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

Side by Side Diff: components/safe_browsing/base_blocking_page.cc

Issue 2950863002: Implement code for Start/Finish threat details collection in WebView. (Closed)
Patch Set: fix comment Created 3 years, 5 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 unified diff | Download patch
« no previous file with comments | « components/safe_browsing/base_blocking_page.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 #include "components/safe_browsing/base_blocking_page.h" 5 #include "components/safe_browsing/base_blocking_page.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/lazy_instance.h" 8 #include "base/lazy_instance.h"
9 #include "base/memory/ptr_util.h" 9 #include "base/memory/ptr_util.h"
10 #include "base/strings/string_number_conversions.h" 10 #include "base/strings/string_number_conversions.h"
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after
355 355
356 int BaseBlockingPage::GetHTMLTemplateId() { 356 int BaseBlockingPage::GetHTMLTemplateId() {
357 return sb_error_ui_->GetHTMLTemplateId(); 357 return sb_error_ui_->GetHTMLTemplateId();
358 } 358 }
359 359
360 void BaseBlockingPage::set_sb_error_ui( 360 void BaseBlockingPage::set_sb_error_ui(
361 std::unique_ptr<BaseSafeBrowsingErrorUI> sb_error_ui) { 361 std::unique_ptr<BaseSafeBrowsingErrorUI> sb_error_ui) {
362 sb_error_ui_ = std::move(sb_error_ui); 362 sb_error_ui_ = std::move(sb_error_ui);
363 } 363 }
364 364
365 // static
366 bool BaseBlockingPage::ShouldReportThreatDetails(SBThreatType threat_type) {
367 return threat_type == SB_THREAT_TYPE_URL_PHISHING ||
368 threat_type == SB_THREAT_TYPE_URL_MALWARE ||
369 threat_type == SB_THREAT_TYPE_URL_UNWANTED ||
370 threat_type == SB_THREAT_TYPE_URL_CLIENT_SIDE_PHISHING ||
371 threat_type == SB_THREAT_TYPE_URL_CLIENT_SIDE_MALWARE ||
372 threat_type == SB_THREAT_TYPE_URL_PASSWORD_PROTECTION_PHISHING;
373 }
374
365 } // namespace safe_browsing 375 } // namespace safe_browsing
OLDNEW
« no previous file with comments | « components/safe_browsing/base_blocking_page.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698