Command Injection

;ping+-c+10.10.10.10+1#

Command Injection is a critical vulnerability that results in attackers being able to inject commands on a machine form the website.

Taken from PortSwigger Web Security Academy

Exploitation

First, one has to understand how special characters are processed by websites and shells:

There are tons of payload cheatsheets online, and the one at Hacktricks is very good.

This vulnerability is quite easy confirm:

Look at Cmd parameter

Blind Injection

Sometimes, the output of commands is not displayed. One can use the ping command to send a packet to our machine, and tcpdump can be used to listen for ICMP packets.

Last updated