Back to skill

Security audit

Skill Publish

Security checks for vulnerabilities and agentic risk

Overview

The skill is not overtly malicious, but it needs Review because it can exceed the intended product-folder boundary and can generate unsupported financial report statements.

Install only if you are comfortable reviewing the generated report before use, editing config.json to a deliberate output path, and running it only on trusted product folders without symlinks. Treat generated financial and contractual statements as drafts until verified against source documents, and prefer pinned dependency versions before using it on untrusted files.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/evidence_pipeline/cache.py:22
Finding

Symlink-Based Access to Files Outside the Product Directory

Content
View full analysis
list[Path]: product_dir = Path(product_dir).resolve() return sorted( path for path in product_dir.rglob("*") if path.is_file() and CACHE_DIRNAME not in path.relative_to(product_dir).parts and path.name not in {".DS_Store", "Thumbs.db"} ) ``` The accepted files are subsequently opened and hashed: ```python def sha256_file(path: Path, chunk_size: int = 1024 * 1024) -> str: digest = hashlib.sha256() with Path(path).open("rb") as handle: for chunk in iter(lambda: handle.read(chunk_size), b""): digest.update(chunk) return digest.hexdigest() ``` Supported text files are also read into the evidence pipeline: ```python if suffix in {".txt", ".md", ".csv"}: text_by_relative[relative] = path.read_text( encoding="utf-8", errors="replace" ) ``` ### Technical Analysis The containment check is performed against the lexical path returned by `Path.rglob()`. However, `is_file()`, `open()`, and `read_text()` follow symbolic links by default. The code does not resolve each candidate file and verify that the resolved target remains beneath the resolved product directory. Consequently, a symbolic link located inside the supplied product directory can point to any file readable by the process account. The expression below only proves that the symlink itself appears inside the directory; it does not prove that its target is inside the directory: ```python path.relative_to(product_dir) ``` The external target can be hashed, inventoried, and read into the evidence cache. If its content matches recognized ...[truncated 1370 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
requirements.txt:2
Finding

Unpinned and Unhashed Third-Party Dependencies

Content
View full analysis
=0.10.0 pypdfium2>=4.0.0 Pillow>=10.0.0 openpyxl>=3.1.0 xlrd>=2.0.0 pandas>=2.0.0 # Optional: OCR support (only needed if enable_ocr=true in config.json) # rapidocr-onnxruntime>=1.3.0 ``` The installation documentation directs users to install these unconstrained dependencies: ```bash pip install -r requirements.txt ``` It also documents an unconstrained optional dependency: ```bash pip install rapidocr-onnxruntime ``` ### Technical Analysis Every declared dependency uses a lower-bound version constraint rather than an exact reviewed version. No lock file or package hash is supplied. As a result, installations performed at different times can resolve to different package versions. Future releases that satisfy the lower bound can be downloaded and executed even though they were not represented in the audited project. This is particularly relevant because these dependencies process attacker-controlled PDFs, images, and spreadsheets. Parser updates can introduce vulnerabilities or changed behavior, while a compromised package release could execute code during installation or import. ### Attack Path 1. A user follows the documented installation procedure. 2. `pip` resolves the newest available releases satisfying the lower-bound constraints. 3. The installer does not verify package files against project-controlled hashes. 4. A compromised, malicious, or newly vulnerable release is installed. 5. Package code executes during installation, import, or document parsing with the privileges of the user running the Skill. ### Impact Assessment A malicious dependency release could execute arbitrary code with the current user's privileges. This could permit access to l ...[truncated 348 chars]
Remediation
View remediation
pypdfium2== Pillow== openpyxl== xlrd== pandas== ``` 2. Generate a lock file that includes transitive dependencies. 3. Record SHA-256 hashes and require hash verification during installation: ```bash python -m pip install --require-hashes -r requirements.lock ``` 4. Pin and hash optional OCR dependencies using the same process. 5. Use a controlled update workflow that includes: - Vulnerability scanning. - Release-note review. - Parser regression testing. - Rebuilding hashes only after review. - Testing against untrusted PDF and workbook samples. 6. Document supported Python and platform versions so dependency resolution remains deterministic. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
scripts/generate_report.py:319
Finding

Unsupported Hard-Coded Financial and Contractual Claims in Generated Reports

Content
View full analysis
**红利不确定性提示**:保单红利是不确定的,某些年度可能为零。红利分配取决于公司分红保险业务的实际经营成果。" ) ``` It inserts a generalized break-even assertion: ```python sections.append("1. **回本年限**:多久能回本(通常3-5年)") ``` It also inserts fixed surrender statements without checking the supplied contract: ```python sections.append("- 犹豫期内退保:扣除不超过10元工本费后退还全部已交保费") sections.append("- 犹豫期后退保:退还合同现金价值,前期现金价值较低,退保会有较大损失") ``` The output checker only searches for a limited set of prohibited terms: ```python forbidden = ["请审查", "待基于", "未提供", "未载明", "无法判断"] for term in forbidden: if term in text: errors.append(f"Forbidden term found: '{term}'") ``` ### Technical Analysis The Skill explicitly states that every conclusion must come from the supplied product files and that external assumptions or generalized industry statements must not be used. The report generator nevertheless emits financial and contractual claims independently of extracted evidence. The break-even statement is especially inconsistent with the source-only requirement because it uses generalized wording asserting a typical three-to-five-year period. The fixed surrender fee, refund behavior, and dividend statement may also differ between contracts. These statements are not conditioned on corresponding evidence records and do not carry evidence identifiers. The output checker validates report structure and a narrow prohibited-term list, but it does not establish claim-level provenance or reject all speculative terms. The documented workflow also requires user confirmation of the detected product t ...[truncated 1907 chars]
Remediation
View remediation
Vulnerability Patterns
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • 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
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (23)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

This is a clear description-behavior mismatch. The declared purpose describes a document-processing and knowledge-base-output skill for insurance product拆解, implying ingestion of multiple product files, extraction/summarization, and persistence to Obsidian. The supplied code does none of that. Instead, it is a small calculation module for insurance cash-flow analysis: converting table units, computing IRR, deriving break-even metrics, and validating dividend cash-flow representations. These functions may be supportive components within a larger insurance analysis system, but taken as the supplied code chunk, they do not implement the declared workflow or outputs. There are no concerning undeclared external accesses or permissions; the mismatch is primarily that the actual code is materially narrower and different in purpose from the declared end-user functionality.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The declared description presents a high-level insurance product analysis pipeline over a directory of heterogeneous source documents, with a final Markdown knowledge-base output. The supplied code chunk is a narrow utility for workbook extraction. Its purpose is to read .xlsx/.xls files and preserve spreadsheet provenance details such as merged cells, hidden rows/columns, headers, and sample rows. While spreadsheets like rate tables or cash value tables could be supporting inputs in the broader system, this code alone does not implement the declared end-user behavior and lacks key described capabilities such as document-directory traversal, insurance-specific decomposition, Markdown authoring, and Obsidian persistence. Therefore the description does not accurately represent what this code chunk actually does.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The code is clearly related to insurance product analysis, so the general domain matches the description. However, the declared purpose says the skill should decompose insurance product files into structured Markdown and store the result in an Obsidian knowledge base. This code instead provides a command-line evidence-processing pipeline: it builds cached evidence from PDFs, spreadsheets, and text, creates inventory/evidence JSON, supports querying evidence, computes scenario metrics, validates reports, and generates report-input JSON. Those are materially different operational capabilities and outputs. The missing Markdown/Obsidian behavior and the added calculation/validation/checking features make this a description-behavior mismatch.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
84% confidence
Finding

The skill declares capabilities that read from and write to local files, including writing generated Markdown into an Obsidian vault, but it does not define an explicit tool scope such as allowed-tools or permissions. Without an explicit scope boundary, an agent may have broader-than-necessary filesystem access, which raises the risk of unintended file reads, overwrites, or writes outside the intended vault.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The activation description is broad enough that the skill could trigger on loosely related insurance-analysis tasks, increasing the chance of unintended execution. In a skill that can read directories and write into a knowledge base, over-broad triggering raises the risk of processing the wrong dataset or modifying local files when the user did not intend to invoke this workflow.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The skill instructs writing output into an Obsidian knowledge base but does not prominently warn the user that local files will be created or modified. This can lead to silent or surprising filesystem changes, including overwriting notes, polluting a vault with incorrect analyses, or writing to a misconfigured path.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
80% confidence
Finding

The operational instructions, prompts, and output expectations are entirely in Chinese, which imposes a language preference on users and downstream interactions. The file does not offer an opt-in language choice or explain that the skill is intentionally limited to a Chinese-language regulatory or business context.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The file enforces specific Chinese clause names as mandatory report inputs, which imposes a language/locale requirement in the skill behavior. Because there is no visible opt-in, language selection, or documented region-specific justification in this file, this is a natural-language locale policy concern.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The report checker requires Chinese markdown section titles and Chinese YAML field names, meaning reports in other languages would be treated as invalid. This constitutes a language/locale restriction, and the file does not show a user choice mechanism or explicit justification for the constraint.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The TOC detection and quote scoring logic is hard-coded around Chinese phrases and Chinese punctuation, such as '条款目录', '阅读指引', '本条款第', ',', and '。'. This creates a locale-specific behavior in the skill without any visible user choice or justification in the file, which matches the language/locale policy violation criteria.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The scoring function increases quality scores when quotes contain Chinese punctuation and specific Chinese insurance terms, which can systematically disadvantage non-Chinese content. Because the file does not present this as an explicit region-specific or user-selected mode, it appears to force a language-specific policy implicitly.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The file hard-codes required report module titles and metadata keys entirely in Chinese, which effectively forces a specific language/locale for valid inputs. Under the policy, locale-specific constraints should either offer user choice or be explicitly documented as justified for a region-specific tool.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The extractor deliberately enumerates every worksheet and captures rows, hidden rows, hidden columns, merged regions, and sheet visibility, which means hidden spreadsheet content will be ingested and propagated just like visible data. In this skill context, insurance product workbooks may contain internal notes, draft assumptions, or sensitive business data in hidden areas, so extracting them without an explicit consent gate or disclosure creates a real data over-collection and privacy/confidentiality risk.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The path includes a Chinese-named vault directory ("LZQuinn的藏经阁"), which suggests the skill is tied to a specific language/locale context. In this config file, there is no natural-language indication that users can choose another language/locale or that this constraint is documented and justified.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
96% confidence
Finding

The dependency is specified with a lower bound only, so installs may resolve to different versions over time and across environments. This weakens supply-chain control, makes builds non-reproducible, and can silently introduce vulnerable or incompatible releases into a skill that processes untrusted document inputs.

Content

Scanner excerpt · requirements.txt (reported line 2)May include surrounding context.

text
# Core dependencies
pdfplumber>=0.10.0
pypdfium2>=4.0.0
Pillow>=10.0.0
openpyxl>=3.1.0

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
96% confidence
Finding

The dependency is unpinned and therefore the actual installed pypdfium2 version is not deterministic. For a package involved in PDF handling, this increases supply-chain and patch-management risk because future installs may pull a release with newly introduced flaws or behavior changes.

Content

Scanner excerpt · requirements.txt (reported line 3)May include surrounding context.

text
# Core dependencies
pdfplumber>=0.10.0
pypdfium2>=4.0.0
Pillow>=10.0.0
openpyxl>=3.1.0
xlrd>=2.0.0

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
99% confidence
Finding

Pillow is unpinned despite being a parser for image content, and the skill's workflow may encounter embedded images or OCR-related inputs from untrusted insurance documents. Because the resolved version is uncontrolled, deployments could unintentionally install a Pillow release affected by known memory-safety, RCE, or resource-exhaustion issues.

Content

Scanner excerpt · requirements.txt (reported line 4)May include surrounding context.

text
# Core dependencies
pdfplumber>=0.10.0
pypdfium2>=4.0.0
Pillow>=10.0.0
openpyxl>=3.1.0
xlrd>=2.0.0
pandas>=2.0.0

Unverifiable Dependency: Pillow has 16 known advisory(ies) (CVE-2016-2533 (Pillow buffer overflow in ImagingPcdDecode); CVE-2023-50447 (Arbitrary Code Execution in Pillow); CVE-2021-27922 (Pillow Uncontrolled Resource Consumption) +13 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
97% confidence
Finding

This is a true risk because Pillow has multiple known advisories and the manifest does not pin a version, so there is no way to verify that deployed environments avoid affected releases. The skill context raises concern because image/PDF processing often handles untrusted files, which can turn parser bugs into denial of service or, in worst cases, code execution.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
98% confidence
Finding

openpyxl is unpinned even though the skill processes spreadsheet-like insurance artifacts such as rate tables and cash value tables. If an environment resolves to a vulnerable release, XML-related parsing issues could be exposed through attacker-controlled workbook content, making version ambiguity a real security concern.

Content

Scanner excerpt · requirements.txt (reported line 5)May include surrounding context.

text
pdfplumber>=0.10.0
pypdfium2>=4.0.0
Pillow>=10.0.0
openpyxl>=3.1.0
xlrd>=2.0.0
pandas>=2.0.0

Unverifiable Dependency: openpyxl has 2 known advisory(ies) (CVE-2017-5992 (Improper Restriction of XML External Entity Reference in Openpyxl); CVE-2017-5992 (Openpyxl 2.4.1 resolves external entities by default, which allows remote attack)), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
95% confidence
Finding

openpyxl has known historical advisories, and without a pinned version the deployment cannot be verified as patched. Because this skill is expected to parse insurer-provided or user-supplied Excel documents, a vulnerable XML parsing path could be reachable through crafted workbook content.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
95% confidence
Finding

xlrd is specified with a minimum version only, which leaves the exact installed version uncontrolled. While not tied here to a specific known advisory, unpinned parser dependencies still create supply-chain and reproducibility risk in a workflow that consumes external spreadsheet files.

Content

Scanner excerpt · requirements.txt (reported line 6)May include surrounding context.

text
pypdfium2>=4.0.0
Pillow>=10.0.0
openpyxl>=3.1.0
xlrd>=2.0.0
pandas>=2.0.0

# Optional: OCR support (only needed if enable_ocr=true in config.json)

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
97% confidence
Finding

pandas is unpinned, so installations may drift to different releases without review. In a document-ingestion skill that manipulates spreadsheet/tabular data, this increases the chance of pulling in a vulnerable or behavior-changing build and complicates incident response and patch verification.

Content

Scanner excerpt · requirements.txt (reported line 7)May include surrounding context.

text
Pillow>=10.0.0
openpyxl>=3.1.0
xlrd>=2.0.0
pandas>=2.0.0

# Optional: OCR support (only needed if enable_ocr=true in config.json)
# rapidocr-onnxruntime>=1.3.0

Unverifiable Dependency: pandas has 1 known advisory(ies) (CVE-2020-13091 (** DISPUTED ** pandas through 1.0.3 can unserialize and execute commands from an)), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependency has known vulnerabilities (CVEs). Using packages with unpatched security flaws exposes the environment to known exploits.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.