T08 · Insecure Dependencies
- Location
SKILL.md:37- Finding
Unpinned Third-Party SDK Dependency
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:37;scripts/main.py:229-233
Vulnerability Type: Unpinned third-party dependency and supply-chain exposure
Risk Level: LowVulnerable Code
SKILL.md:37:text pip install tencentcloud-sdk-pythonscripts/main.py:229-233:python except ImportError: print( "Error: Missing dependency tencentcloud-sdk-python; run: pip install tencentcloud-sdk-python", file=sys.stderr, )The original message in the source code is written in Chinese but gives the same unpinned installation instruction shown above.
Technical Analysis
The Skill directs users to install
tencentcloud-sdk-pythonwithout specifying an exact reviewed version, package hash, or lockfile. Consequently, the installed code depends on mutable package-registry state at installation time rather than the version reviewed with this Skill.The SDK is imported by
scripts/main.pyand executes in the same process as the Skill. It can therefore access the process environment, includingTENCENTCLOUD_SECRET_IDandTENCENTCLOUD_SECRET_KEY, as well as document data supplied for OCR processing. This creates supply-chain exposure if the upstream package, maintainer account, release pipeline, or package repository is compromised.No evidence was found that the current Skill deliberately installs a malicious or lookalike package. The risk arises from the absence of version and integrity controls.
Attack Path
- An attacker compromises the upstream package maintainer account, release pipeline, distribution repository, or a future dependency release.
- The attacker publishes a malicious version under the legitimate package name.
- A user follows the Skill documentation or runtime error message and runs the unpinned installation command.
- The package manager selects the attacker-controlled release.
- When
scripts/main.pyimports the SDK, malicious initialization code executes with the invokin ...[truncated 822 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the dependency to an exact version that has been reviewed:
text tencentcloud-sdk-python==REVIEWED_VERSION- Maintain dependencies in a requirements or lock file rather than instructing users to install an unconstrained package.
- Generate and enforce cryptographic hashes, for example with pip's
--require-hashesoption. - Install packages only from the official Python package index or an organization-controlled, authenticated package mirror.
- Add automated dependency vulnerability scanning and review updates before changing the pinned version.
- Run the Skill in an isolated environment with only the required credentials, files, and network access.
- Update both
SKILL.mdand the runtime dependency error message so they reference the pinned, integrity-verified installation procedure.
