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

Creating a blob in an iframe, then navigating the iframe to that blob url, then accessing the iframe contents from parent document, gets SecurityError #25080

Open
pshaughn opened this issue Dec 4, 2019 · 2 comments
Labels
A-content/script Related to the script thread

Comments

@pshaughn
Copy link
Member

pshaughn commented Dec 4, 2019

WPT html/webappapis/dynamic-markup-insertion/opening-the-input-stream/location-set-and-document-open.html attempts this. The iframe in question is created by createElement, so it's presumably about:blank initially, which could complicate the matter of determining the blob's origin.

Instead of either seeing the expected PASS or the unexpected-but-possible FAIL in the iframe's textContent, this test just gets a SecurityError trying to read into the iframe. Chrome and Edge also fail this test, but not via SecurityError.

@pshaughn
Copy link
Member Author

pshaughn commented Dec 4, 2019

Based on an experience I had a couple years ago with making the blob API work across browsers, I would guess that the Chrome TIMEOUT on this test is because of expiring the blob URL too early. I don't think that would ever give a SecurityError though, so our problem is probably origin-related and not expiration-related.

@jdm jdm added the A-content/script Related to the script thread label Dec 4, 2019
@jdm jdm added this to To do in web-platform-test failures via automation Dec 4, 2019
@jdm
Copy link
Member

jdm commented Dec 4, 2019

We might be treating the blob URL as cross-origin to the iframe's parent's document when we load it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-content/script Related to the script thread
Projects
Development

No branches or pull requests

2 participants