Skip to content

Latest commit

 

History

History
14 lines (7 loc) · 445 Bytes

File metadata and controls

14 lines (7 loc) · 445 Bytes

SecurityExplained S-56: Vulnerable Code Snippet - 43

Vulnerable Code:

Vulnerable Code

Solution:

This code is vulnerable to Command Injection as an attacker can inject malicious shell commands into the name of an uploaded file by using characters such as ";" or "`" to start a new command.

Twitter Thread: https://twitter.com/harshbothra_/status/1496993342378242063

Code Credits: @SonarSource