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

Issue 1410853003: [Safe Browsing] Only check main frame and iframe URLs on Mobile, for speed. (Closed)

Created:
5 years, 2 months ago by Nathan Parker
Modified:
5 years, 2 months ago
Reviewers:
Lei Zhang, mattm
CC:
chromium-reviews, grt+watch_chromium.org, gsennton
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Only check main frame and iframe URLs on Mobile, to improve page load time. Setup a finch flag to control the resource types we check so we can experiment with speed-vs-protection. It will always check at least main+iframes. Also move some of the per-platform logic down into DatabaseManager impls to remove a number of ifdef's (part of http://crbug.com/542795). BUG=542795, 495806 Committed: https://crrev.com/289e006b7542ef0cc97d57e7e4b754fcb7669c9b Cr-Commit-Position: refs/heads/master@{#355094}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : add tests #

Patch Set 4 : #

Patch Set 5 : Use a comma-separated list of types #

Total comments: 4

Patch Set 6 : Fix tests, fix comment per mattm #

Total comments: 2

Patch Set 7 : nit per thestig #

Patch Set 8 : rm unecessary thread restriction that interferes with tests #

Unified diffs Side-by-side diffs Delta from patch set Stats (+213 lines, -118 lines) Patch
M chrome/browser/renderer_host/safe_browsing_resource_throttle.h View 2 chunks +3 lines, -18 lines 0 comments Download
M chrome/browser/renderer_host/safe_browsing_resource_throttle.cc View 1 2 3 4 5 6 5 chunks +14 lines, -47 lines 0 comments Download
M chrome/browser/safe_browsing/database_manager.h View 1 2 3 4 5 2 chunks +10 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/local_database_manager.h View 1 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/local_database_manager.cc View 1 2 3 4 5 6 1 chunk +10 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/remote_database_manager.h View 1 2 3 4 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/remote_database_manager.cc View 1 2 3 4 5 6 7 4 chunks +48 lines, -4 lines 0 comments Download
A chrome/browser/safe_browsing/remote_database_manager_unittest.cc View 1 2 3 4 1 chunk +98 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/safe_browsing_blocking_page_test.cc View 1 2 3 4 5 1 chunk +8 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/safe_browsing_service.h View 1 2 3 4 5 6 3 chunks +0 lines, -24 lines 0 comments Download
M chrome/browser/safe_browsing/safe_browsing_service.cc View 1 2 3 4 5 6 3 chunks +1 line, -25 lines 0 comments Download
M chrome/browser/safe_browsing/test_database_manager.h View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/test_database_manager.cc View 1 1 chunk +11 lines, -0 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 17 (6 generated)
Nathan Parker
thestig@: Please review safe_browsing_resource_throttle* mattm: Please review safe_browsing/* Thanks.
5 years, 2 months ago (2015-10-17 00:31:03 UTC) #2
mattm
https://codereview.chromium.org/1410853003/diff/80001/chrome/browser/safe_browsing/database_manager.h File chrome/browser/safe_browsing/database_manager.h (right): https://codereview.chromium.org/1410853003/diff/80001/chrome/browser/safe_browsing/database_manager.h#newcode53 chrome/browser/safe_browsing/database_manager.h:53: // allways have some latency. s/allways/always/ https://codereview.chromium.org/1410853003/diff/80001/chrome/browser/safe_browsing/test_database_manager.cc File chrome/browser/safe_browsing/test_database_manager.cc ...
5 years, 2 months ago (2015-10-19 20:19:40 UTC) #3
Nathan Parker
https://codereview.chromium.org/1410853003/diff/80001/chrome/browser/safe_browsing/database_manager.h File chrome/browser/safe_browsing/database_manager.h (right): https://codereview.chromium.org/1410853003/diff/80001/chrome/browser/safe_browsing/database_manager.h#newcode53 chrome/browser/safe_browsing/database_manager.h:53: // allways have some latency. On 2015/10/19 20:19:40, mattm ...
5 years, 2 months ago (2015-10-19 21:03:22 UTC) #4
mattm
lgtm
5 years, 2 months ago (2015-10-19 21:24:02 UTC) #5
Lei Zhang
lgtm https://codereview.chromium.org/1410853003/diff/100001/chrome/browser/renderer_host/safe_browsing_resource_throttle.cc File chrome/browser/renderer_host/safe_browsing_resource_throttle.cc (right): https://codereview.chromium.org/1410853003/diff/100001/chrome/browser/renderer_host/safe_browsing_resource_throttle.cc#newcode77 chrome/browser/renderer_host/safe_browsing_resource_throttle.cc:77: } else { nit: no else after return.
5 years, 2 months ago (2015-10-19 23:26:00 UTC) #6
Nathan Parker
Thanks! https://codereview.chromium.org/1410853003/diff/100001/chrome/browser/renderer_host/safe_browsing_resource_throttle.cc File chrome/browser/renderer_host/safe_browsing_resource_throttle.cc (right): https://codereview.chromium.org/1410853003/diff/100001/chrome/browser/renderer_host/safe_browsing_resource_throttle.cc#newcode77 chrome/browser/renderer_host/safe_browsing_resource_throttle.cc:77: } else { On 2015/10/19 23:26:00, Lei Zhang ...
5 years, 2 months ago (2015-10-19 23:48:13 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1410853003/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1410853003/120001
5 years, 2 months ago (2015-10-19 23:50:02 UTC) #10
commit-bot: I haz the power
Try jobs failed on following builders: linux_android_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_android_rel_ng/builds/84077)
5 years, 2 months ago (2015-10-20 01:20:16 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1410853003/140001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1410853003/140001
5 years, 2 months ago (2015-10-20 16:53:55 UTC) #15
commit-bot: I haz the power
Committed patchset #8 (id:140001)
5 years, 2 months ago (2015-10-20 17:41:20 UTC) #16
commit-bot: I haz the power
5 years, 2 months ago (2015-10-20 17:42:11 UTC) #17
Message was sent while issue was closed.
Patchset 8 (id:??) landed as
https://crrev.com/289e006b7542ef0cc97d57e7e4b754fcb7669c9b
Cr-Commit-Position: refs/heads/master@{#355094}

Powered by Google App Engine
This is Rietveld 408576698