Content Security Policy Playground

The Pos Ronda gate: each arrival matched to a CSP directive, then in a test frame your own browser decides which style and image load. unsafe-inline, nonce…

Why it matters

A CSP is the second layer against XSS: if there is a hole and a <script> is slipped into the page, a strict CSP makes the browser refuse it. But one wrong token, like 'unsafe-inline' or a missing default-src, quietly switches the protection off. Knowing how the browser matches each source lets you write a rule that really guards.

The key idea

A CSP lists what may come in, not what is banned

Common mistakes

Try it in this playground