Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Issue 2651413002: media: Require SecureContext for EME APIs (prototype) (Closed)

Created:
3 years, 11 months ago by xhwang
Modified:
3 years, 10 months ago
Reviewers:
haraken, Yuki, Mike West, bashi
CC:
chromium-reviews, feature-media-reviews_chromium.org, mlamouri+watch-blink_chromium.org, eric.carlson_apple.com, haraken, blink-reviews, Srirama, jrummell, ddorwin
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

media: Require SecureContext for EME APIs (prototype) $$$ Uploaded for discussion. Not for full review and commit yet. $$$ In this CL requestMediaKeySystemAccess() requires SecureContext. On non-SecureContext, this API will not be visible. BUG=672605 TEST=Manually tested and made sure EME APIs are not available on insecure origins.

Patch Set 1 : Working but I have some questions. #

Patch Set 2 : SecureContext on "readonly attribute MediaKeys mediaKeys" #

Patch Set 3 : SecureContext on "partial interface HTMLMediaElement" #

Unified diffs Side-by-side diffs Delta from patch set Stats (+5 lines, -3 lines) Patch
M third_party/WebKit/Source/modules/encryptedmedia/HTMLMediaElementEncryptedMedia.idl View 1 2 1 chunk +3 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/modules/encryptedmedia/MediaKeys.idl View 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/encryptedmedia/NavigatorRequestMediaKeySystemAccess.idl View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 22 (11 generated)
xhwang
haraken, Yuki, Mike West and bashi: This is work in progress. But I am hitting ...
3 years, 11 months ago (2017-01-26 18:47:50 UTC) #5
xhwang
Then in PS2, I marked mediaKeys attribute on HTMLMeidaElement us SecureContest: [SecureContext] readonly attribute MediaKeys ...
3 years, 11 months ago (2017-01-26 18:55:47 UTC) #8
xhwang
Then in PS3, I marked the whole "partial interface HTMLMediaElement" using SecureContest. I think I ...
3 years, 11 months ago (2017-01-26 19:05:00 UTC) #9
xhwang
jrummell / ddorwin: FYI
3 years, 11 months ago (2017-01-26 19:05:53 UTC) #10
bashi
On 2017/01/26 18:47:50, xhwang_slow wrote: > haraken, Yuki, Mike West and bashi: > > This ...
3 years, 11 months ago (2017-01-27 00:08:36 UTC) #11
xhwang
Thank you for looking into this! Another question. In PS one, some layouts are failing, ...
3 years, 10 months ago (2017-01-27 04:48:07 UTC) #14
Yuki
First of all, the implementation of [SecureContext] is imperfect. https://crrev.com/2634923003 is now facing to mostly ...
3 years, 10 months ago (2017-01-27 07:32:09 UTC) #17
xhwang
On 2017/01/27 07:32:09, Yuki wrote: > First of all, the implementation of [SecureContext] is imperfect. ...
3 years, 10 months ago (2017-02-03 19:52:26 UTC) #18
Yuki
On 2017/02/03 19:52:26, xhwang_slow wrote: > On 2017/01/27 07:32:09, Yuki wrote: > > First of ...
3 years, 10 months ago (2017-02-06 08:24:39 UTC) #20
xhwang
On 2017/02/06 08:24:39, Yuki wrote: > On 2017/02/03 19:52:26, xhwang_slow wrote: > > On 2017/01/27 ...
3 years, 10 months ago (2017-02-06 17:57:42 UTC) #21
Yuki
3 years, 10 months ago (2017-02-09 08:12:09 UTC) #22
On 2017/02/06 17:57:42, xhwang_slow wrote:
> On 2017/02/06 08:24:39, Yuki wrote:
> > On 2017/02/03 19:52:26, xhwang_slow wrote:
> > > On 2017/01/27 07:32:09, Yuki wrote:
> > > > First of all, the implementation of [SecureContext] is imperfect. 
> > > > https://crrev.com/2634923003 is now facing to mostly the same issue;
> > > > [SecureContext] for interfaces is not supported.
> > > > 
> > > > mkwst@, do you have any thoughts on how to proceed this?  Are you going
to
> > > > resume your work on [SecureContext]?
> > > > 
> > > > For layout testing, I vaguely guess that we may need to run the test in
> > > https:. 
> > > > You can put tests in http/tests/... and navigate to https:... if it's
> http:.
> > > 
> > > mkwst@: Kindly ping!
> > > 
> > > For layout testing, currently most tests are running on file:///, which is
> > > treated as SecureContext because we use --allow-file-access-from-files for
> > > layout tests (I guess). So the test isn't a blocking issue at this moment.
> > 
> > Just FYI, layout tests under http/tests/ run with a http server, and other
> tests
> > run without a http server using file:///.  So, if you want to use http: or
> > https:, then put your tests in http/tests/ .  If you're okay with using
> > file:///, that's fine, too.  Just my two cents.
> 
> Thank you so much for the suggestions. Our tests do need to run on https. Do
you
> know how to run http/tests/* on https?
> 
> Currently file:/// seems to work well for my use case. I have an updated CL at
> https://chromiumcodereview.appspot.com/2678433003/

You can navigate to the https: version of the layout tests.  See the following
test for example.
https://cs.chromium.org/chromium/src/third_party/WebKit/LayoutTests/http/test...

Powered by Google App Engine
This is Rietveld 408576698