subprocess module call
Medium
- Category
- Dangerous Code Execution
- Content
if repo_dir.exists() and any(repo_dir.iterdir()): return "existing" repo_dir.parent.mkdir(parents=True, exist_ok=True) subprocess.run(["git", "clone", "--depth", "1", repo_url, str(repo_dir)], check=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True) return "cloned"- Confidence
- 88% confidence
- Finding
- The code clones arbitrary user-supplied remote repositories onto the local filesystem with no apparent allowlist, protocol restriction, size limit, or confirmation gate. In a KB-ingestion skill, this expands capability significantly and can be abused for unwanted data transfer, storage exhaustion, or retrieval of hostile repository content that may later be processed by other tooling.
