-
Notifications
You must be signed in to change notification settings - Fork 248
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
Setting sandbox attribute of frame #258
Comments
Hi @th174. You can do:
That said:
If the iframe is on a different domain, that will be impossible anyway, even without |
That's currently how it is, however, because of some unrelated requirements, I might need to reverse proxy the iframe's domain through the parent's domain. In that case, I would need the sandbox to preserve the same separation of permissions. |
Interesting. Could you reverse-proxy onto a subdomain? Otherwise the site will also have same-domain access to any of your server's urls/apis. |
I was hoping to prevent that by revoking allow-same-origin access with the sandbox attribute. Would that not be sufficient? |
That would work, but what if somebody redirects to the page outside of an iframe? Using a subdomain would give an extra layer of security for cases like that. |
Is there some way to set the sandbox attribute of the iframe? Specifically, I want to prevent the child inside the iframe from being able to inject javascript inside the context of the parent.
The text was updated successfully, but these errors were encountered: