os.system() or os exec-family call
High
- Category
- Dangerous Code Execution
- Content
try: # Try notify-send (Linux) urgency_map = {'low': 'low', 'normal': 'normal', 'critical': 'critical'} os.system(f'notify-send -u {urgency_map.get(urgency, "normal")} "{title}" "{message}"') except: print(f"[NOTIFICATION] {title}: {message}")- Confidence
- 98% confidence
- Finding
- This is a true command-injection vulnerability because untrusted CLI inputs (`title` and `message`) are interpolated directly into a shell command passed to `os.system()`. Quoting with double quotes is not sufficient to prevent shell expansion, so crafted input containing shell metacharacters or command substitution can execute arbitrary commands under the privileges of the script.
