4d-publish-github
Fail
Audited by Gen Agent Trust Hub on Feb 17, 2026
Risk Level: HIGHCOMMAND_EXECUTIONEXTERNAL_DOWNLOADS
Full Analysis
- [COMMAND_EXECUTION] (HIGH): In
scripts/publish.py, thesetup_github_repofunction is vulnerable to command injection. - Evidence: The code constructs a shell command
cmd = f'gh repo create "{project_name}" --source=. --push {visibility_flag}'and executes it usingsubprocess.run(cmd, shell=True). Theproject_nameis derived from the directory name or a.4DProjectfile, allowing an attacker to execute arbitrary commands by naming a folder with shell metacharacters (e.g.,$(touch pwned)). - Evidence: The repository
descriptionis appended to the command after a naive escaping attempt:description.replace('"', '\\"'). This does not prevent command substitution via$()or backticks in a shell environment. - [COMMAND_EXECUTION] (MEDIUM): Both
scripts/publish.pyandscripts/install_workflows.pyuse a helper functionrun_cmdthat executes commands withshell=True. - Evidence: Pervasive use of
shell=Truethroughout the scripts increases the risk of shell-related vulnerabilities and is against security best practices. - [EXTERNAL_DOWNLOADS] (LOW): The skill facilitates the download and installation of external software.
- Evidence: The
check_ghfunction inpublish.pyoffers to install the GitHub CLI usingbrew install gh. While Homebrew is a trusted source, this involves external code execution at runtime. - [SAFE] (INFO): No hardcoded credentials or unauthorized data exfiltration patterns were detected in the provided files.
Recommendations
- AI detected serious security threats
Audit Metadata