T03 · Remote Payload Retrieval and Execution
- Location
SKILL.md:10- Finding
Unpinned Remote Repository Is Retrieved and Installed as Executable Code
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 10–17
Vulnerability Type:T03: Remote Payload Retrieval and Execution
Risk Level: MediumThe Skill retrieves the default branch of an external GitHub repository and immediately installs it as an editable Python package. The retrieved source is not pinned to a reviewed commit or verified using a cryptographic checksum or signature.
Complete vulnerable code snippet:
yaml install: - id: clone kind: shell label: "Clone repository" command: "git clone https://github.com/mudgesbot/samsung-health-skill.git" - id: venv kind: shell label: "Create virtualenv and install" command: "cd samsung-health-skill && python3 -m venv .venv && source .venv/bin/activate && pip install -e ."Equivalent installation instructions are repeated at
SKILL.md, lines 31–37:bash cd /path/to/workspace/projects git clone https://github.com/mudgesbot/samsung-health-skill.git cd samsung-health-skill python3 -m venv .venv source .venv/bin/activate pip install -e .Technical Analysis
A plain
git cloneretrieves whichever revision is currently referenced by the remote repository's default branch. Because no immutable commit hash or verified release artifact is specified, the effective code can change after this Skill has been reviewed.The subsequent
pip install -e .treats the downloaded repository as a Python package. Package installation may invoke attacker-controlled build backend, packaging, or setup logic. Creating a virtual environment limits where Python packages are installed, but it does not sandbox installation-time code; such code still runs with the invoking user's operating-system privileges.The remote implementation is not included in the audited artifact, so this audit cannot confirm that it is malicious or assess its internal dependency handling. The vulnerability is ...[truncated 1517 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the repository to an immutable, reviewed commit hash rather than cloning and installing the current default branch.
- Fetch the pinned revision explicitly and verify that the checked-out commit exactly matches the approved value before installation.
- Prefer a versioned release artifact with a published SHA-256 checksum or a cryptographically verified signature.
- Vendor the reviewed source into the Skill package when feasible so that the audited artifact contains the code that will execute.
- Replace editable installation with a reproducible, non-editable installation process.
- Pin all direct and transitive Python dependencies and verify package hashes using a lock file or
pip --require-hashes. - Review the repository's build-system configuration and installation hooks before approval.
- Perform installation and health-data processing in an isolated environment with minimal filesystem, credential, and network access.
- Avoid exposing unrelated Google credentials or sensitive files to the installation process, and grant only the minimum Drive permissions required for the declared operation.
