Back to skill

Security audit

ancient-term-normalization

Security checks for vulnerabilities and agentic risk

Overview

This skill appears to do the disclosed local data-normalization task, with a minor dependency-management caveat.

Reasonable to install for local humanities text normalization if you are comfortable with a Python script that reads a chosen input file and writes output in the workspace. For stronger supply-chain safety, install it in a virtual environment and pin or hash-lock PyYAML before production use.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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)

T08 · Insecure Dependencies

Warning
Location
scripts/requirements.txt:1
Finding

Unpinned Third-Party Dependency Creates a Supply-Chain Risk

Content
View full analysis
=6.0 ``` `README.md:8`: ```markdown 1. Install dependencies from `scripts/requirements.txt` in a virtual environment. ``` ### Technical Analysis The dependency declaration uses only a lower version bound. Consequently, package installers may resolve any current or future PyYAML release satisfying `>=6.0`. The project does not include an exact version pin, lockfile, package hash, or trusted package-index configuration. This prevents users from reliably reproducing the dependency version covered by the audit. If a compatible future release or configured package index is compromised, following the documented installation procedure could install unaudited code. The installed package is subsequently imported by `scripts/normalize_terms.py:30-36`: ```python try: import yaml except ImportError: print("PyYAML is required to run this script. Please install pyyaml.", file=sys.stderr) return {} with open(path, 'r', encoding='utf-8') as f: return yaml.safe_load(f) ``` The use of `yaml.safe_load` appropriately mitigates unsafe YAML object deserialization, but it does not mitigate compromise of the dependency package itself. ### Attack Path 1. A user follows the installation instruction in `README.md`. 2. The package installer resolves `PyYAML>=6.0` through the user's configured package index. 3. A compromised or malicious compatible release is selected because no exact version or integrity hash restricts resolution. 4. Dependency-controlled code may execute during package installation or when `yaml` is imported by the normalization script. 5. The malicious dependency operates with the permissions of the user or service running the installation and Skill. This path req ...[truncated 992 chars]
Remediation
View remediation
``` 2. Generate and maintain a hash-locked dependency file. Require hash verification during installation, for example: ```bash python -m pip install --require-hashes -r scripts/requirements.txt ``` 3. Record hashes for every permitted distribution and platform rather than copying an unverified hash. 4. Use a trusted, explicitly configured package index or an internally controlled dependency mirror. 5. Add automated dependency vulnerability and provenance checks to the release process. 6. Perform dependency upgrades through a controlled review process, regenerate hashes, run the test suite, and audit relevant release changes before publishing the updated Skill. 7. Continue installing dependencies in an isolated environment and enforce the documented sandbox restrictions, including no network access at runtime and least-privilege workspace permissions. ]]>
Vulnerability Patterns
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
Findings (6)

Lp1

High
Category
MCP Least Privilege
Confidence
75% confidence
Finding

The skill uses 'file_read' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

Lp1

High
Category
MCP Least Privilege
Confidence
75% confidence
Finding

The skill uses 'file_write' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

Lp1

High
Category
MCP Least Privilege
Confidence
55% confidence
Finding

The skill uses 'shell' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

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 · tests/test_normalize_terms.py (reported line 24)May include surrounding context.

python
workspace.mkdir()
    # Run script
    script_path = Path(__file__).parent.parent / "scripts" / "normalize_terms.py"
    subprocess.check_call([
        "python", str(script_path), "--input", str(input_path), "--workspace", str(workspace)
    ])
    # Check output

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
94% confidence
Finding

The dependency is specified as PyYAML>=6.0, which allows any future major or minor release and makes builds non-reproducible. This can introduce vulnerable or incompatible versions into the skill at install time, especially given PyYAML's history of security advisories related to unsafe parsing and input handling.

Content

Scanner excerpt · scripts/requirements.txt (reported line 1)May include surrounding context.

text
PyYAML>=6.0

Unverifiable Dependency: PyYAML has 8 known advisory(ies) (CVE-2019-20477 (Deserialization of Untrusted Data in PyYAML); CVE-2020-1747 (Improper Input Validation in PyYAML); CVE-2020-14343 (Improper Input Validation in PyYAML) +5 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
87% confidence
Finding

PyYAML has multiple historical advisories, and because the manifest does not pin an exact version, it is impossible to verify whether installations will receive a fixed or vulnerable release. In a skill that processes OCR-derived JSON and likely performs data transformation, the danger depends on how PyYAML is used elsewhere, but leaving the version open unnecessarily increases supply-chain and exposure risk.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.