T07 · Tool Hijacking and Spoofing
- Location
SKILL.md:43- Finding
Execution of Unverified External and Relative Scripts
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 43-53 and 56-78
Vulnerability Type: Untrusted local script resolution and execution
Risk Level: HighEvidence
bash node 115.js ls <cid> node 115.js rename "<old_name>" "<new_name>" <cid> python3 movie_pipeline.py --mode=monitor python3 copy_and_rename_movies.py python3 cleanup_and_rename.py python3 movie_pipeline.py --mode=full python3 batch_rename_115_cloud.pyThe documented external script is located at:
text ~/.openclaw/scripts/115-renamer/115.jsTechnical Analysis
The Skill directs the Agent to execute several Python and Node.js scripts, but none of those executable files is included in the audited project. The commands use relative script names such as
movie_pipeline.pyand115.js, making script selection dependent on the current working directory.The instructions do not require canonical path resolution, ownership verification, restrictive permissions, an integrity hash, or signature validation. Consequently, a local attacker or compromised process capable of creating or replacing a file in the effective working directory could cause a legitimate-looking command to execute attacker-controlled code.
Because the referenced scripts are absent from the package, their behavior cannot be verified. This finding concerns the insecure execution mechanism and replacement risk; it does not establish that the absent scripts are themselves malicious.
Attack Path
- An attacker obtains write access to the directory from which a documented command will be run, or replaces an external script under
~/.openclaw/scripts. - The attacker creates a malicious script named
movie_pipeline.py,cleanup_and_rename.py,batch_rename_115_cloud.py, or115.js. - A user or scheduled Agent task invokes the corresponding command from
SKILL.md. - Python or Node.js resolves and executes the att ...[truncated 852 chars]
- An attacker obtains write access to the directory from which a documented command will be run, or replaces an external script under
- Remediation
View remediation
Remediation Suggestions
- Include all required scripts inside the reviewed Skill package so their implementation can be audited.
- Resolve scripts relative to a trusted, immutable package directory instead of the current working directory.
- Invoke scripts through canonical absolute paths.
- Verify script ownership and reject files writable by unauthorized users or groups.
- Pin and verify cryptographic hashes or signatures before execution.
- Run the scripts under a dedicated least-privilege account with access limited to the required source and destination directories.
- Prevent executable directories from being writable by untrusted users.
- Apply API-side least privilege and require confirmation for destructive cloud rename or deletion operations.
- Audit the missing Python and Node.js scripts before enabling the documented scheduled tasks.
