Intent to Ship: Web Permissions API on WebView

30 views
Skip to first unread message

Peter Birk Pakkenberg

unread,
8:00 AM (2 hours ago) 8:00 AM
to blink-dev, Peter Beverloo, eng...@chromium.org

Specification

https://w3c.github.io/permissions/


Summary


This Intent to Ship covers the launch of the Web Permission API in WebView, an API that has already launched in other browsers and embedders.


WebView has a more limited permission model than other embedders, namely, it doesn’t support separating “checking permission state” from “requesting permissions”, and the Permission API implementation we ship will reflect this. In particular, the API will respond with “denied” for APIs that are not supported by WebView, “granted” for permissions that WebView automatically grants (midi, sensors) and “prompt” for APIs where permission is handled by sending a callback to the WebView-embedding app (camera, microphone, midi-sysex). WebView does offer support for persistent permissions for the Geolocation API, so in apps that use that feature, WebView will respond with “granted” or “prompt” depending on the choices made by the embedding app.


Blink component

Blink>PermissionsAPI

Mobile>WebView


TAG review

None


TAG review status

Not applicable


Risks


Interoperability and Compatibility


The API is already implemented in all major browsers. This Intent to Ship covers the launch in WebView.


WebView application risks

Does this intent deprecate or change behaviour of existing APIs, such that it has potentially high risk for Android WebView-based applications?


This launch does not change any existing behaviour in WebView. However, websites should be aware that they will now be able to use the permissions.query API, which was previously not exposed, and for some APIs (microphone, camera, and MIDI SysEx), they will always get a response of “prompt”. This reflects the fact that these permissions are always forwarded to the embedding app.


Debuggability

None



Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?

Yes


Is this feature fully tested by web-platform-tests?

Yes, where results will be published to wpt.fyi


Flag name on chrome://flags

None


Finch feature name

WebPermissionsApi


Requires code in //chrome?

False


Tracking bug

https://issues.chromium.org/issues/348635849


Measurement

Reuse existing use counter for permissions.query.


Availability expectation

Available in all major browsers. This also adds the API to WebView


Adoption expectation

Already widely adopted.


Adoption plan

Already widely adopted.


Non-OSS dependencies

Does the feature depend on any code or APIs outside the Chromium open source repository and its open-source dependencies to function?

No.


Estimated milestones

Shipping on WebView

128





Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).

None


Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/6376494003650560


Reply all
Reply to author
Forward
0 new messages