Skip to content

Add permission policy integration#112

Merged
marcoscaceres merged 13 commits into
gh-pagesfrom
sagoston/feature-policy
Oct 29, 2020
Merged

Add permission policy integration#112
marcoscaceres merged 13 commits into
gh-pagesfrom
sagoston/feature-policy

Conversation

@marcoscaceres

@marcoscaceres marcoscaceres commented Sep 23, 2019

Copy link
Copy Markdown
Member

@marcoscaceres marcoscaceres changed the title added feautre policy section Add feature policy integration Sep 23, 2019
@marcoscaceres marcoscaceres force-pushed the sagoston/feature-policy branch from 4b6926f to 082254a Compare September 23, 2019 05:33

@JamesHollyer JamesHollyer left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gamepad events also need protection. We should simply put something like "Events will not be fired unless the feature policy "gamepad" is enabled."

@marcoscaceres

Copy link
Copy Markdown
Member Author

Gamepad events also need protection. We should simply put something like "Events will not be fired unless the feature policy "gamepad" is enabled."

good point! I forgot they fire on the Window object.

@JamesHollyer JamesHollyer left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to see an issue number that gets closed by this change. But the change itself looks good to me.
Also fyi, I am currently implementing the metric for gamepad use in cross origin sub frames so we have more info on how to move forward with this breaking change.

@marcoscaceres

Copy link
Copy Markdown
Member Author

I would like to see an issue number that gets closed by this change.

#119 - once we have the telemetry data, we can move on the tests and implementation commitments.

Comment thread index.html Outdated
Marcos Cáceres and others added 2 commits October 25, 2019 20:58
@marcoscaceres marcoscaceres changed the title Add feature policy integration Add permission policy integration Jul 17, 2020
@marcoscaceres marcoscaceres merged commit 792597d into gh-pages Oct 29, 2020
@marcoscaceres marcoscaceres deleted the sagoston/feature-policy branch October 29, 2020 22:58
@greggman

Copy link
Copy Markdown

broke a few hundred or thousand games on itch.io

@nondebug

Copy link
Copy Markdown
Collaborator

Which browser? As far as I know this change isn't enforced yet in Chrome or Firefox.

Can you link to an example of a game that was broken?

@greggman

Copy link
Copy Markdown

You're right. There's just a warning. So they'll all break in a few months but not today

@reillyeon

Copy link
Copy Markdown
Member

According to their documentation itch.io hosts web games by embedding an iframe. This is why this change will break a number of games but also means that the fix is simple. itch.io needs to add "gamepad" to the existing allow attribute in the <iframe> tags on their pages. They already appear to allow a number of other capabilities through this attribute so it seems that they understand how Permissions Policy works. If I'm correct then this shouldn't require any changes on the part of individual game authors. The change can be made unilaterally by itch.io.

@subsoap

subsoap commented Feb 9, 2021

Copy link
Copy Markdown

I have contacted the itch.io admin about this via e-mail. If the change is not done in a few days someone else should try pinging him via social media until he notices. He has been responsive about adding needed permissions before so it will likely be done before this is enforced.

@greggman

greggman commented Feb 9, 2021

Copy link
Copy Markdown

@reillyeon

Copy link
Copy Markdown
Member

Pinging @jpmedley for the MDN update. This change hasn't shipped in Chrome or Firefox but we've started to show a console warning so a note in MDN would be helpful as well.

@subsoap

subsoap commented Feb 10, 2021

Copy link
Copy Markdown

Gamepad permission has now been added to itch.io iframe. ✨

@byersdz

byersdz commented Feb 28, 2021

Copy link
Copy Markdown

I've added an allow="gamepad" attribute to the iframes on https://bitmelo.com however I am still getting this warning in Chrome. Am I handling this correctly or is there something else I need to do?

@nondebug

nondebug commented Mar 1, 2021

Copy link
Copy Markdown
Collaborator

@byersdz I tried Katana in Chrome 88.0.4324.182 (Official Build) (64-bit) but didn't see any gamepad-related console messages. I checked the source and everything seems fine.

Can you share the text of the console warning?

@reillyeon

Copy link
Copy Markdown
Member

I saw the message when I loaded https://bitmelo.com, I think I understand the issue and have filed https://crbug.com/1183491 to track the fix.

@subsoap

subsoap commented Jul 24, 2021

Copy link
Copy Markdown

Is this required yet? When adding the permission to iframes (allow="gamepad") it still prints

Unrecognized feature: 'gamepad'.

But it also still mentions

VM17:1 getGamepad will now require a Permission Policy. Please update your application accordingly. For more information see #112

Seen here in console

https://www.pixcade.com/big-klondike/

@marcoscaceres

Copy link
Copy Markdown
Member Author

@subsoap, I believe it should be "coming soon". @JamesHollyer, any update?

@marcoscaceres

Copy link
Copy Markdown
Member Author

Filed WebKit bug https://bugs.webkit.org/show_bug.cgi?id=230136 ... will implement that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature policy integration

9 participants