Injection Pattern Detection

Detect SQL injection, XSS, SSTI, command injection, SSRF, and path traversal patterns in source code.

1|Updated Mar 12, 2026
One-click install
npx skills add https://github.com/kaminocorp/hermes-alpha-hunter --skill injection-pattern-detection-kaminocorp
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: Injection Pattern Detection
Source: https://github.com/kaminocorp/hermes-alpha-hunter/tree/main/hunter/skills/security/injection-patterns
Command: npx skills add https://github.com/kaminocorp/hermes-alpha-hunter --skill injection-pattern-detection-kaminocorp

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Security reviewers and developers need a systematic way to find injection vulnerabilities during code audits, but manually tracing every path from user input to dangerous sinks across multiple languages and frameworks is slow and error-prone. ## Core Features & Use Cases - Multi-Language Search Patterns: Ready-to-use grep patterns for Python, JavaScript, TypeScript, Java, Ruby, PHP, and template engines to locate dangerous sinks like raw SQL, shell execution, and unescaped template rendering. - Six Injection Classes Covered: SQL injection (including ORM bypasses and NoSQL), XSS (reflected, stored, DOM-based), SSTI, command injection, SSRF, and path traversal, each with vulnerable and secure code examples. - Source-to-Sink Verification Workflow: A checklist for tracing untrusted input to sensitive sinks, evaluating sanitization, and assessing real-world exploitability. - Use Case: During a security review of a Node.js API, run the provided grep patterns to find exec() calls and sequelize.query() with template literals, then trace whether req.query or req.body values reach them without sanitization. ## Quick Start Ask the agent to scan this repository for SQL injection and command injection vulnerabilities using the injection pattern detection workflow.

Frequently Asked Questions about Injection Pattern Detection

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I find SQL injection vulnerabilities in source code?▼

Search for raw SQL with string formatting using grep patterns targeting execute(), query(), and ORM escape hatches like .raw(), .extra(), knex.raw(), and $queryRawUnsafe. Then trace whether user input reaches those calls without parameterization.

How to detect XSS vulnerabilities in React and Vue applications?▼

Search for dangerouslySetInnerHTML in React, v-html in Vue, and bypassSecurityTrust in Angular. For DOM-based XSS, grep for document.write, eval, innerHTML assignments, and location.hash usage, then check if stored user input reaches rendering without sanitization.

Does path.join prevent path traversal attacks in Node.js?▼

No, path.join does not prevent path traversal because path.join('/uploads', '../../../etc/passwd') resolves to /etc/passwd. You must validate that the resolved path stays within the intended base directory.

What SSRF bypass techniques should I check during a code review?▼

Check whether URL validation blocks localhost variants like 127.0.0.1, [::1], and 169.254.169.254 for cloud metadata. Also test DNS rebinding, credential-embedded URLs like http://evil@authorized-host/, and redirect chains that 302 to internal hosts.

Why is Prisma $queryRawUnsafe dangerous compared to $queryRaw?▼

$queryRaw uses tagged templates which automatically parameterize interpolated values, making it safe. $queryRawUnsafe accepts a raw string, so any interpolated user input is executed directly as SQL, enabling injection.