Back to skill

Security audit

Trading Coach

Security checks for vulnerabilities and agentic risk

Overview

This trading-analysis skill is not overtly malicious, but it asks users to run unreviewed remote code on sensitive brokerage files.

Install only if you are comfortable running code from the referenced GitHub repository after reviewing it yourself. Prefer pinning a known commit, reviewing requirements, running it in an isolated environment, and redacting account identifiers or unnecessary personal fields from brokerage exports before use.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (1)

T03 · Remote Payload Retrieval and Execution

Warning
Location
SKILL.md:29
Finding

Unpinned Remote Code and Dependency Retrieval

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 29-37
Vulnerability Type: Remote payload retrieval and insecure dependency installation
Risk Level: Medium

bash
git clone https://github.com/BENZEMA216/tradingcoach.git ~/tradingcoach
cd ~/tradingcoach
python3 -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt && cp config_template.py config.py

# 一键复盘
python scripts/import_trades.py /path/to/trades.csv  # 导入
python scripts/run_matching.py                        # 配对
python scripts/score_positions.py --all               # 评分
python scripts/analyze_scores.py                      # 报告

Technical Analysis

The documented installation process clones the current state of an external GitHub repository without pinning a reviewed commit, verifying a cryptographic checksum, or requiring a signed release. It then installs dependencies from a remotely obtained requirements.txt and executes scripts that are absent from the audited artifact.

Because the effective implementation can change after this skill package has been reviewed, the security properties of the invoked scripts cannot be established from the artifact. The dependency installation is also not reproducible or integrity-protected: no lockfile, exact versions, or package hashes are supplied.

A Python virtual environment isolates package placement but does not sandbox execution. Installation hooks and downloaded scripts retain the invoking user's normal filesystem, process, and network privileges.

Attack Path

  1. An attacker compromises the referenced GitHub account or repository, gains control of a dependency source, or otherwise causes malicious content to appear in the repository or its dependency definitions.
  2. A user follows the instructions and clones the mutable default branch.
  3. The user executes pip install -r requirements.txt; malicious package installation hooks could run at th ...[truncated 925 chars]
Remediation
View remediation

Remediation Suggestions

  1. Bundle the reviewed implementation with the skill so its executable behavior is included in the audit scope.
  2. If remote retrieval remains necessary, pin the repository to a specific reviewed commit rather than cloning a mutable default branch.
  3. Distribute signed releases and verify signatures or cryptographic checksums before installation or execution.
  4. Use a dependency lockfile containing exact versions and hashes. Install with an integrity-enforcing command such as pip install --require-hashes -r requirements.txt.
  5. Review direct and transitive dependencies and use trusted package indexes explicitly.
  6. Disable unnecessary network access while processing brokerage records and restrict filesystem access to the required input and output directories.
  7. Document what financial data is read, retained, logged, or transmitted.
  8. Run the processing scripts under a dedicated, least-privileged account or an appropriately isolated environment.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (5)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill solicits and processes brokerage CSV exports, which commonly contain sensitive financial and sometimes personal account data, but it provides no prominent warning about privacy, minimization, or redaction. Users may upload full account exports without understanding the sensitivity, increasing exposure of account identifiers, detailed trading history, and other confidential financial information.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger conditions are broad enough to activate on ordinary requests like 'analyze my trading' or 'help me review trades', which can cause the skill to engage unexpectedly. In a financial-analysis context, unintended activation increases the chance that sensitive brokerage CSV data is pulled into the skill flow without the user clearly opting into this specific tool.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
76% confidence
Finding

This markdown file is largely written in Chinese and defines broker formats primarily using Chinese labels, while only one subsection offers English field names. Under the stated policy, forcing a specific language without user opt-in can be a natural-language policy violation unless the locale constraint is explicitly documented and justified, which is not present here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
96% confidence
Finding

This markdown file presents all instructions, labels, and examples exclusively in Chinese, which effectively forces a specific language for users. The policy for SQP-3 flags language or locale constraints when no user opt-in or justification is provided.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

The entire skill document is written in Chinese and does not indicate that language selection is optional or constrained to a Chinese-speaking audience. Under the policy, forcing a specific language without user opt-in can be a natural-language locale violation.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.