Consider exposing QUIC preconnections to Web Request API.
Reported by
amiag...@gmail.com,
Apr 25 2017
|
|||||||
Issue descriptionUserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.81 Safari/537.36 Steps to reproduce the problem: The Quick UDP Internet Connections (QUIC) protocol is actively used by Chrome for ad tracking purposes: https://blog.brave.com/quic-in-the-wild-for-google-ad-advantage/ What is the expected behavior? What went wrong? QUIC requests are not available to (privacy, ad blocking, network debugging) extensions. Furthermore, they are not visible in the Network pane of Developer Tools. Did this work before? N/A Does this work in other browsers? N/A Chrome version: 58.0.3029.81 Channel: stable OS Version: Flash Version: Shockwave Flash 25.0 r0 This is a similar problem to the unavailablity of WebSockets (fix in progress: https://bugs.chromium.org/p/chromium/issues/detail?id=129353) and WebRTC requests. The common thread is that Chrome should expose nearly all network traffic to extensions and Developer Tools, but does not. Whether intentional or not, this feels like a privacy-last approach.
,
Apr 25 2017
Or not? "Breakage can be intermittent depending upon whether QUIC or TCP is selected. http://Youtube.com was where we originally found QUIC use" https://twitter.com/lukemulks/status/856896086752886785
,
Apr 25 2017
My understanding is that that blog post has some inaccuracies in it, but routing to the QUIC team for specific evaluation.
,
Apr 25 2017
Agreed. Manual testing shows that ad blocking extensions do the right thing when QUIC is in use. Of course, software has bugs so please feel free to re-open if you find a repro.
,
Apr 25 2017
I built a quic (pun intended) Chrome extension to see if I could repro the issue: https://github.com/diracdeltas/quic-request. It uses webRequest's onBeforeRequest listener to cancel all requests matching the filter '*://*.doubleclick.net/*'. I loaded the extension into Chrome, enabled QUIC in chrome://flags, loaded up youtube.com, and still saw doubleclick QUIC requests in chrome://net-internals (screenshot attached).
,
Apr 25 2017
Re #5: Do you have the network log (https://dev.chromium.org/for-testers/providing-network-details) for this case and/or did you look at the Events tab in chrome://net-internals to see the flow of events?
,
Apr 25 2017
With the extension in #5, I can repro the display of a googleads.g.doubleclick.net entry in the chrome://net-internals/#events&q=type:QUIC_SESSION%20is:active list. However, I suspect this is an expected result where we believe the connection is going to be needed later so we preconnnect: 205: HTTP_STREAM_JOB_CONTROLLER https://googleads.g.doubleclick.net/ Start Time: 2017-04-25 17:53:42.816 t=316 [st= 0] +HTTP_STREAM_JOB_CONTROLLER [dt=160] --> is_preconnect = true --> url = "https://googleads.g.doubleclick.net/" t=316 [st= 0] HTTP_STREAM_REQUEST_STARTED_JOB --> source_dependency = 206 (HTTP_STREAM_JOB) t=476 [st=160] -HTTP_STREAM_JOB_CONTROLLER ... but ultimately by the time we get around to issuing the request, it's not, because the extension kills it: 662: URL_REQUEST https://googleads.g.doubleclick.net/pagead/id Start Time: 2017-04-25 17:53:46.111 t=3611 [st=0] +REQUEST_ALIVE [dt=1] --> priority = "MEDIUM" --> url = "https://googleads.g.doubleclick.net/pagead/id" t=3611 [st=0] +URL_REQUEST_DELEGATE [dt=1] t=3611 [st=0] DELEGATE_INFO [dt=1] --> delegate_blocked_by = "extension QUIC webRequest tester" t=3612 [st=1] CHROME_EXTENSION_ABORTED_REQUEST --> extension_id = "ejjcjbmlghojblfopokjfdfabplkhicc" We do not, as far as I know, provide extensions with control over preconnections.
,
Apr 25 2017
Re #6, here is a network log generated after restarting Chrome Stable and loading youtube.com
,
Apr 25 2017
Re #8: Yes, the json you shared matches my findings. We see a few preconnections to the target servers, but all of the subsequent URL_REQUESTs are blocked with
CHROME_EXTENSION_ABORTED_REQUEST
--> extension_id = "dljphincejbibbfhepmphieaojbopkih"
ERR_BLOCKED_BY_CLIENT
,
Apr 25 2017
Re #9: thanks for looking at this. Indeed I see that the QUIC preconnection starts at t=29057, and the doubleclick ad request starts at t=31563 and is cancelled at t=31569 by the extension. The QUIC session stays open for a while after that and then is closed with:
t=58214 [st=29157] QUIC_SESSION_CLOSED
--> from_peer = false
--> quic_error = 25 (QUIC_NETWORK_IDLE_TIMEOUT)
t=58214 [st=29157] QUIC_SESSION_CLOSED
--> from_peer = false
--> quic_error = 25 (QUIC_NETWORK_IDLE_TIMEOUT)
,
Apr 26 2017
Reopening this, and assigning to the privacy team to discuss the narrower question about whether or not extensions should control preconnects. My impression is that there's very little privacy implication to a socket connection in itself (and, honestly, I'm not even sure what a "preconnect" means in this context, given QUIC's 0-RTT mechanisms; are we doing a TLS handshake? Just warming up a socket?). rdevlin.cronin@: FYI.
,
Apr 26 2017
(Actually reopening/renaming)
,
Apr 26 2017
Issue 715249 has been merged into this issue.
,
Apr 26 2017
> whether or not extensions should control preconnects Maybe this could depends on whether the setting chrome.privacy.network.networkPredictionEnabled is false? (i.e. if false, extensions are called before preconnect).
,
Apr 26 2017
Re #11: Yes, a cryptographic handshake is performed; you can see this in the chrome://net-internals log data, but I'm not convinced that this itself has a privacy implication.
,
Apr 26 2017
It does seem to have some privacy implications. For instance a tracking domain can see the IP addresses of all clients that are running a tracker blocker that is preventing connections to them. Whether there are other implications beyond that deserves some thought. Would the preconnections transmit TLS Channel IDs? SNI headers? If yes there's a bit more risk that these preconnections could be used for unblockable nefarious purposes.
,
Apr 26 2017
RE #16: The "IP addresses of all clients" concern wouldn't be unique to QUIC, it would also apply to traditional HTTPS-over-TCP/IP. I'm not sure I understand the concern about SNI headers, since an "attacker" could simply name their host anything they like.
,
Apr 27 2017
My involvement in privacy is reduced and in Web Request is null. I see this looping in more appropriate people, so removing myself.
,
May 26 2017
Apologies for the delay in my reply. I second mkwst@ and elawrence@ on their assessment that preconnect does not need to be controllable by the webRequest API, since there aren't privacy implications w.r.t. data being sent. The only privacy implication, as peter.eckersley@ noted, is the pure fact that a connection is being made, i.e. that the client reveals its existence to a server. However, this particular issue is independent of QUIC, and it's the reason why we have the "network prediction" setting. An ad blocker extension which cares about not revealing its presence to the web can simply use the chrome.privacy.network.networkPredictionEnabled API to disable it. This should address rhill@'s suggestion above too - the preconnection should not happen in the first place if the setting is false.
,
May 26 2017
And to double-check, +igrigorik@, can you please confirm that QUIC preconnect respects network prediction?
,
Nov 7
I discovered an issue today where chrome.webRequest.onBeforeRequest is not reliably capturing requests for httpVersion: http/2.0+quic/43 The handler detects Google Image Proxy requests (*://*.googleusercontent.com/*) containing tracking pixels in its hash fragment, blocking the proxied request, and issuing the de-proxied request. For affected users, the handler does not detect any matching requests. Disabling the enable-quic flag allowed the handler to capture the request. This is not consistent, however, as enabling the flag in my browser does not reproduce the bug. Both of our enable-quic flags were initially set to Default, and I confirmed that we were on the same extension version, so I suspect some users are on an experiment. Is this related to this issue?
,
Nov 8
Disabling enable-quic flag does not resolve the issue for all affected users. Some users report using Chrome Dev as a workaround. Attached is a HAR file where the extension failed to capture and cancel the request. |
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by amiag...@gmail.com
, Apr 25 2017