Skip to content
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

Allow connection via WebHID in iframe #107

Merged
merged 1 commit into from
Sep 30, 2021
Merged

Allow connection via WebHID in iframe #107

merged 1 commit into from
Sep 30, 2021

Conversation

danjm
Copy link
Contributor

@danjm danjm commented Sep 28, 2021

This PR is necessary for the use of WebHID in the ledger-bridge

Associated PR: #106

@@ -424,6 +424,7 @@ class LedgerBridgeKeyring extends EventEmitter {
_setupIframe () {
this.iframe = document.createElement('iframe')
this.iframe.src = this.bridgeUrl
this.iframe.allow = `hid 'src'`
Copy link
Member

Choose a reason for hiding this comment

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

Interesting that this wasn't documented on MDN on the list of features this allowlist applies to, but I did find it in the WebHID spec: https://wicg.github.io/webhid/#permissions-policy

Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh, yeah, that's how I found that as well. I should have put that in the PR description.

Copy link
Member

@Gudahtt Gudahtt left a comment

Choose a reason for hiding this comment

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

LGTM!

@danjm danjm merged commit b3d387e into main Sep 30, 2021
@danjm danjm deleted the allow-hid branch September 30, 2021 14:21
julianariel pushed a commit to block-wallet/eth-ledger-bridge-keyring that referenced this pull request Apr 27, 2022
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.

2 participants