Back to skill

Security audit

场内基金溢价率查询

Security checks for vulnerabilities and agentic risk

Overview

This is a coherent fund premium lookup skill that only queries public market data, but some financial data is fetched over plaintext HTTP and should not be relied on for trading decisions without verification.

Install only if you are comfortable with a Chinese-language tool that sends requested fund codes to public finance data providers. Treat its output as informational: because several sources use HTTP instead of HTTPS, prices or NAV data could be modified on an untrusted network, so verify important results with a trusted broker or official source before making financial decisions.

Vulnerability Patterns
  • 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
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/data_sources.py:127
Finding

Unauthenticated Plaintext HTTP Used for Financial Market Data

Content
View full analysis
dict: url = f"http://fundgz.1234567.com.cn/js/{fund_code}.js" ``` ```python # scripts/data_sources.py:207-208 url = f"http://hq.sinajs.cn/list={code}" ok, text, err = http_get( url, headers={"Referer": "http://finance.sina.com.cn"}, encoding="gbk" ) ``` ```python # scripts/data_sources.py:245-270 url = ( f"http://stock.finance.sina.com.cn/fundInfo/api/openapi.php" f"/CaihuiFundInfoService.getNav?symbol={fund_code}" f"&datefrom=2026-05-01&dateto=2026-06-03" ) ok, text, err = http_get(url) # ... url = ( f"http://money.finance.sina.com.cn/quotes_service/api/json_v2.php" f"/CN_MarketData.getKLineData?symbol={code}" f"&scale=240&ma=no&datalen={days}" ) ``` ```python # scripts/data_sources.py:301 url = f"http://qt.gtimg.cn/q={code}" ``` ```python # scripts/premium_history.py:32-35 url = ( f"http://api.fund.eastmoney.com/f10/lsjz" f"?fundCode={fund_code}&pageIndex=1&pageSize ...[truncated 2924 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (8)

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The trigger list includes very broad terms such as “套利” and “premium rate,” which can match ordinary finance conversations far beyond the narrow ETF/LOF premium-rate use case. Over-broad activation can cause the skill to run unexpectedly, leading to scope hijacking, user confusion, and unintended external data access in contexts where the user did not intend to invoke this tool.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The top-level docstring is entirely in Chinese and presents the skill's purpose and behavior only in that language. This creates a natural-language locale restriction without any opt-in, fallback, or justification that the skill is intended only for a Chinese-speaking or region-specific environment.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
93% confidence
Finding

This code retrieves fund NAV data over plain HTTP and also sends an HTTP Referer, allowing any network attacker on the path to observe or tamper with responses. Because the returned data is parsed and used as authoritative financial information, a man-in-the-middle could falsify NAV values, disrupt downstream decisions, or inject misleading data without authentication guarantees.

Content

Scanner excerpt · scripts/data_sources.py (reported line 127)May include surrounding context.

python
def get_latest_nav(self, fund_code: str, page_size: int = 1) -> dict:
        url = (
            f"http://api.fund.eastmoney.com/f10/lsjz"
            f"?fundCode={fund_code}&pageIndex=1&pageSize={page_size}"
        )
        ok, text, err = http_get(url, headers={"Referer": "http://fund.eastmoney.com/"})

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The docstring says the function performs data retrieval with automatic fallback for the requested method, but in the history_klines branch it hardcodes days=0 instead of propagating a caller-supplied day count. This means the documented generic fallback behavior does not actually apply correctly for historical K-line queries.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This code's top-level docstring presents usage and description entirely in Chinese, and the script's runtime help and status messages are also Chinese-only. Under the stated policy, forcing a specific language without user opt-in is 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.

External Transmission

Medium
Category
Data Exfiltration
Confidence
95% confidence
Finding

The script retrieves fund NAV data over plain HTTP from external providers, which allows a network attacker or malicious proxy to intercept and modify responses in transit. Because the returned data is used to calculate and display premium/discount rates, tampered data could mislead financial decisions without obvious signs of compromise.

Content

Scanner excerpt · scripts/premium_history.py (reported line 32)May include surrounding context.

python
from data_sources import http_get
                import json
                url = (
                    f"http://api.fund.eastmoney.com/f10/lsjz"
                    f"?fundCode={fund_code}&pageIndex=1&pageSize={page_size}"
                )
                ok, text, err = http_get(url, headers={"Referer": "http://fund.eastmoney.com/"})

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This Python file contains natural-language instructions and output strings entirely in Chinese, which effectively forces a specific language for users. The policy allows locale constraints only when they are optional or clearly justified, but this file provides neither a language choice nor a documented reason for the restriction.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
86% confidence
Finding

The natural-language instructions and usage guidance are predominantly in Chinese, but the document does not indicate that the skill is region-specific or that users may choose another language. This can violate language/locale policy when a skill implicitly forces one language without opt-in.

Content

No source excerpt is available for this finding.