Fill in source lists per directive to build a Content-Security-Policy header value — or paste an existing policy below to load it into the fields. Runs entirely in your browser.
curl -sS -X POST https://devops.majbase.com/csp-builder/api -H "Content-Type: application/json" -d '{"action":"build","directives":{"default-src":"'"'"'self'"'"'","script-src":"'"'"'self'"'"' https://cdn.example.com"}}'
curl -sS -X POST https://devops.majbase.com/csp-builder/api -H "Content-Type: application/json" -d '{"action":"parse","policy":"default-src '"'"'self'"'"'; script-src '"'"'self'"'"' https://cdn.example.com"}'
Build returns {"result": "..."}. Parse returns {"directives": {...}}. directives values can be a space-separated string or an array.