Skip to content
Multi-Tool Security Sandbox

Interactive Web Security Lab

Real-time simulators for evaluating Content Security Policies, CORS preflight handshakes, XSS sanitization engines, SameSite cookie scopes, and UI framing defenses.

Configure CSP DirectivesCSP Level 3

Controls trusted script sources.
Include Cryptographic Nonce
Generated HTTP Header:
Content-Security-Policy: default-src 'self'; script-src 'self' https://trusted-cdn.com; style-src 'self' 'unsafe-inline'; connect-src 'self' https://api.my-app.com; frame-ancestors 'none';

Live Asset Evaluation Matrix

1. First-Party App ScriptALLOWED
https://my-app.com/static/bundle.js (self)
Allowed by 'self' origin.
2. Inline Script Tag (<script>alert(1)</script>)BLOCKED
inline code block
Blocked: script-src restricts inline scripts without matching nonce.
3. Approved CDN Script (trusted-cdn.com)ALLOWED
https://trusted-cdn.com/lib/react.js
Allowed by host allowlist (https://trusted-cdn.com).
4. Third-Party Tracker (evil-analytics.com)BLOCKED
https://evil-analytics.com/tracker.js
Refused to load script from https://evil-analytics.com/tracker.js: violated script-src directive.
5. Backend API Fetch CallALLOWED
https://api.my-app.com/v1/user
Allowed by host allowlist (https://api.my-app.com).
6. Embedded Iframe Framing RequestBLOCKED
https://partner-portal.com
Blocked from framing by frame-ancestors 'none'.