Back to skill

Security audit

gongwen-docx

Security checks for vulnerabilities and agentic risk

Overview

This appears to be a legitimate local document-formatting skill, but it deserves review because it can overwrite a Word document in place without a backup and may apply official-document formatting too broadly.

Install only if you specifically need Chinese 公文/GB/T 9704-2012 Word formatting. Keep source files and important .docx files backed up before running the postprocessor, and avoid using it for generic reports or ordinary Word cleanup unless you explicitly want this official-document format.

Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (3)

Vague Triggers

Medium
Confidence
91% confidence
Finding
The invocation criteria are broad enough to trigger on generic document-editing or formatting requests, which can cause the agent to apply this skill when the user did not ask for Chinese official-document conversion. Over-broad activation increases the chance of unintended file transformations, unexpected tool use, and user-confusing behavior, especially because the skill can process existing documents and enforce rigid formatting defaults.

Natural-Language Policy Violations

Medium
Confidence
86% confidence
Finding
The skill states that it defaults to Chinese official-document formatting whenever the user does not specify another standard, without requiring explicit opt-in for locale, document type, or output convention. This can override user intent, produce materially incorrect documents, and in enterprise settings may cause compliance or workflow errors if a normal report or memo is silently converted into a formal 公文 structure.

Missing User Warnings

Medium
Confidence
93% confidence
Finding
The script deletes the original .docx and recreates it in place, so any interruption during repackaging or any malformed input/output condition can permanently destroy the only copy of the document. In the context of a document-conversion skill, this is especially risky because it operates on user-supplied files and users may not expect destructive behavior from a formatting post-processor.

Static analysis

No suspicious patterns detected.