Back to skill

Security audit

Aion Skill Builder

Security checks for vulnerabilities and agentic risk

Overview

This appears to be a trading-skill generator, but its packaging partly describes it as a trader and it can write unreviewed model-generated Python into runnable, scheduled skill projects.

Review carefully before installing. Use only test credentials, do not provide a wallet private key unless absolutely necessary, generate output in an empty disposable directory, inspect generated skill.py before running it, and remove or disable the generated cron schedule until the code has been audited.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
Findings (3)

T03 · Remote Payload Retrieval and Execution

Error
Location
build_skill.py:59
Finding

Unvalidated Remote Model Output Is Written as Executable Python

Content
View full analysis
str: """Generate Python skill code using LLM.""" prompt = f""" Generate Python trading skill code for AION that implements this strategy: {strategy_description} Requirements: - Use AionClient from aion_sdk - Include proper error handling - Default to dry-run mode - Include market context checking - Add reasoning strings to all trades - Use skill_slug: {skill_slug} - Include docstrings Return only valid Python code that can be directly used in a clawhub skill. The code should define a main() function that runs the strategy. """ response = openai.ChatCompletion.create( model="gpt-4", messages=[{"role": "user", "content": prompt}], temperature=0.7 ) return response.choices[0].message.content ``` The remote response is subsequently written directly to an executable file: ```python # Generate skill.py using LLM skill_code = generate_skill_code(strategy_description, skill_slug) (skill_path / "skill.py").write_text(skill_code) ``` The generated instructions then recommend executing that file: ```python print(f" 3. Test locally: python skill.py") print(f" 4. Publish: npx clawhub@latest publish . --slug {skill_slug} --version 1.0.0") ``` ### Technical Analysis The user-controlled strategy description and skill slug are interpolated into a prompt sent to a remote language-model service. The service's response is treated as trusted Python source code and written directly to `skill.py`. No controls verify that the response: - Is syntactically valid Python rather than Markdown or mixed content. - Implements dry-run mode. - Avoids credential access ...[truncated 2439 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
build_skill.py:83
Finding

Unvalidated Skill Slug Enables Path Traversal and File Overwrite

Content
View full analysis
Path: """Create a complete skill folder with all required files.""" # Create skill directory skill_path = Path(output_dir) / skill_slug skill_path.mkdir(parents=True, exist_ok=True) ``` Interactive input is accepted without validation: ```python skill_name = input("What is your skill name? (e.g., 'Weather Prediction Trader'): ").strip() skill_slug = input("What is your skill slug? (lowercase, hyphens only, e.g., 'weather-trader'): ").strip() ``` Command-line input is also accepted without validation and passed to the file-generation function: ```python if len(sys.argv) > 1: # Command-line mode (for testing) # python build_skill.py if len(sys.argv) >= 4: skill_slug = sys.argv[1] skill_name = sys.argv[2] strategy_description = sys.argv[3] author = sys.argv[4] if len(sys.argv) > 4 else "Unknown" create_skill_folder( skill_slug=skill_slug, strategy_description=strategy_description, skill_name=skill_name, author=author ) ``` Files are then written using ordinary `write_text()` operations, for example: ```python (skill_path / "SKILL.md").write_text(skill_md_content) (skill_path / "clawhub.json").write_text(json.dumps(clawhub_json, indent=2)) (skill_path / "skill.py").write_text(skill_code) (skill_path / "README.md").write_text(readme_content) ``` ### Technical Analysis The interactive pro ...[truncated 2138 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
clawhub.json:5
Finding

Unpinned SDK and Mutable Publishing Tool Create Supply-Chain Risk

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (16)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared purpose says this is a Polymarket/AION trading skill, but the behavior described is a code generator that uses OpenAI APIs, writes files, and scaffolds projects. This mismatch is dangerous because users may approve the skill expecting market analysis/trading while it actually gains different capabilities, handles different secrets, and performs code-generation side effects.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The manifest markets the package as an autonomous thesis trader, while the documentation shows it is actually a skill generator that creates other trading skills from prompts. This can mislead operators into invoking it in higher-trust contexts, and generated code may introduce additional unreviewed logic, secrets handling, or trading behavior downstream.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

Internal documentation contradictions about what the skill does undermine informed consent and safe deployment. In security-sensitive agent environments, inconsistent descriptions make it harder to apply correct permissions, review the right threat model, and detect when the skill is operating outside expectations.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The file behavior materially contradicts the declared skill purpose: instead of acting as a Polymarket thesis trader, it is a code generator that creates new files and calls an external LLM API. This mismatch is dangerous because users, reviewers, or automated systems may grant permissions or trust based on the manifest description, while the code performs unrelated higher-risk actions such as code generation and filesystem writes.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The module docstring explicitly identifies the program as a skill builder, directly contradicting the manifest's representation as a trading skill. This kind of deceptive or inaccurate packaging undermines permission-based trust decisions and can mask capabilities such as remote API use and local file generation that users did not intend to authorize.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The manifest description claims the skill is a Polymarket thesis trader, but the configured entrypoint is a skill builder and the requested credentials include OpenAI and an optional wallet private key for building/testing generated skills. This capability mismatch is dangerous because it can mislead users into granting sensitive secrets to code that performs materially different actions than advertised, increasing the risk of secret theft, unauthorized code generation, or execution under false pretenses.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
87% confidence
Finding

The manifest omits any explicit tool scope despite the skill apparently needing environment access and file-writing capabilities. That creates an authorization ambiguity where an agent or platform may grant broader capabilities than a user expects, increasing the chance of unintended filesystem changes or secret exposure.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The invocation example uses a broad natural-language request to build a trading skill without boundaries on allowed markets, data sources, code generation scope, or whether file writes and publication steps require confirmation. In an agent setting, such open-ended prompting can cause overbroad generation, unsafe defaults, or creation of code that handles sensitive credentials and trading actions without adequate review.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script initializes and uses an external LLM service for metadata and code generation, which is not justified by the declared trading-skill purpose and expands the trust boundary. In the skill context, this is more dangerous because sensitive strategy descriptions are transmitted off-host and the generated code may later be executed or published without adequate review.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

User-provided strategy content is sent to the OpenAI API without any explicit warning, consent flow, or confidentiality notice. This is dangerous because trading strategies may contain proprietary or sensitive information, and the external transmission is easy to miss in a tool presented as a local skill utility.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The file creates directories and writes multiple project files (SKILL.md, clawhub.json, skill.py, README.md) unrelated to operating a live thesis-trading strategy. In a misrepresented skill, undisclosed write capabilities are risky because users may expect market reads/trades but instead receive filesystem modifications and generated code that could be executed later.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest requests highly sensitive secrets, including API keys and an optional wallet private key, without prominent user-facing warnings about privacy, fund risk, or downstream use. In the context of a misleadingly described skill, collecting these secrets becomes more dangerous because users may provide credentials believing the skill only performs market analysis or trading, when it may instead build or test arbitrary generated skills.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
76% confidence
Finding

The script creates a directory and writes multiple files, including SKILL.md, clawhub.json, skill.py, and README.md. While creation is part of the tool's purpose, the interactive flow does not explicitly warn the user in advance about where files will be created or that existing content may be overwritten due to exist_ok=True and direct write_text calls.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

This is a manifest file, so trigger clarity applies. The file defines the skill's runtime requirements and entrypoint but contains no invocation description, trigger phrases, or contextual constraints, making it unclear when the skill should activate versus not activate.

Content

No source excerpt is available for this finding.