Comprehensive security vulnerability scanner for Next.js and TypeScript/JavaScript projects. Detects OWASP Top 10 vulnerabilities, XSS, injection flaws, authentication issues, hardcoded secrets, and Next.js-specific security problems. Audits dependencies for known CVEs and generates actionable security reports.
This skill enables comprehensive security scanning of Next.js and TypeScript/JavaScript projects based on OWASP guidelines and industry best practices.
Fast scan focusing on critical vulnerabilities:
dangerouslySetInnerHTML, eval)Comprehensive security assessment covering:
Focus on specific vulnerability categories:
--xss - Cross-site scripting patterns--injection - SQL/NoSQL/Command injection--auth - Authentication/authorization issues--secrets - Hardcoded credentials--deps - Dependency vulnerabilities--nextjs - Next.js specific issuesnext.config.js, package.json, .env*)Run the dependency audit script:
./scripts/dependency-audit.sh
Or manually:
npm audit --json
# or
yarn audit --json
Scan for hardcoded secrets:
python scripts/secret-scanner.py /path/to/project
Important: Environment File Handling
.env files are SKIPPED (.env, .env.local, .env.production, etc.).env.example and .env.template files are analyzed for documentation quality--include-env-files flag only if explicitly requested by userThe scanner will:
.env.example templates to check:
For each file in the codebase, check against patterns in:
references/xss-patterns.md - XSS vulnerabilitiesreferences/injection-patterns.md - Injection flawsreferences/auth-vulnerabilities.md - Auth issuesreferences/nextjs-specific.md - Next.js vulnerabilitiesGenerate a security report using:
assets/report-template.md - Report structure| Severity | Description | Action Required | |----------|-------------|-----------------| | CRITICAL | Exploitable vulnerability with severe impact | Immediate fix required | | HIGH | Significant security risk | Fix before deployment | | MEDIUM | Potential security issue | Fix in next release | | LOW | Minor security concern | Consider fixing | | INFO | Security best practice suggestion | Optional improvement |
**/*.ts, **/*.tsx, **/*.js, **/*.jsx - Source codenext.config.js, next.config.mjs - Next.js configurationpackage.json, package-lock.json - Dependenciesmiddleware.ts, middleware.js - Middleware security.env.example, .env.template - SCAN for template analysis.env, .env.local, .env.production - SKIP by default (contain real secrets)Note: Real .env files should never be committed to version control. The scanner analyzes .env.example templates to ensure proper documentation of required variables.
app/api/**/* - API routes (App Router)pages/api/**/* - API routes (Pages Router)**/actions.ts, **/*-actions.ts - Server Actionslib/auth*, utils/auth* - Authentication code**/middleware.* - Middleware filesFindings should be reported as:
[SEVERITY] Category: Description
File: path/to/file.ts:lineNumber
Code: <relevant code snippet>
Risk: <explanation of the security risk>
Fix: <recommended remediation>
This skill can generate output compatible with:
Load additional context as needed:
references/owasp-top-10.md - OWASP Top 10:2025 quick referencereferences/xss-patterns.md - XSS detection patternsreferences/injection-patterns.md - Injection vulnerability patternsreferences/auth-vulnerabilities.md - Authentication security patternsreferences/nextjs-specific.md - Next.js specific vulnerabilities and CVEsnpx skills add sugarforever/Next.js Security Scan下载完整 Skill 目录,包含 SKILL.md 及所有相关文件
Search for places (restaurants, cafes, etc.) via Google Places API proxy on localhost.
Interact with GitHub using the `gh` CLI. Use `gh issue`, `gh pr`, `gh run`, and `gh api` for issues, PRs, CI runs, and advanced queries.
Create or update AgentSkills. Use when designing, structuring, or packaging skills with scripts, references, and assets.
Start voice calls via the OpenClaw voice-call plugin.
Notion API for creating and managing pages, databases, and blocks.
Gemini CLI for one-shot Q&A, summaries, and generation.
Category:developer