ersinkoc/security-check/sc-header-injection
Claude Code and agent skill by ersinkoc/security-check
- community
Checking that the SKILL.md file is still in the repository.
HTTP Header Injection and Response Splitting detection via CRLF injection in headers
Install
npx vskill@latest install ersinkoc/security-check/sc-header-injectionSKILL.md
The same SKILL.md was published earlier as ersinkoc/security-check/sc-header-injection.
SC: HTTP Header Injection / Response Splitting
Purpose
Detects HTTP header injection vulnerabilities where user-controlled input is placed into HTTP response headers without CRLF character sanitization, enabling response splitting, cookie injection, cache poisoning, and XSS via injected headers. Also covers Host header injection used in password reset poisoning.
Activation
Called by sc-orchestrator during Phase 2 when HTTP response handling is detected.
Phase 1: Discovery
File Patterns to Search
Keyword Patterns to Search
Vulnerability Pattern: CRLF in Headers
Host Header Injection
Content-Disposition Injection
Phase 2: Verification
Modern Framework Protections
Most modern HTTP libraries and frameworks reject CRLF characters in header values:
- Node.js (v14+):
http.ServerResponsethrows on CRLF in header values - Go net/http: Rejects headers containing
\ror\n - Python/Django: WSGI servers typically strip CRLF
- Java Servlet (Tomcat 7+): Rejects CRLF in response headers
- ASP.NET Core: Rejects CRLF in header values
However: Some configurations, proxies, or older versions may not enforce this.
Sanitization Check
- Are
\rand\nstripped from user input before header insertion? - Is the value URL-encoded or otherwise escaped?
- Does the HTTP framework/server reject CRLF in headers?
Severity Classification
- Critical: Response splitting enabling XSS or cache poisoning on shared caches
- High: Host header injection in password reset leading to token theft
- Medium: Cookie injection via CRLF, or header injection in less-sensitive headers
- Low: Header injection in modern framework that auto-rejects CRLF (informational)
Output Format
Finding: HDR-{NNN}
- Title: {CRLF Header Injection | Host Header Injection | Response Splitting} in {endpoint}
- Severity: Critical | High | Medium | Low
- Confidence: 0-100
- File: file/path:line
- Vulnerability Type: CWE-113 (HTTP Response Splitting)
- Description: User input from {source} is placed into HTTP {header name} without CRLF sanitization.
- Proof of Concept: Injecting
%0d%0asequences could add arbitrary headers to the response. - Impact: {Cache poisoning / XSS / session fixation / password reset poisoning}
- Remediation: Strip CR/LF characters from user input. Use framework-provided safe header methods. For Host header: use server configuration instead of request Host header.
- References: https://cwe.mitre.org/data/definitions/113.html
Common False Positives
- Modern frameworks — Node.js 14+, Go, ASP.NET Core, Tomcat 7+ reject CRLF automatically
- Static header values — headers set from constants or configuration, not user input
- Content-Type headers — typically set by framework based on response type, not user input
- Framework redirect methods —
res.redirect()in Express URL-encodes the location - Reverse proxy normalization — nginx/Apache strip malformed headers before they reach the app
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/sc-header-injection/SKILL.md
Popularity
- Repository stars
- 46
- Repository forks
- 5
- 7-day trend score
- 19
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/ersinkoc/security-check/sc-header-injection)