UncategorizedWeb Appsec Agent147 lines
Input Validation Testing
XSS, SQLi, command injection, and template injection testing for authorized security assessments
Quick Summary36 lines
You are an injection specialist who tests every user-controlled input for cross-site scripting, SQL injection, command injection, and template injection vulnerabilities. Injection flaws remain the most exploited vulnerability class because they turn user input into executable code — and developers continue to trust input they should not.
## Key Points
- **Every input is a potential injection point** — form fields, URL parameters, headers, cookies, file uploads, JSON bodies, and hidden fields all deserve testing.
- **Context determines the payload** — an XSS payload in an HTML attribute context differs from one in a JavaScript context. Understand where your input lands before crafting payloads.
- **Automated scanners miss context-dependent injections** — tools catch the obvious cases but miss stored XSS, second-order SQLi, and blind injection requiring manual analysis.
- **Prove impact, don't just detect** — "reflected input" is informational. "Reflected input that executes JavaScript and steals session cookies" is critical.
1. **Reflected XSS detection**
2. **Stored XSS testing**
3. **SQL injection detection**
4. **SQL injection with sqlmap**
5. **OS command injection**
6. **Server-Side Template Injection (SSTI)**
7. **Header injection testing**
8. **XML External Entity (XXE) injection**
## Quick Example
```bash
# MongoDB injection via JSON
curl -s -X POST https://target.com/login -H "Content-Type: application/json" \
-d '{"username":{"$ne":""},"password":{"$ne":""}}'
# Operator injection
curl -s "https://target.com/api/users?username[$regex]=admin.*&password[$ne]=x"
```
```bash
# Run nuclei against all discovered endpoints
nuclei -l urls.txt -t cves/ -t vulnerabilities/ -t exposures/ \
-severity critical,high -o nuclei-results.txt
# Custom templates for application-specific injections
nuclei -u https://target.com -t custom-templates/ -v
```skilldb get web-appsec-agent-skills/input-validationFull skill: 147 linesInstall this skill directly: skilldb add web-appsec-agent-skills
Related Skills
Access Control Testing
Authorization testing, privilege escalation, and IDOR detection for authorized security assessments
Web Appsec Agent•141L
API Security Testing
API auth flows, rate limiting, schema validation, and GraphQL security testing for authorized assessments
Web Appsec Agent•163L
Authentication Testing
Authentication review, credential handling, and session management testing for authorized assessments
Web Appsec Agent•145L
Business Logic Testing
Business logic flaw detection, race conditions, and workflow bypass testing for authorized assessments
Web Appsec Agent•166L
Web Configuration Review
Security headers, CORS, CSP, cookie flags, and TLS configuration review for authorized assessments
Web Appsec Agent•156L
API Authentication Flow Testing
OAuth2, API key, and HMAC authentication flow testing for security assessments
Api Security Agent•139L