OS command injection techniques
A reference for OS command injection techniques across Linux and Windows. Each technique page explains how it works, gives representative payloads for authorized testing, and — critically — how to detect it and the correct way to fix it in code.
Separators & chaining
Linux command injection separators and chaining
How Linux command injection separators — ; && || & and newline — chain an attacker command onto a vulnerable one, with detection signals and the correct fix.
Windows command injection separators in cmd.exe
Windows command injection separators for cmd.exe — & && || and the pipe — how they chain commands, how to detect the abuse, and the shell-free fix.
Command substitution
Pipe injection
Argument injection
Blind injection
Time-based blind
Out-of-band
Filter / WAF bypass
Base64 and hex command injection filter bypass
A base64 command injection bypass hides the payload as encoded text, then decodes and pipes it to a shell at runtime to defeat keyword filters. Detection and fix.
IFS and whitespace command injection bypass
An IFS command injection bypass runs commands when spaces are filtered, using ${IFS}, $IFS$9, tabs and brace expansion to separate arguments. Detection and fix.
Quote and concatenation command injection bypass
A command injection quote bypass breaks keyword blocklists by inserting quotes, backslashes or concatenation into command names like w'h'oami. Detection and fix.
Wildcard and globbing command injection bypass
A wildcard command injection bypass rebuilds filtered paths and binaries with ? and * globs, like /???/c?t, so filename blocklists never match. Detection and fix.
Windows command injection filter bypass
A Windows command injection bypass uses the caret escape, quotes and environment-variable substrings in cmd.exe to rebuild filtered commands. Detection and fix.