Home / Knowledge hub / Remote code execution
Knowledge hub
Remote code execution
Getting a server to run commands of an attacker's choosing.
What it means
Remote code execution, usually shortened to RCE, means an attacker gets your server to run commands they chose. Not reading data it should hide, but running programs on your machine.
It normally arrives through something built to handle data: a file upload, a template, an object somebody serialised, or an over-helpful library.
Why it matters
Once somebody runs commands on your server, your other controls become decoration. They read the database, take the credentials the application uses, install something that survives a restart, and reach whatever the server reaches.
Rating systems put it at the top for that reason, and there is no partial version of the outcome to negotiate about. Recovery also costs more than teams expect. After a server has run someone else's code, you cannot clean it with confidence. You rebuild it and rotate everything it held.
How it shows up
In a real application it rarely looks dramatic. A field takes a filename and passes it to a shell. An image converter runs on whatever a customer uploads. A template renders text a user supplied. An out of date component carries a published flaw with a working exploit already attached.
Because the entry point looks ordinary, ask where this input ends up and what runs it, rather than whether the field can break. MITRE catalogues the general pattern as CWE-94. Keeping components current removes a large share of the realistic routes, because most of them are published flaws in something entirely unremarkable. Logging helps afterwards as well. Without a record of what that server ran and reached, the clean-up turns into guesswork.
Questions people ask
Remote code execution, answered
How serious is a remote code execution bug?
It is the worst ordinary outcome. Somebody running commands on your server reads the database, takes the credentials the application holds, and reaches whatever that server can reach.
Rating systems put it at the top, and the gap between somebody finding it and somebody using it tends to be short.
Is RCE the same as command injection?
Command injection is one route to it. RCE names the outcome, running code of the attacker's choosing.
Deserialisation flaws, template injection and vulnerable components all arrive at the same place. MITRE catalogues the general pattern as CWE-94.
Can a file upload really lead to remote code execution?
Yes, and it is one of the commonest routes. The upload itself is rarely the problem.
What runs afterwards is: an image converter, a document parser, or a web server willing to execute the file you just stored.
What should we do first if we find an RCE?
Take the path out of reach, then work out what that server held. Rotate every credential it could touch.
Once a machine has run someone else's code, you cannot clean it with confidence. Rebuild it.
Will a firewall or a WAF stop remote code execution?
It blocks known payload shapes, and attackers rewrite payloads. Treat it as cover while you fix the code, never as the fix.
Cyberlop does not grade firewall or WAF configuration, and it does not scan networks. It tests the application.
Related
Terms that sit next to this one
Injection
Input that ends up running as a command instead of being read as text.
Insecure deserialisation
Turning data from outside back into live objects without checking it.
SQL injection
Input a database ends up running as part of a query.
Severity
How bad a finding is, from critical down to informational.
Exploit
The specific sequence that turns a suspected weakness into a real one.
Could a file upload run commands?
Injection sits among the ten vulnerability classes Cyberlop tests, and any finding arrives with the proof attached. Run it against a single application for 30 days for $199.
Or start with a $199 pilot on one application: thirty days, success criteria agreed before day one, credited against the annual if you convert.