Agent skill

csp

Content Security Policy configuration, nonces, and reporting.

Stars 163
Forks 31

Install this agent skill to your Project

npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/csp

SKILL.md

CSP Skill

Expert assistance for Content Security Policy implementation.

Capabilities

  • Configure CSP headers
  • Implement nonces
  • Set up reporting
  • Handle inline scripts
  • Configure strict CSP

CSP Configuration

typescript
// Next.js middleware
const cspHeader = `
  default-src 'self';
  script-src 'self' 'nonce-${nonce}' 'strict-dynamic';
  style-src 'self' 'nonce-${nonce}';
  img-src 'self' blob: data:;
  font-src 'self';
  connect-src 'self';
  frame-ancestors 'none';
  base-uri 'self';
  form-action 'self';
  report-uri /api/csp-report;
`;

Target Processes

  • security-hardening
  • csp-implementation
  • xss-prevention

Expand your agent's capabilities with these related and highly-rated skills.

Didn't find tool you were looking for?

Be as detailed as possible for better results