question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Need to be able to set `sandbox` property to empty string

See original GitHub issue

I have an application using this component which renders a PDF inside an IFRAME. This component seems to set the sandbox property (at least in Chrome) to be wide open:

sandbox="allow-forms allow-pointer-lock allow-popups allow-same-origin allow-scripts allow-top-navigation"

I had to remove this component and replace it with a basic HTML <iframe> tag to get the PDF to render so I could set the sandbox attribute to be blank.

Help?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
robbestadcommented, Sep 24, 2018

Good idea, will implement!

man. 24. sep. 2018 kl. 19:18 skrev gtwilliams03 notifications@github.com:

[Edit] This does allow setting the sandbox property to “something” but it does not allow the value to be empty. I question whether a blank sandbox value should be the default?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/svenanders/react-iframe/issues/35#issuecomment-424054627, or mute the thread https://github.com/notifications/unsubscribe-auth/ABfQp4rdoYGl7ijzzh1IQ4WvYpfXamVMks5ueRP_gaJpZM4W3GBa .

– Mvh, Sven Anders Robbestad https://www.robbestad.com http://www.robbestad.com/

0reactions
gtwilliams03commented, Sep 27, 2018

I updated and all is well with me! Many, many thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Need to be able to set sandbox property to empty string #35
I have an application using this component which renders a PDF inside an IFRAME. This component seems to set the sandbox property (at...
Read more >
Add HTML5 sandbox attribute to an iframe using Javascript
href) i need to set the attribute sandbox="allow-forms allow-scripts allow-same-origin , because the framed site "deframes". How to set location ...
Read more >
Play safely in sandboxed IFrames - web.dev
Constructing a rich experience on today's web almost unavoidably involves embedding components and content over which you have no real ...
Read more >
HTML DOM IFrame sandbox Property - W3Schools
The sandbox attribute is used to enable security restrictions for iframes with untrusted content (such as scripts and forms). If specified as an...
Read more >
iFrame sandbox permissions tutorial | Google Cloud Blog
We'll need to be able to serve both HTML and JS for this demo. To do this, I whipped up a function to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found