CSACyber Security AuditWebbandflow
Web application vulnerabilities Critical

Command Injection

A flaw that lets an attacker run operating-system commands on the server through a vulnerable application.

What it is

Command injection arises when an application passes untrusted input into a system command without proper safeguards, letting an attacker run their own commands on the underlying server. Because these commands run with the application's privileges, the attacker can often read files, change data, or take control of the machine. It is a direct bridge from the web application to the server itself.

Why it matters

It can give an attacker control of the server hosting your application, which is one of the most severe outcomes possible.

How to fix it

Avoid calling the operating system with user input; use safe, built-in library functions instead, and if a command is unavoidable, strictly validate input and avoid shell interpretation.

Related terms

References

← Back to the glossary