T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:25
- Finding
- Unpinned Tencent Cloud SDK Dependency<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:25` **Vulnerability Type**: Unpinned third-party dependency **Risk Level**: Medium ### Vulnerable Code ```bash pip install tencentcloud-sdk-python ``` ### Technical Analysis The installation instruction retrieves the latest available version of `tencentcloud-sdk-python` without enforcing an audited version or validating package hashes. Consequently, the code installed when the instruction is followed can change after the Skill has been reviewed. This does not prove that the current package is malicious. However, it creates a supply-chain risk if the package repository, publisher account, package distribution process, or a future release is compromised. The dependency executes in the same Python environment as the Skill and can access the Tencent Cloud credentials supplied through `TENCENT_SECRET_ID` and `TENCENT_SECRET_KEY`. ### Attack Path 1. An attacker compromises the package publisher, distribution account, or upstream release process. 2. The attacker publishes a malicious version under the legitimate package name. 3. A user follows the documented unpinned installation command. 4. The package manager retrieves and installs the compromised release. 5. Malicious package code executes during installation or import. 6. The compromised dependency accesses Tencent credentials, local files, or network resources with the privileges of the user running the Skill. ### Impact Assessment A compromised dependency could execute arbitrary code under the invoking user's account. It could access the Tencent Cloud credentials required by the Skill, submit unauthorized API requests, read files available to the process, alter generated output, or communicate with external services. The affected scope is limited by the privileges of the Python environment and operating-system user, but those privileges exceed what is necessary merely to install a known, reviewed SDK version. ]]>
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Pin the SDK to a specifically reviewed version: ```bash pip install "tencentcloud-sdk-python==AUDITED_VERSION" ``` 2. Maintain dependencies in a lock file with cryptographic hashes, such as a hash-locked `requirements.txt`. 3. Install the dependency in an isolated virtual environment rather than a privileged or shared Python environment. 4. Use an internal or controlled package mirror where appropriate. 5. Periodically review and deliberately update the pinned version after checking release notes and package integrity. 6. Run the Skill with Tencent credentials scoped to only the API actions and resources required for video generation. ]]>
