New issue
Advanced search Search tips

Issue 787115 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug



Sign in to add a comment

NoScript not working for http request that commits as https request

Project Member Reported by dougarnett@chromium.org, Nov 20 2017

Issue description

Need to handle navigations that start at http but end up as https
 
Project Member

Comment 1 by bugdroid1@chromium.org, Nov 27 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9bb50615e0855d215edc5a45ac379f483584e020

commit 9bb50615e0855d215edc5a45ac379f483584e020
Author: Doug Arnett <dougarnett@chromium.org>
Date: Mon Nov 27 18:20:45 2017

Fix NoScript Preview to work for HTTP nav that resolves to HTTPS

This change now sets the NOSCRIPT_ON bit in PreviewsState at the
beginning of a HTTP navigation (as well as HTTPS). It then checks
the final URL in ResourceLoader::CompletedResponseStarted in order
to affect the PreviewsState value in the response to the renderer
(set in call to PopulateResourceResponse). It clears the bit if
the final URL is HTTP but leaves it set if HTTPS (thus fixing a
current bug).

I was hoping to find a better place to put this logic but didn't
find any current delegate type call point that happens in time
to affect the WebURLResponse. Perhaps some better options with
more design and rework.

Note: the NOSCRIPT_ON bit will only be set if the dev flag
for it is enabled (ie, not default behavior).

Bug:  787115 
Change-Id: Ie330e34c722c07271648f7370dfacc81495ec97b
Reviewed-on: https://chromium-review.googlesource.com/782384
Reviewed-by: Matt Menke <mmenke@chromium.org>
Reviewed-by: Tarun Bansal <tbansal@chromium.org>
Commit-Queue: Doug Arnett <dougarnett@chromium.org>
Cr-Commit-Position: refs/heads/master@{#519342}
[modify] https://crrev.com/9bb50615e0855d215edc5a45ac379f483584e020/chrome/browser/loader/chrome_resource_dispatcher_host_delegate.cc
[modify] https://crrev.com/9bb50615e0855d215edc5a45ac379f483584e020/chrome/browser/previews/previews_browsertest.cc
[modify] https://crrev.com/9bb50615e0855d215edc5a45ac379f483584e020/chrome/browser/previews/previews_infobar_tab_helper.cc
[modify] https://crrev.com/9bb50615e0855d215edc5a45ac379f483584e020/components/previews/content/previews_content_util.cc
[modify] https://crrev.com/9bb50615e0855d215edc5a45ac379f483584e020/components/previews/content/previews_content_util_unittest.cc

Status: Fixed (was: Started)

Comment 3 by efoo@chromium.org, Dec 5 2017

Components: Blink>Previews

Comment 4 by efoo@chromium.org, Dec 5 2017

Components: -UI>Browser>Previews

Sign in to add a comment