FontAccess: Replace Sticky Activation with Page Visibility check #25869
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.
This CL replaces the Sticky Activation check for enumeration with a page
visibility check. The attack vector that the sticky activation check was
intended to mitigate is background access to the API.
However, this prevents an intended use-case of the API: e.g. navigating
to a link to open a document will require user activation before content
is show if this API is necessary to render on-screen.
Using a Page Visibility change instead mitigates the same attack vector
while enabling the navigation use-case.
A manual test will be added in a subsequent CL.
Bug: 1043306
Change-Id: Ieb12341f78bceec94907fb577f3c969ae839abdd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2439496
Reviewed-by: Joshua Bell <jsbell@chromium.org>
Reviewed-by: Martin Barbella <mbarbella@chromium.org>
Reviewed-by: Balazs Engedy <engedy@chromium.org>
Commit-Queue: Olivier Yiptong <oyiptong@chromium.org>
Cr-Commit-Position: refs/heads/master@{#812279}