T08 · Insecure Dependencies
- Location
SKILL.md:346- Finding
Unpinned Security-Sensitive Python Dependencies
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:343-346
Vulnerability Type: Supply-chain exposure through unpinned third-party dependencies
Risk Level: MediumVulnerable Code
bash ## Dependencies For wallet signing in Python: pip install mnemonic eth-account requestsThe installed packages subsequently operate in a process that accesses the wallet private key:
python private_key = os.environ.get("WALLET_PRIVATE_KEY") account = Account.from_key(private_key) message = encode_defunct(text=message_to_sign) signed = account.sign_message(message) signature = signed.signature.hex()Technical Analysis
The installation command does not pin dependency versions, verify package hashes, use a lockfile, or explicitly constrain package retrieval to an approved index. Consequently, the packages and their transitive dependencies may change between installations without any corresponding change to the reviewed Skill.
This is particularly security-sensitive because the installed wallet libraries execute in the same Python process that reads
WALLET_PRIVATE_KEY. A malicious or compromised package release, package-index compromise, or compromised transitive dependency could execute code during installation or import and access the private key from the environment.No evidence establishes that the named packages or documented API are currently malicious. The vulnerability is the absence of controls ensuring that users install the same reviewed dependency artifacts.
Attack Path
- An attacker compromises a listed package, one of its transitive dependencies, or the package distribution channel.
- The attacker publishes a malicious release that remains compatible with the unconstrained installation command.
- A user follows the Skill documentation and runs
pip install mnemonic eth-account requests. - The package manager resolves and installs the attacker-controlled release.
...[truncated 1023 chars]
- Remediation
View remediation
Remediation Suggestions
- Replace the unconstrained installation command with dependencies pinned to reviewed versions.
- Generate a lockfile containing all transitive dependencies.
- Require cryptographic hashes for every downloaded artifact, such as through a hash-locked requirements file and
pip install --require-hashes -r requirements.txt. - Configure installation to use an explicitly approved package index and disable unintended supplemental indexes.
- Regularly scan locked dependencies for known vulnerabilities and review dependency changes before updating the lockfile.
- Run wallet-signing code in a dedicated, minimally privileged virtual environment or container.
- Recommend a dedicated low-value wallet rather than a wallet holding significant assets.
- Prefer hardware-wallet or isolated signing where feasible so the raw private key is not exposed to general-purpose Python dependencies.
- Explicitly warn users not to execute package installation with administrator or root privileges.
