api-integration
Use this skill when the user says 'API integration', 'connect APIs', 'sync data', 'data mapping', 'rate limiting', or needs…
Use this skill when the user says 'CSP', 'Content-Security-Policy', 'security headers', 'HSTS', 'X-Frame-Options', 'clickjacking', 'unsafe-inline', 'unsafe-eval', or needs to audit, generate, or fix HTTP security headers for a web application. Do NOT use for API route audits or
$ npx -y skills add cwinvestments/memstack --skill csp-headers --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/csp-headersContext preview
The summary Claude sees to decide when to auto-load this skill.
Use this skill when the user says 'CSP', 'Content-Security-Policy', 'security headers', 'HSTS', 'X-Frame-Options', 'clickjacking', 'unsafe-inline', 'unsafe-eval', or needs to audit, generate, or fix HTTP security headers for a web application. Do NOT use for API route audits or
name: memstack-security-csp-headers description: "Use this skill when the user says 'CSP', 'Content-Security-Policy', 'security headers', 'HSTS', 'X-Frame-Options', 'clickjacking', 'unsafe-inline', 'unsafe-eval', or needs to audit, generate, or fix HTTP security headers for a web application. Do NOT use for API route audits or dependency scanning." version: 1.0.0 license: "Proprietary, MemStack™ Pro by CW Affiliate Investments LLC. See LICENSE.txt"
*Audit existing security headers, identify overly permissive directives, and generate a production-ready Content-Security-Policy with companion headers.*
When this skill activates, output:
`🛡️ CSP Headers: Auditing your security headers...`
| Context | Status | |---------|--------| | **User says "CSP", "security headers", "Content-Security-Policy"** | ACTIVE | | **User wants to fix unsafe-inline, unsafe-eval, or wildcard directives** | ACTIVE | | **User mentions HSTS, X-Frame-Options, or Permissions-Policy** | ACTIVE | | **User wants a full OWASP security audit (not just headers)** | DORMANT: see owasp-top10 | | **User wants to scan for secrets in code** | DORMANT: see secrets-scanner | | **User wants API-level security (auth, rate limiting)** | DORMANT: see api-audit |
Ask the user for:
Check for CSP and security headers in all possible locations:
**Where to look:** 1. **Middleware**: Express/Next.js middleware setting response headers 2. **Config files**: `next.config.js` (`headers()` function), `nginx.conf`, `Caddyfile` 3. **Meta tags**: `<meta http-equiv="Content-Security-Policy" content="...">` in HTML 4. **Hosting config**: `vercel.json`, `netlify.toml`, `_headers` file 5. **Reverse proxy**: Nginx/Caddy/Apache header directives
── EXISTING HEADERS FOUND ───────────────── Location: [file:line or "not found"] Content-Security-Policy: [current policy or "MISSING"] Strict-Transport-Security: [current value or "MISSING"] X-Content-Type-Options: [current value or "MISSING"] X-Frame-Options: [current value or "MISSING"] Referrer-Policy: [current value or "MISSING"] Permissions-Policy: [current value or "MISSING"] X-XSS-Protection: [current value or "MISSING, deprecated but still useful for older browsers"]
If a CSP exists, audit each directive for security issues:
| Directive | Current Value | Issue | Severity | Fix | |-----------|--------------|-------|----------|-----| | `default-src` | `*` | Allows loading from any origin | 🔴 Critical | Restrict to known origins | | `script-src` | `'unsafe-inline'` | Allows inline scripts, XSS vector | 🔴 Critical | Use nonces or hashes | | `script-src` | `'unsafe-eval'` | Allows dynamic code execution, injection risk | 🟡 High | Remove, refactor code | | `style-src` | `'unsafe-inline'` | Allows inline styles, less severe | 🟠 Medium | Use nonces if feasible | | `img-src` | `*` | Allows images from any origin | 🟠 Medium | Restrict to known CDNs | | `frame-ancestors` | missing | No clickjacking protection | 🟡 High | Add `'self'` or `'none'` | | `connect-src` | missing | No restriction on fetch/XHR targets | 🟠 Medium | Restrict to API origins | | `base-uri` | missing | Base tag injection possible | 🟡 High | Add `'self'` | | `form-action` | missing | Forms can submit to any origin | 🟠 Medium | Add `'self'` | | `object-src` | missing | Plugin content allowed | 🟡 High | Add `'none'` |
**Common dangerous patterns:**
BAD: default-src * → Defeats the entire purpose of CSP BAD: script-src 'unsafe-inline' → XSS protection nullified BAD: script-src 'unsafe-eval' → Dynamic code execution permitted BAD: script-src https: → Any HTTPS origin can serve scripts BAD: script-src *.googleapis.com → JSONP endpoints can bypass CSP BAD: connect-src * → Data exfiltration unrestricted BAD: frame-ancestors not set → Clickjacking possible
Identify all external resources the application loads:
── RESOURCE INVENTORY ───────────────────── Scripts (script-src): - https://www.googletagmanager.com: Google Tag Manager - https://js.stripe.com: Stripe.js - https://cdn.jsdelivr.net: jsDelivr CDN - 'self': Own domain scripts Styles (style-src): - https://fonts.googleapis.com: Google Fonts CSS - 'self': Own stylesheets - 'unsafe-inline': Needed for: [reason] Fonts (font-src): - https://fonts.gstatic.com: Google Fonts files - 'self': Self-hosted fonts Images (img-src): - https://res.cloudinary.com: Cloudinary images - https://*.githubusercontent.com: GitHub avatars - data:: Data URI images - 'self': Own images Connections (connect-src): - https://api.example.com: Own API - https://api.stripe.com: Stripe API - https://www.google-analytics.com: Analytics - 'self': Same-origin requests Frames (frame-src): - https://js.stripe.com: Stripe checkout iframe - https://www.youtube.com: Embedded videos - 'none': If no iframes needed
The structured skill framework for Claude Code: 131 professional skills for deployment, security, databases, content, marketing, and more. Skills activate automatically when you need them. Say "deploy this to Railway" and the right skill loads on demand.
Use this skill when the user says 'API integration', 'connect APIs', 'sync data', 'data mapping', 'rate limiting', or needs…
Use this skill when the user says 'content pipeline', 'content automation', 'auto-publish', 'repurpose content', 'multi-platform…
Use this skill when the user says 'cron job', 'scheduled task', 'run every', 'cron expression', 'recurring job', or needs…
Use when the user says 'what MCP servers', 'find an MCP for', 'hosted MCP', 'list MCP servers', 'MCP catalog', 'available MCP…
Use this skill when the user says 'n8n workflow', 'build a workflow', 'automation workflow', 'connect services', or needs visual…
Use this skill when the user says 'webhook', 'webhook handler', 'webhook endpoint', 'receive events', 'HMAC verification',…