CSP Allow-list Experiment

AI-generated summary of reporting by Simon Willison’s Weblog. Read the original for the full story.

Why it matters

Simon Willison demonstrates a pattern for safely running untrusted AI-generated apps in sandboxed iframes with user-approved API access, but it is an experiment, not a product.

Read this as

Simon Willison built a small web demo called the CSP Allow-list Experiment. A Content Security Policy (CSP) is a browser rule that blocks a web page from talking to outside servers; here, an app runs inside a locked-down iframe, and when it tries to reach a blocked site like api.inaturalist.org, the parent window asks the user to approve it. Willison says he built it with GPT-5.5 in the Codex desktop app.

Willison published a working demo, built with GPT-5.5 in the Codex desktop app, showing a pattern for running untrusted code safely: an app in a CSP-restricted sandboxed iframe, with blocked fetch() requests intercepted and surfaced to the user for allow-list approval. It is an experiment posted on his blog, not a product or framework, so there is no direct cost or competitive impact; its value is as a reference pattern for sandboxing AI-generated apps.

The demo loads an app in a CSP-protected sandboxed iframe with default-src 'none' and script-src 'unsafe-inline', following Willison's earlier iframe-escape test. A custom fetch() wrapper catches CSP violations (e.g. connect-src blocks on https://api.inaturalist.org), postMessages them to the parent, which prompts the user to add the origin to a connect-src allow-list before refreshing the preview. Built with GPT-5.5 xhigh in Codex; no code release or benchmarks mentioned.

Read the original

This summary exists to save you time, not to replace the source.

Key terms

Simon Willison CSP Allow-list Experiment GPT-5.5 Codex desktop app api.inaturalist.org api.github.com

Was this summary useful?

One click, anonymous. It tells us which summaries to re-run.

Related reading