-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
proposed change for #402 #407
Closed
Closed
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
b37e0ea
proposed change for #402
ShijunS d5e8ffb
proposed change for #402
ShijunS 387ca28
proposed change for #402
ShijunS 86616df
change storedDeviceList to an internal slot
ShijunS 407ef8c
make [[\storedDeviceList]] operations more concise
ShijunS 2cb0bad
edits based on input from @adam-be
ShijunS File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This removes all permission requirements for the devicechange event, which I don't think we agreed to.
I think we need to keep this, and an exception for the active tab that has input focus. Something like:
", or the active document in the current browsing context is fully active and has focus, then"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jan-ivar, I'll update this part based on your input.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I still haven't figured out a situation where protecting the devicechange event gives any real protection (see previous discussion). Until I see such a scenario, I am in favor of removing all coupling between the devicechange event and the deviceinfo permission.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alvestrand arguing for going further than this PR, is not a reason to hold up this PR I think.
This PR removes permission for the active tab and aligns enumerateDevices with the firing of the event, like we do with other events.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alvestrand I would be against going further. If I have, say, 100 tabs open across 3 separate brand browsers, and pull out my USB device, and we signal all tabs about that immediately, that's a fairly strong timing signal to all those tabs' JS that I might be the same user, in spite of every other precaution I might have taken to be anonymous (including using separate browsers, VPNs, denying cookies, and any tracking-protecting private browsing modes).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should add virtual machines to that list, if they have USB hooked up.