-
Notifications
You must be signed in to change notification settings - Fork 464
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
Added sandbox attribute to Safe App iframe #1252
Conversation
ESLint Summary View Full Report
Report generated by eslint-plus-action |
Branch preview |
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.
👍
Deploying with Cloudflare Pages
|
@JagoFigueroa found that some links are not working (like twitter links) To address this issue I added this |
Espectacular trabajo compañero, todo bueno 😉 |
Congrats, your important contribution to this open-source project has earned you a GitPOAP! GitPOAP: 2022 Safe Web Core Contributor: Head to gitpoap.io & connect your GitHub account to mint! Learn more about GitPOAPs here. |
What it solves
Resolves #1246
How this PR fixes it
Added a
sandbox
attribute to the Safe Apps iframe in the pastWe discussed in this Problem Statement the possibility of adding the sandbox attribute in the iframe.
Allowed features
allow-scripts
: Lets the resource run scripts (needed for all the Safe Apps)allow-same-origin
: Needed to the same-origin policy (Most of Safe App access to data storage/cookies and some JavaScript APIs).allow-forms
: Allows Safe Apps to submit forms. Example: Transaction Builder Safe Appallow-orientation-lock
: Lets the resource lock the screen orientation.allow-popups
: Most of Safe Apps, to allow new tab redirections (Etherscan links, docs links...)allow-popups-to-escape-sandbox
: Allows a sandboxed document to open new windows without forcing the sandboxing flags upon them (needed for some redirections like twitter see:)Restrictions
You can not access to the parent Safe localStorage directly from a Safe App:
Preventing top-level navigation:
How to test it
Screenshots