generating-swift-package-docs

Pass

Audited by Gen Agent Trust Hub on Sep 15, 2026

Risk Level: SAFECOMMAND_EXECUTIONINDIRECT_PROMPT_INJECTION
Full Analysis
  • [COMMAND_EXECUTION]: The script scripts/generate_docs.py executes external CLI tools using the subprocess.run function. It calls git describe and git tag to determine package versions within the dependency directories, and it runs the interfazzle CLI tool to generate documentation from Swift modules located in the Xcode DerivedData directory. Although the commands are constructed using list arguments to prevent shell injection, the skill relies on the integrity of external tools when processing files from third-party dependencies.
  • [INDIRECT_PROMPT_INJECTION]: The skill is vulnerable to indirect prompt injection because it ingests untrusted content from external Swift packages.
  • Ingestion points: The script reads Package.resolved and Package.swift files, and extracts content from README.md, README.txt, or README.markdown files found in the package source.
  • Boundary markers: While the generated output uses markdown headers (e.g., # Package README) to delimit sections, it lacks specific instructions to the agent to disregard any commands or prompts embedded in that content.
  • Capability inventory: The skill performs file system operations (read/write) and executes subprocesses based on information gathered from these external files.
  • Sanitization: The content from README files and package manifests is processed and presented to the agent in its raw form, allowing potentially malicious instructions in a dependency to influence agent behavior.
Audit Metadata
Risk Level
SAFE
Analyzed
Sep 15, 2026, 06:23 AM