[mediacapture-main] enumerateDevices' access model is unclear

jan-ivar has just created a new issue for 
https://github.com/w3c/mediacapture-main:

== enumerateDevices' access model is unclear ==
>From [the 
spec](http://w3c.github.io/mediacapture-main/getusermedia.html#methods-2):

> If none of the local devices are attached to an active 
MediaStreamTrack, let filteredList be a copy of resultList, and all 
its elements, where the label member is the empty string.

Taken literally, this exposes the label to all concurrently open tabs 
during active gUM use in *any* tab regardless of site, which is not 
what we mean, because [it further 
says](http://w3c.github.io/mediacapture-main/getusermedia.html#access-control-model):

> The algorithm described above means that the access to media device 
information depends on whether or not permission has been granted to 
the page's origin to use media devices.

This narrows access down to a page's origin, but is fuzzy about the 
duration of access, wrt whether access is afforded outside active use 
(MediaStreamTracks are stopped), or when persistent permission has 
been (previously) granted.

These statements seem quite contradictory in their description about 
what matters for access, and neither matches gUM permissions which are
 afforded, not even per page, but, *per instance* and not per origin 
(unless permanent access is granted). 

Questions:
1. Open same jsfiddle in two tabs, grant access in one and deny in the
 other. Who sees label?
2. Open different jsfiddle's in two tabs, grant access in one and deny
 in the other. Who sees label?
3. Stop the MediaStream. Can you still see label?
4. Never start a MediaStream, but persistent permissions were granted 
on a previous visit. See label?
5. Never start a MediaStream, but persistent permissions were granted 
on a previous visit to another page on the same host. See label?


See https://github.com/w3c/mediacapture-main/issues/142

Received on Saturday, 21 February 2015 05:38:59 UTC