New issue
Advanced search Search tips

Issue 711443 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 3
Type: Feature

Blocked on:
issue 623682
issue 713364

Blocking:
issue 699790
issue 492204


Participants' hotlists:
USB


Sign in to add a comment

Integrate WebUSB with Feature Policy

Project Member Reported by reillyg@chromium.org, Apr 13 2017

Issue description

Tracking issue for integrating WebUSB with Feature Policy.

 
Blocking: 699790
Project Member

Comment 2 by bugdroid1@chromium.org, Apr 14 2017

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

commit f809e180a16f5b87c3eb36101ffa342dc4e9bf0c
Author: reillyg <reillyg@chromium.org>
Date: Fri Apr 14 22:31:39 2017

Hide USB service unavailability from web content

This changes the handling of Mojo service connection errors so that they
are treated as if the service were present but returned no devices
instead of surfacing a specific failure message for this case.

This simplifies content_shell-based tests for WebUSB.

BUG= 711443 

Review-Url: https://codereview.chromium.org/2813903007
Cr-Commit-Position: refs/heads/master@{#464811}

[modify] https://crrev.com/f809e180a16f5b87c3eb36101ffa342dc4e9bf0c/third_party/WebKit/Source/modules/webusb/USB.cpp

Blockedon: 713364
Project Member

Comment 4 by bugdroid1@chromium.org, May 12 2017

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

commit aee98b5c7aebe3c263f2150357d36901efbf0d53
Author: reillyg <reillyg@chromium.org>
Date: Fri May 12 23:31:11 2017

Integrate WebUSB with Feature Policy

This patch uses the new Feature Policy framework to control access to
WebUSB from embedded frames. When Feature Policy is available WebUSB's
default policy ["self"] is enforced. When it isn't available WebUSB is
simply disallowed in embedded frames.

A follow-up patch will remove the parser for the "allowed origins"
descriptor as they are no longer used and have been removed from the
specification.

BUG= 711443 

Review-Url: https://codereview.chromium.org/2815003005
Cr-Commit-Position: refs/heads/master@{#471487}

[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/DEPS
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/usb_browsertest.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/usb_chooser_controller.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/usb_chooser_controller.h
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/usb_chooser_controller_unittest.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/usb_tab_helper.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/usb_tab_helper.h
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/web_usb_permission_provider.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/chrome/browser/usb/web_usb_permission_provider.h
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/content/common/feature_policy/feature_policy.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/device/usb/mojo/device_impl.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/device/usb/mojo/device_impl_unittest.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/device/usb/mojo/mock_permission_provider.cc
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/device/usb/mojo/mock_permission_provider.h
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/device/usb/mojo/permission_provider.h
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/resources/check-availability.html
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/resources/featurepolicytest.js
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/usb-allowed-by-feature-policy-attribute.https.sub.html
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/usb-allowed-by-feature-policy.https.sub.html
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/usb-allowed-by-feature-policy.https.sub.html.headers
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/usb-default-feature-policy.https.sub.html
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/usb-disabled-by-feature-policy.https.sub.html
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/LayoutTests/external/wpt/webusb/usb-disabled-by-feature-policy.https.sub.html.headers
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/Source/modules/webusb/USB.cpp
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp
[modify] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/public/platform/WebFeaturePolicy.h
[add] https://crrev.com/aee98b5c7aebe3c263f2150357d36901efbf0d53/third_party/WebKit/public/platform/WebFeaturePolicyFeature.h

Status: Fixed (was: Started)
Project Member

Comment 6 by bugdroid1@chromium.org, May 17 2017

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

commit aa72d98b41a08607308b1f1ccb9604fff36aa432
Author: Reilly Grant <reillyg@chromium.org>
Date: Wed May 17 20:52:52 2017

Remove support for WebUSB "allowed origin" descriptors

With the integration with Feature Policy these descriptors are no longer
used.

BUG= 711443 

Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation
Change-Id: Ia6978ce2855bd4228ddaa2471c613c446d9d67b2
Reviewed-on: https://chromium-review.googlesource.com/505414
Reviewed-by: Christopher Lam <calamity@chromium.org>
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: David Trainor <dtrainor@chromium.org>
Reviewed-by: Vincent Scheib <scheib@chromium.org>
Commit-Queue: Reilly Grant <reillyg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#472557}
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/chrome/browser/resources/usb_internals/usb_internals.html
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/chrome/browser/resources/usb_internals/usb_internals.js
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/chrome/browser/ui/android/usb_chooser_dialog_android.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/chrome/browser/ui/webui/usb_internals/usb_internals.mojom
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/chrome/browser/ui/webui/usb_internals/usb_internals_page_handler.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/chrome/browser/ui/webui/usb_internals/usb_internals_page_handler.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/mock_usb_device.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_device.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_device_android.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_device_android.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_device_impl.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_device_linux.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_service_impl.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/usb_service_linux.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/webusb_descriptors.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/webusb_descriptors.h
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/webusb_descriptors_fuzzer.cc
[modify] https://crrev.com/aa72d98b41a08607308b1f1ccb9604fff36aa432/device/usb/webusb_descriptors_unittest.cc

Sign in to add a comment