Skip to content
Back to skills

Aie Web Security

ASecurity

Read-only defensive self-audit of a website or web app for common security gaps — exposed secrets in client code and git history, dependency vulnerabilities, missing or weak HTTP security headers (CSP, HSTS, X-Content-Type-Options, X-Frame-Options), HTTPS/TLS and mixed-content issues, unsafe DOM sinks (innerHTML/XSS), CSRF/cookie and CORS misconfigurations, and privacy-compliance gaps. Produces findings ranked by severity with plain-language fixes. This skill NEVER attacks a live target — it ...

  • 4 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 19, 2026
ai-agentsgitapisecurity

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 4 files and shows the line behind each finding

Scanned December 1, 2026

npx -y skills add mrhinkle/aienterprise-skills --skill aie-web-security --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Aie Web Security?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Aie Web Security
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mrhinkle-aie-web-security/badge)](https://www.skillsdirectory.com/skills/mrhinkle-aie-web-security)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: aie-web-security
description: Read-only defensive self-audit of a website or web app for common security gaps — exposed secrets in client code and git history, dependency vulnerabilities, missing or weak HTTP security headers (CSP, HSTS, X-Content-Type-Options, X-Frame-Options), HTTPS/TLS and mixed-content issues, unsafe DOM sinks (innerHTML/XSS), CSRF/cookie and CORS misconfigurations, and privacy-compliance gaps. Produces findings ranked by severity with plain-language fixes. This skill NEVER attacks a live target — it only reviews code, config, and public response headers you own. Trigger on "security audit," "security review," "security check," "is my site secure," "check for exposed API keys," "audit my security headers," "am I leaking secrets," "check my CSP," "HTTPS/SSL check," "XSS review," or "privacy compliance check."
---

# Web Security Self-Audit (Defensive)

Runs a safe, read-only security review of a website or web app you control. It reviews source code, configuration, dependency manifests, git history, and public response headers. It does not scan, probe, fuzz, or attack anything — this is a self-audit, not a penetration test.

## Scope and Safety Rules

- Only audit assets the user owns or is explicitly authorized to review.
- Read-only. Do not send crafted/malicious payloads, brute-force, or exploit anything.
- Never print full secret values in output — mask them (`re_****…abcd`).
- If asked to attack a third-party site or bypass a control, decline and redirect to the defensive scope.

## Workflow

1. **Confirm scope** — which repo/folder, which deployed URL (if any), and the stack (framework, host, package manager). Stay stack-agnostic; adapt commands to what you find.
2. **Run the checks** in the order below, gathering evidence.
3. **Report** using the severity format at the end.

Read `reference/audit-checklist.md` for the full itemized checklist across all areas. Read `reference/security-headers.md` for header values and host-specific config examples. Read `reference/glossary.md` if the user needs plain-language definitions.

## Check Areas (summary)

1. **Secrets exposure (Critical)** — Grep the working tree AND git history for API keys, tokens, passwords, private keys, connection strings. Confirm `.env*` and `*.pem` are git-ignored and not committed. Confirm secrets live in the host's environment-variable store, not in client-shipped bundles. Any secret prefixed for client exposure (e.g., build-time public vars) must NOT be a real secret. If a live secret is found, flag it Critical and instruct immediate rotation.
2. **Dependencies** — Run the package manager's audit (`npm audit`, `pnpm audit`, `yarn audit`, `pip-audit`, etc.). Classify by severity, note fixable vs. breaking.
3. **Security headers** — Check for Content-Security-Policy, Strict-Transport-Security (HSTS), X-Content-Type-Options, X-Frame-Options (or CSP `frame-ancestors`), Referrer-Policy, and Permissions-Policy. See `reference/security-headers.md`.
4. **HTTPS / TLS** — Certificate validity, single 301 HTTP→HTTPS redirect, HSTS present, no mixed content (HTTP assets on an HTTPS page).
5. **Input handling / XSS** — Flag `innerHTML`, `dangerouslySetInnerHTML`, `document.write`, and unescaped user input rendered to the DOM or into URLs. Recommend `textContent` and `encodeURIComponent`.
6. **CSRF / cookies** — Confirm state-changing endpoints validate origin or use anti-CSRF tokens; confirm cookies set `SameSite` and, for sensitive cookies, `HttpOnly` + `Secure`.
7. **CORS** — Flag wildcard `Access-Control-Allow-Origin: *` on any authenticated or sensitive endpoint.
8. **Third-party scripts** — Inventory external scripts; recommend Subresource Integrity (SRI) and version pinning for CDN resources; note what data analytics/trackers collect.
9. **Abuse prevention** — Confirm public form/serverless endpoints have spam protection (honeypot and/or rate limiting) and reasonable function timeouts.
10. **Privacy compliance** — Confirm a linked privacy policy, disclosure of data collected and third parties used, cookie consent where required, and a contact path for data requests (GDPR/CCPA baseline).

## Output Format

Lead with an overall grade and counts, then list findings.

**Overall: B — 1 critical, 3 warnings, 4 recommendations**

For each finding:
- **Severity** — CRITICAL (fix before launch) / WARNING (fix within a week) / RECOMMENDATION (best practice)
- **What** — the issue, with file path and line or the header that's missing
- **Why it matters** — one plain-language sentence
- **Fix** — exact code, config, or step

Order findings Critical → Warning → Recommendation.

## References

- OWASP Top 10 — https://owasp.org/www-project-top-ten/
- OWASP Secure Headers Project — https://owasp.org/www-project-secure-headers/
- MDN HTTP headers — https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers
- MDN Content Security Policy — https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP
- MDN Mixed content — https://developer.mozilla.org/en-US/docs/Web/Security/Mixed_content

**Sample run:** `examples/sample-run.md` — a condensed real run showing the exact output this skill produces.

Files in this skill

  • SKILL.md5 KB
  • reference/audit-checklist.md3.7 KB
  • reference/glossary.md1.5 KB
  • reference/security-headers.md3.4 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.