Back to skill

Security audit

1、不依赖任何第三方 PPT 服务; 2、给可以自行上传ppt模板和内容资料,约束让大模型根据上传的内容生成最终的成品 3.自动导出生成.pptx格式的文件

Security checks for vulnerabilities and agentic risk

Overview

The skill’s PPT-generation purpose is coherent, but its generator and setup workflow expose users to code-execution and unsafe system-level installation risks.

Install only after the maintainer removes the JavaScript injection path, enforces strict color validation, removes normal use of --skip-validation, and replaces the current dependency setup with pinned, local, non-privileged installs. Do not run the printed curl-to-sudo command or install global packages from this skill on a sensitive machine.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • 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)

T03 · Remote Payload Retrieval and Execution

Error
Location
scripts/check_env.py:140
Finding

Remote Installation Script Is Piped Directly into a Privileged Shell

Content
View full analysis
Remediation
View remediation
nodesource-setup.sh" | sha256sum --check - less nodesource-setup.sh sudo bash nodesource-setup.sh ``` The URL and digest must correspond to a specific trusted release, not a mutable “latest” endpoint. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
scripts/generate_ppt.py:201
Finding

Palette Values Permit JavaScript Injection and Arbitrary Node.js Code Execution

Content
View full analysis
dict: """Strip '#' from all hex color fields. Returns cleaned palette.""" if not isinstance(palette, dict): corrections.append("palette was not a dict — replaced with empty palette") return {} cleaned = {} for key, val in palette.items(): if key in HEX_FIELD_KEYS and isinstance(val, str) and val.startswith("#"): cleaned[key] = strip_hash(val) corrections.append(f"palette.{key}: removed '#' prefix (was '{val}' → '{cleaned[key]}')") else: cleaned[key] = val return cleaned ``` The unvalidated values are subsequently inserted into executable JavaScript using single-quoted f-strings: ```python def generate_pptxgenjs_script(plan: dict, output_path: str) -> str: palette = plan.get("palette", {}) primary = palette.get("primary", "1E2761") secondary = palette.get("secondary", "CADCFC") accent = palette.get("accent", "FFFFFF") font_h = plan.get("font_heading", "Calibri") font_b = plan.get("font_body", "Calibri") pres_title = plan.get("title", "Presentation") slides = plan.get("slides", []) lines = [] lines.append("const pptxgen = require('pptxgenjs');") lines.append("const pres = new pptxgen();") lines.append("pres.layout = 'LAYOUT_16x9';") lines.append(f"pres.title = {json.dumps(pres_title)};") lines.append(f"const PRIMARY = '{primary}';") lines.append(f"const SECONDARY = '{secondary}';") lines.append(f"const ACCENT = '{a ...[truncated 3043 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
scripts/check_env.py:293
Finding

Unpinned Dependencies Are Installed into Global or System-Managed Environments

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
Findings (48)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
96% confidence
Finding

The template-based generation path explicitly uses --skip-validation, bypassing the safety and sanitation step that was introduced to clean LLM-generated slide plans. Because the plan and template may both be influenced by untrusted user content, skipping validation can allow malformed or unsafe data to reach the generator, increasing the chance of file corruption, unsafe parser behavior, or unexpected script execution paths depending on downstream implementation.

Content

Scanner excerpt · SKILL.md (reported line 374)May include surrounding context.

--output presentation.pptx
--mode from-template
--template uploaded_template.pptx
--skip-validation

text

**Patch mode — modify specific slides without regenerating the full plan:**

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
87% confidence
Finding

Advertising --skip-validation as a supported generator option normalizes bypassing an important security control. Even if not the default, exposing this flag in skill documentation makes it easier for future prompts, operators, or automated flows to disable sanitization when handling untrusted LLM output or uploaded template/content files.

Content

Scanner excerpt · SKILL.md (reported line 446)May include surrounding context.

md
| `analyze_template.py` | Extract template design system | — |
| `suggest_style.py` | Infer style from content | `--lang`, `--slides` |
| `validator.py` | Sanitize LLM slide plan | `--out`, `--strict` |
| `generate_ppt.py` | Build PPTX (both modes) | `--mode`, `--template`, `--skip-validation`, `--patch` |
| `template_builder.py` | Fill template via python-pptx | `--template`, `--plan`, `--output` |
| `chart_builder.py` | chart dict → PptxGenJS chart code | (imported by generate_ppt.py) |

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · scripts/check_env.py (reported line 141)May include surrounding context.

python
"note":    "Python 3.9+ required",
    },
    "node": {
        "linux":   ["curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -",
                    "sudo apt install -y nodejs",
                    "# or: sudo snap install node --classic"],
        "macos":   ["brew install node",

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · scripts/generate_ppt.py (reported line 8)May include surrounding context.

python
Two modes:
  --mode from-scratch   PptxGenJS — builds a fresh styled presentation
  --mode from-template  template_builder.py — fills content into an uploaded .pptx template
                        (replaces the old "print instructions" stub)

v4 improvements:
  - from-template mode now actually works via template_builder.py

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
95% confidence
Finding

Exposing a --skip-validation flag allows callers to bypass the only explicit safety gate before untrusted slide-plan data is turned into either executable JS or handed to template-processing logic. In this skill context, validation is security-relevant because the tool accepts arbitrary user-supplied content and can trigger downstream code execution or unsafe file processing.

Content

Scanner excerpt · scripts/generate_ppt.py (reported line 368)May include surrounding context.

python
parser.add_argument("--output",   required=True, help="Output .pptx path")
    parser.add_argument("--mode",     choices=["from-scratch", "from-template"], default="from-scratch")
    parser.add_argument("--template", help="Path to .pptx template (required for from-template mode)")
    parser.add_argument("--skip-validation", action="store_true")
    parser.add_argument("--patch",    help='JSON string to patch specific slides, e.g. \'{"slides":[{"index":3,"title":"New Title"}]}\'')
    args = parser.parse_args()

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
89% confidence
Finding

The skill clearly instructs the agent to read and write files and execute shell commands, but it declares no explicit tool scope or allowed-tools policy. That creates an over-privileged integration surface where the host may grant broader capabilities than necessary, increasing the blast radius if prompts, files, or downstream scripts are abused.

Content

No source excerpt is available for this finding.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

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

md
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 133)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

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

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 141)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 142)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 143)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 151)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 159)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 183)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 184)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 185)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

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

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/check_env.py (reported line 194)May include surrounding context.

python
⚠️  OPTIONAL — QA features will be unavailable:

  ▸ LibreOffice  — Optional, needed for QA visual inspection
      $ sudo apt install libreoffice       # Ubuntu/Debian
      $ brew install --cask libreoffice    # macOS

  ▸ pdftoppm  — Optional, needed for QA visual inspection

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · SKILL.md (reported line 52)May include surrounding context.

$ brew install --cask libreoffice # macOS

▸ pdftoppm — Optional, needed for QA visual inspection $ sudo apt install poppler-utils # Ubuntu/Debian $ brew install poppler # macOS ══════════════════════════════════════════════════════

text

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · SKILL.md (reported line 501)May include surrounding context.

$ brew install --cask libreoffice # macOS

▸ pdftoppm — Optional, needed for QA visual inspection $ sudo apt install poppler-utils # Ubuntu/Debian $ brew install poppler # macOS ══════════════════════════════════════════════════════

text

Unrestricted Tool Access

Medium
Category
Excessive Agency
Confidence
80% confidence
Finding

Skill grants unrestricted tool access without appropriate constraints. An agent with unfettered tool access can perform arbitrary actions including file modification, network requests, and code execution.

Content

Scanner excerpt · SKILL.md (reported line 73)May include surrounding context.

md
## Phase 1 — Requirements Gathering

**Do not run any scripts yet.** First collect everything needed through a short conversation.

### Fast-path — Skip questions when info is already provided

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill directs the agent to ask the user a sequence of questions entirely in Chinese, which effectively imposes a specific language on the interaction. The file does not state that Chinese is optional or that the agent should adapt to the user's preferred language, so this is a natural-language locale policy issue.

Content

No source excerpt is available for this finding.

Unsafe Defaults

Medium
Category
Tool Misuse
Confidence
94% confidence
Finding

The prescribed template workflow treats validation bypass as part of the normal command sequence, which is an unsafe operational default for a pipeline consuming untrusted inputs and LLM-produced JSON. In this context, the skill is designed to process arbitrary uploaded files and generated plans, so skipping validation materially increases risk.

Content

Scanner excerpt · SKILL.md (reported line 374)May include surrounding context.

--output presentation.pptx
--mode from-template
--template uploaded_template.pptx
--skip-validation

text

**Patch mode — modify specific slides without regenerating the full plan:**

Unsafe Defaults

Medium
Category
Tool Misuse
Confidence
82% confidence
Finding

Listing skip-validation among core generator flags contributes to an unsafe default posture because it presents safety-control bypass as a routine capability. The surrounding skill context is more dangerous than a closed internal tool because it accepts arbitrary user documents, templates, and LLM-generated plans.

Content

Scanner excerpt · SKILL.md (reported line 446)May include surrounding context.

md
| `analyze_template.py` | Extract template design system | — |
| `suggest_style.py` | Infer style from content | `--lang`, `--slides` |
| `validator.py` | Sanitize LLM slide plan | `--out`, `--strict` |
| `generate_ppt.py` | Build PPTX (both modes) | `--mode`, `--template`, `--skip-validation`, `--patch` |
| `template_builder.py` | Fill template via python-pptx | `--template`, `--plan`, `--output` |
| `chart_builder.py` | chart dict → PptxGenJS chart code | (imported by generate_ppt.py) |

Static analysis

No suspicious patterns detected.