3 ms·
why not just put the ads in a srcdoc+sandbox iframe. that way it can be loaded inline but runs on a null origin, preventing access to the page itself.
by the8472 10y ago
why not just put the ads in a srcdoc+sandbox iframe. that way it can be loaded inline but runs on a null origin, preventing access to the page itself.
- shakna 10y agoWhat about the risks if you serve something that breaks out of the sandbox?
- the8472 10y agothen the origin security model of the browser is broken and you have much bigger problems than just some ads.
- Twirrim 10y agoWell, yeah, but ads are the most likely attack vector.
- the8472 10y agoI would argue that relying on SOP isolation is more reliable than attempting to patch over the ads running in the same page context in the first place. The threat model changes quite a bit if we assume the attacker has a SOP exploit.