Back to skill

Security audit

财报引文逐字核对

Security checks for vulnerabilities and agentic risk

Overview

This filing-analysis skill needs review because credential safeguards can be bypassed, file writes can escape its data folder, and altered financial quotations can pass verification.

Review before enabling credentialed use. Credential requests need validated destinations and redirect protection, and imported source IDs need strict path containment. Use authenticated HTTPS disclosure sources and independently check important figures against original filings; 'verbatim' and --fix currently allow meaningful numeric changes. Optional model settings send disclosure excerpts to your configured provider. External companion services and Bridge code were not audited. The evidence supports implementation concerns, not intentional malicious behavior.

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 (2)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/cue.py
Finding

External source IDs allow writes outside the selected directory

Content
View full analysis

Impact

Crafted IDs can create or overwrite files outside the selected directory, subject to process permissions and the suffix imposed by the processing path: .htm, .pdf, .jsonl, .txt, or .json. For example, ../../outside reaches a sibling of the selected data directory when appended beneath raw, pages, docs, or omni.

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/cue.py
Finding

Plaintext filing retrieval permits evidence substitution

Content
View full analysis

Impact

An attacker can substitute a valid PDF or HTML filing containing fabricated financial content. Quotations from that substituted corpus can pass verify as verbatim despite being absent from the genuine disclosure.

Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (42)

Tainted flow: 'url' from os.environ.get (line 531, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/cue.py (reported line 67)May include surrounding context.

python
def get(url, headers=None, data=None, tries=4):
    for a in range(tries):
        try:
            with urllib.request.urlopen(urllib.request.Request(url, data=data, headers=headers or {'User-Agent': 'Mozilla/5.0'}), timeout=90) as r: return r.read()
        except urllib.error.HTTPError as e:
            if a == tries - 1 or (400 <= e.code < 500 and e.code != 429): raise   # 4xx (except rate limit) will not fix itself on retry
            time.sleep(2 * (a + 1))

Tainted flow: 'req' from os.environ.get (line 188, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/cue_connectivity_check.py (reported line 193)May include surrounding context.

python
code = None
    raw = ""
    try:
        with urllib.request.urlopen(req, timeout=args.timeout) as resp:
            code, raw = resp.status, resp.read().decode("utf-8", "replace")
    except urllib.error.HTTPError as err:
        detail = ""

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · README.en.md (reported line 44)May include surrounding context.

bash
   CATALOG="https://cuecue.cn/api/mcp-catalog"
   curl -s "$CATALOG" | python3 -c 'import json,sys
   rows=json.load(sys.stdin)["data"]["domains"]
   [print(r.get("id"), r.get("external_status"), (r.get("routing") or {}).get("url", "-")) for r in rows]'
   DOMAIN_ID="<replace with one of the ids listed by the line above>"

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · README.en.md (reported line 48)May include surrounding context.

md
rows=json.load(sys.stdin)["data"]["domains"]
   [print(r.get("id"), r.get("external_status"), (r.get("routing") or {}).get("url", "-")) for r in rows]'
   DOMAIN_ID="<replace with one of the ids listed by the line above>"
   ROUTING_URL="$(curl -s "$CATALOG" | python3 -c 'import json,sys
   rows=json.load(sys.stdin)["data"]["domains"]
   hit=[r["routing"]["url"] for r in rows if r.get("id")==sys.argv[1] and r.get("routing")]
   print(*hit,sep="\n") if hit else sys.exit("Not found: that id is not in the catalog response (or its routing has no url field) - run the line above and pick one of the ids listed")' "$DOMAIN_ID")"

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · README.md (reported line 44)May include surrounding context.

bash
   CATALOG="https://cuecue.cn/api/mcp-catalog"
   curl -s "$CATALOG" | python3 -c 'import json,sys
   rows=json.load(sys.stdin)["data"]["domains"]
   [print(r.get("id"), r.get("external_status"), (r.get("routing") or {}).get("url", "-")) for r in rows]'
   DOMAIN_ID="<把这里换成上一行列出的那个域 id>"

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · README.md (reported line 48)May include surrounding context.

md
rows=json.load(sys.stdin)["data"]["domains"]
   [print(r.get("id"), r.get("external_status"), (r.get("routing") or {}).get("url", "-")) for r in rows]'
   DOMAIN_ID="<把这里换成上一行列出的那个域 id>"
   ROUTING_URL="$(curl -s "$CATALOG" | python3 -c 'import json,sys
   rows=json.load(sys.stdin)["data"]["domains"]
   hit=[r["routing"]["url"] for r in rows if r.get("id")==sys.argv[1] and r.get("routing")]
   print(*hit,sep="\n") if hit else sys.exit("未取到:该 id 不在目录现值里(或它没有 routing 里的 url 字段)——先跑上面那行列出现场的 id 再填")' "$DOMAIN_ID")"

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The primary purpose matches, and the filing downloads, local files, parsing subprocesses, and Cue Bridge calls support that purpose. The material differences are the additional, undescribed external-model data flow and the stronger assurance claimed for quotation fidelity than the matcher actually provides. In particular, --fix preserves quotations already classified as 'verbatim', so it does not necessarily restore their exact original wording and formatting. The stated benchmark percentages cannot be validated from this code alone.

Content

No source excerpt is available for this finding.

The credential destination guard does not cover redirects, contradicting the documented guarantee that every credential-bearing destination is checked.

High
Category
Excessive Agency
Confidence
99% confidence
Finding

The guard validates only the initial URL, while urllib's default redirect handler can follow a POST's 301/302/303 redirect and preserve the Authorization header on the resulting GET. An allowed endpoint that is compromised or exposes an attacker-controlled redirect can therefore send the API key to an unauthorized host or an HTTP destination, bypassing both advertised protections.

Content

No source excerpt is available for this finding.

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
60% confidence
Finding

Code enumerates, copies, or searches environment variables for secrets. Bulk environment access can collect credentials unrelated to the skill's stated purpose.

Content

Scanner excerpt · scripts/test_skill_regression.py (reported line 96)May include surrounding context.

python
FX = _HERE / 'fixtures' / 'omni_real_shape.json'
    def _fx(self): return rj(self.FX)
    def _ingest(self, d, path, **env):
        e = dict(os.environ, **env)
        return subprocess.run([sys.executable, str(CUE), 'ingest', d, '--omni', path, '--sid', 'ANN-1', '--kind', 'announcement', '--date', '2026-10-01',
                               '--title', 't', '--company', 'TestCN', '--market', 'CN'], capture_output=True, text=True, env=e)
    def _bridge_env(self, fx_path, log):

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
60% confidence
Finding

Code enumerates, copies, or searches environment variables for secrets. Bulk environment access can collect credentials unrelated to the skill's stated purpose.

Content

Scanner excerpt · scripts/test_skill_regression.py (reported line 134)May include surrounding context.

python
d = os.path.join(self.d, 'cn'); os.makedirs(d)
        wj({'company': 'TestCN', 'id': '000000', 'market': 'CN', 'sources': [{'sid': 'ANN-1', 'kind': 'announcement', 'date': '2026-10-01', 'title': 't',
                   'source_url': 'https://example.com/a.pdf', 'parser': 'pending', 'n_pages': 0}]}, f'{d}/sources.json')
        log = os.path.join(self.d, 'bridge.log'); env = dict(os.environ, **self._bridge_env(self.FX, log))
        r = subprocess.run([sys.executable, str(CUE), 'omni', d], capture_output=True, text=True, env=env)
        self.assertEqual(r.returncode, 3); self.assertIn('--yes', r.stdout); self.assertFalse(os.path.exists(log))
        r = subprocess.run([sys.executable, str(CUE), 'omni', d, '--yes'], capture_output=True, text=True, env=env); self.assertEqual(r.returncode, 0, r.stderr)

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
70% confidence
Finding

Code enumerates, copies, or searches environment variables for secrets. Bulk environment access can collect credentials unrelated to the skill's stated purpose.

Content

Scanner excerpt · scripts/test_skill_regression.py (reported line 176)May include surrounding context.

python
self.assertEqual(cue.pagespec('1,3-4'), [1, 3, 4])
        out = subprocess.run([sys.executable, str(CUE), 'page', self.d, '10-K_FY2025', '1-2'], capture_output=True, text=True, check=True).stdout
        self.assertIn('[10-K_FY2025 p2]', out)
        env = {k: v for k, v in os.environ.items() if not k.startswith('CUE_LLM_')}
        out = subprocess.run([sys.executable, str(CUE), 'brief', self.d], capture_output=True, text=True, check=True, env=env).stdout
        self.assertIn('10-K_FY2025', out); self.assertEqual(rj(f'{self.d}/leads.json')['aligner'], 'fallback')
class QuietStream:

MCP server referenced without pinned version: 'npx skills'.

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.

MCP server referenced without pinned version: 'npx skills'.

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding

The command executes an unpinned npm CLI and installs skills from a mutable repository reference. Although this is an installer rather than an MCP server, unexpected or compromised upstream updates could introduce code or agent instructions with the user's privileges.

Content

No source excerpt is available for this finding.

MCP server referenced without pinned version: 'npx skills'.

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding

The single-skill installation command still resolves an unpinned npm CLI and mutable skill repository. Selecting one skill limits installation scope but does not prevent upstream changes from supplying unexpected executable code or agent instructions.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
99% confidence
Finding

The shell example attaches the API key to a URL taken directly from a remote catalog without validating its scheme or authorized host. A compromised or incorrectly configured catalog could redirect the credential to an attacker-controlled endpoint or an unencrypted HTTP endpoint; the separately described script's safeguards do not protect this curl example.

Content

Scanner excerpt · README.en.md (reported line 53)May include surrounding context.

md
hit=[r["routing"]["url"] for r in rows if r.get("id")==sys.argv[1] and r.get("routing")]
   print(*hit,sep="\n") if hit else sys.exit("Not found: that id is not in the catalog response (or its routing has no url field) - run the line above and pick one of the ids listed")' "$DOMAIN_ID")"
   [ -n "$ROUTING_URL" ] || { echo "Fetch failed: ROUTING_URL is empty - run the line above, then set DOMAIN_ID to one of the ids listed" >&2; exit 1; }
   curl -s -X POST "$ROUTING_URL" \
     -H "Authorization: Bearer $CUE_API_KEY" \
     -H "Accept: application/json, text/event-stream" \
     -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' \

MCP server referenced without pinned version: 'npx skills'.

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding

The installation example executes the currently resolved skills CLI and retrieves this skill from a mutable repository reference. This creates a supply-chain exposure even though the command is ordinary installation guidance, not evidence of malicious intent.

Content

No source excerpt is available for this finding.

MCP server referenced without pinned version: 'npx skills'.

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding

The collection-install command executes an unpinned npm CLI and retrieves skills from a mutable repository reference. The MCP-server label is inaccurate, but compromised or unexpected upstream updates could still introduce executable code or agent instructions.

Content

No source excerpt is available for this finding.

MCP server referenced without pinned version: 'npx skills'.

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding

The individual-skill installation example leaves both the installer version and repository revision unpinned. Limiting installation to one skill does not eliminate the possibility of receiving changed or compromised upstream content.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
99% confidence
Finding

The curl command sends the API key to a catalog-provided URL after checking only that it is nonempty. A manipulated catalog can therefore select an unauthorized host or HTTP destination; safeguards described for the alternative connectivity script are absent from this shell path.

Content

Scanner excerpt · README.md (reported line 53)May include surrounding context.

md
hit=[r["routing"]["url"] for r in rows if r.get("id")==sys.argv[1] and r.get("routing")]
   print(*hit,sep="\n") if hit else sys.exit("未取到:该 id 不在目录现值里(或它没有 routing 里的 url 字段)——先跑上面那行列出现场的 id 再填")' "$DOMAIN_ID")"
   [ -n "$ROUTING_URL" ] || { echo "取值失败:ROUTING_URL 为空——先跑上面那行列出现场 id,再把 DOMAIN_ID 换成其中之一" >&2; exit 1; }
   curl -s -X POST "$ROUTING_URL" \
     -H "Authorization: Bearer $CUE_API_KEY" \
     -H "Accept: application/json, text/event-stream" \
     -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' \

MCP server referenced without pinned version: 'npx skills'.

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding

This installation command resolves a mutable npm CLI version and mutable skill repository content. It is legitimate installation guidance, but it exposes users to unreviewed upstream changes that may run code or influence an agent.

Content

No source excerpt is available for this finding.

Skill declares no tool scope ('permissions' or 'allowed-tools') but code capabilities were detected: env, file_read, file_write, network, shell.

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

Quote verification accepts materially altered text as verbatim and leaves it unchanged during --fix.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

Normalization removes punctuation and most symbols, including minus signs and decimal points, before checking whether a quote is 'verbatim'. Financially material changes such as '-100' to '100' or '1.23' to '123' can therefore pass verification, bypass subsequent fabricated-number checks, and remain unchanged under --fix; this directly undermines the skill's central evidence-integrity guarantee.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/cue.py (reported line 67)May include surrounding context.

python
def get(url, headers=None, data=None, tries=4):
    for a in range(tries):
        try:
            with urllib.request.urlopen(urllib.request.Request(url, data=data, headers=headers or {'User-Agent': 'Mozilla/5.0'}), timeout=90) as r: return r.read()
        except urllib.error.HTTPError as e:
            if a == tries - 1 or (400 <= e.code < 500 and e.code != 429): raise   # 4xx (except rate limit) will not fix itself on retry
            time.sleep(2 * (a + 1))

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/cue.py (reported line 83)May include surrounding context.

python
finally: doc.close()
    except ImportError:
        import subprocess
        t = subprocess.run(['pdftotext', '-layout', path, '-'], capture_output=True, text=True).stdout.split('\f')
        if len(t) > 1 and not t[-1].strip(): t = t[:-1]            # pdftotext ends with a form feed: no extra empty page
        return t[:max_pages]
class _Txt(__import__('html.parser').parser.HTMLParser):

Tainted flow: 'path' from os.environ.get (line 197, credential/environment) → subprocess.run (code execution)

Medium
Category
Data Flow
Confidence
65% confidence
Finding

Data from a source is assigned to a variable that is later passed to a sink, creating a variable-mediated taint flow.

Content

Scanner excerpt · scripts/cue.py (reported line 83)May include surrounding context.

python
finally: doc.close()
    except ImportError:
        import subprocess
        t = subprocess.run(['pdftotext', '-layout', path, '-'], capture_output=True, text=True).stdout.split('\f')
        if len(t) > 1 and not t[-1].strip(): t = t[:-1]            # pdftotext ends with a form feed: no extra empty page
        return t[:max_pages]
class _Txt(__import__('html.parser').parser.HTMLParser):