subprocess module call
Medium
- Category
- Dangerous Code Execution
- Content
shell_cmd = f"{shlex.quote(binary)} pipe -s 1 -i {int(interval_ms)}" try: return subprocess.run( [shell, "-lic", shell_cmd], capture_output=True, text=True,- Confidence
- 92% confidence
- Finding
- The fallback executes macmon through `zsh -lic`, which evaluates a command string inside a login shell. Although the binary path is shell-quoted and interval_ms is cast to int, invoking a login shell loads shell startup files and trusts PATH resolution for both zsh and macmon, increasing exposure to environment- or profile-based command hijacking if the skill runs in an untrusted local context.
