CWE-786 advisories

OS Command Injection

What it is

User input is passed to a shell, letting an attacker run arbitrary operating-system commands.

How to fix it

Upgrade, then call programs with an argument array (no shell) and validate inputs.

How to avoid it

Avoid the shell; use exec-with-args APIs and strict allow-lists for any command parameters.

Known OS Command Injection vulnerabilities

Stateward flags OS Command Injection in your own code and dependencies on every pull request.

Scan my repo

Summarize with AI

ChatGPTClaudePerplexity

Sources: CISA KEV (public domain), OSV.dev & GitHub Advisory Database (CC-BY-4.0), FIRST EPSS, NVD/CWE (public domain). Served live from the Stateward advisory database.