subprocess module call
Medium
- Category
- Dangerous Code Execution
- Content
command_b64 = base64.b64decode(args.command).decode("utf-8") command_url = urllib.parse.unquote(command_b64) completed = subprocess.run( command_url, shell=True, text=True,- Confidence
- 99% confidence
- Finding
- The script decodes attacker-controlled input and passes it directly to subprocess.run with shell=True, enabling arbitrary shell command execution. The base64 and URL decoding step adds obfuscation rather than safety, making it easier to conceal dangerous payloads while still executing them on the host.
