New issue
Advanced search Search tips

Issue 913242 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner: ----
Closed: Dec 10
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug-Regression



Sign in to add a comment

chrome.webRequest.onBeforeSendHeaders can't change Referer in Chrome 71

Reported by human.p...@gmail.com, Dec 9

Issue description

UserAgent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.80 Safari/537.36

Steps to reproduce the problem:
1. Load the attached unpacked extension.
2. Try to open any website and observe the headers. For example, https://nghttp2.org/httpbin/headers

What is the expected behavior?
A referer header should be added with value "Test".

What went wrong?
It isn't. According to https://developer.chrome.com/extensions/webRequest, you need to add "extraHeaders" option to modify Referer starting from 72, but that shouldn't be the case for 71.

Actually, 71 doesn't even support "extraHeaders" option yet (will throw error).

Did this work before? Yes 

Does this work in other browsers? Yes

Chrome version: 71.0.3578.80  Channel: stable
OS Version: 6.1 (Windows 7, Windows Server 2008 R2)
Flash Version:
 
test.js
392 bytes View Download
manifest.json
280 bytes View Download
Ok, so it is pretty weird now. I installed both stable with beta and tested again.

It works fine in stable, but not in Beta, despite they have exactly same version number (71.0.3578.80).

(Please ignore the "Chrome version: 71.0.3578.80  Channel: stable" above; I actually have bug in "Beta" version, NOT stable).

Working chrome://version:

Google Chrome	71.0.3578.80 (Official Build) (64-bit) (cohort: 71_Win_80)
Full info: https://gist.github.com/fireattack/fd7300a71ab3f6ee2cde6578d1e7f62d

Bugged chrome://version:

Google Chrome	71.0.3578.80 (Official Build) beta (64-bit) (cohort: Beta)
Full info: https://gist.github.com/fireattack/a3525d37eff6e6e93616fb738b488e10


Labels: Needs-Triage-M71
Cc: viswa.karala@chromium.org
Labels: Triaged-ET Needs-Feedback
Tried testing the issue on chrome reported version# 71.0.3578.80 using windows-10 with steps mentioned below:
1) Launched chrome reported version and loaded the extension file in chrome://extensions
2) Navigated to page: https://nghttp2.org/httpbin/headers, seen same bahaviour on stable and beta, find attached screencast for reference

@Reporter: Please find the attached screencast for your reference and let us know if we missed anything in reproducing the issue, provide your feedback on it which help in further triaging it in better way.

Thanks!
913242.mp4
2.1 MB View Download
Thanks for the testing.

I can't spot anything wrong in your sreencat, it has the exact steps as I had. The only difference is you're testing on Win 10, and I did it on Win 7. 

It might be related to one of many A/B test switches, too.
Project Member

Comment 5 by sheriffbot@chromium.org, Dec 10

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Components: Platform>Extensions
Labels: -Hotlist-Interop
In order to see which experiment is enabled in which profile, you can go to -
chrome://version/?show-variations-cmd

You can compare the output when you have this issue and when you do not have this issue and report back.
Thanks! Not sure how to compare, but I pasted them here:

https://gist.github.com/fireattack/346caeeede5a32c4741c13078540a6e2
Status: WontFix (was: Unconfirmed)
I replaced every , with ,\n and every / with /\n and compared using https://www.diffnow.com/ - I found that NetworkService is enabled in the bad one, which makes sense (I would be surprised if it were enabled by default for some users on stable, though, but maybe the development is mostly done).

Why does it make sense? Because this NetworkService experiment is a radical change to the network stack (moving it out of the browser process and into its own process, if I understand correctly) and webRequest is, well, very related to the network stack.

Also, this was announced, as it turns out -
https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/bbac59f9-ea9e-4e1d-83b8-8341fe0dec50%40chromium.org?utm_medium=email&utm_source=footer
>Also, this was announced, as it turns out 

I mentioned this in my initial report already:

"According to https://developer.chrome.com/extensions/webRequest, you need to add "extraHeaders" option to modify Referer starting from 72, but that shouldn't be the case for 71."

It was announced to be changed in 72, not in 71, isn't it? 

And I can't use the "new" way either because 'extraHeaders' is not supported in this version (which I also mentioned).

"Actually, 71 doesn't even support "extraHeaders" option yet (will throw error)."
All in all: I understand the situation; but is there anyway to make it work in my Beta Chrome 71? Like manually turn off this experiment?

Thanks.
Bummer :(
Try going to chrome://flags/#network-service and disabling it.
Thank you, will give it a try later.

Sign in to add a comment