New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 598059 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Apr 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 1
Type: Bug

Blocking:
issue 565736
issue 598890



Sign in to add a comment

bluetooth: Add a kill switch

Project Member Reported by jyasskin@chromium.org, Mar 25 2016

Issue description

Per https://docs.google.com/document/d/1nepYzsXq3B37e7yFznpewIBn8p7bs_Y_GDKBq2yvHBw/edit?usp=sharing, we need to either implement the Web Bluetooth permission in terms of PermissionContextBase or add the following code in our critical path.

Since PermissionContextBase will store device information on disk, we probably don't want to enable it until the revocation UI is hooked up, which might take longer than M-51.


 if (variations::GetVariationParamValue(
      “PermissionsKillSwitch”,"Bluetooth") == “blocked”) {
   // Log to the developer console.
    web_contents->GetMainFrame()->AddMessageToConsole(
        content::CONSOLE_MESSAGE_LEVEL_LOG,
        base::StringPrintf(
            "%s permission has been blocked.",
            <name of your permission>));
    // The kill switch is enabled for this permission; Block requests.
    return CONTENT_SETTING_BLOCK;
}
 
Blocking: 598890
Project Member

Comment 2 by bugdroid1@chromium.org, Mar 31 2016

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

commit c993ce8db282755a85b9671638ba24de0c5ca946
Author: jyasskin <jyasskin@chromium.org>
Date: Thu Mar 31 00:38:34 2016

Add a kill switch for all of Web Bluetooth.

This is temporary until we get Web Bluetooth behind
PermissionContextBase, but that may block on getting some UI done, so I
don't want to bet on it happening by M51.

BUG= 598059 

Review URL: https://codereview.chromium.org/1841763002

Cr-Commit-Position: refs/heads/master@{#384162}

[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/chrome/browser/OWNERS
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/chrome/browser/chrome_content_browser_client.cc
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/chrome/browser/chrome_content_browser_client.h
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/chrome/browser/permissions/permission_context_base.h
[add] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/chrome/browser/web_bluetooth_browsertest.cc
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/chrome/chrome_tests.gypi
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/content/browser/bluetooth/bluetooth_dispatcher_host.cc
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/content/browser/bluetooth/bluetooth_metrics.h
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/content/public/browser/content_browser_client.cc
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/content/public/browser/content_browser_client.h
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/third_party/WebKit/Source/modules/bluetooth/BluetoothError.cpp
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom
[modify] https://crrev.com/c993ce8db282755a85b9671638ba24de0c5ca946/tools/metrics/histograms/histograms.xml

Status: Fixed (was: Assigned)

Sign in to add a comment