T09 · Insecure Skill Coding Practices
- Location
SKILL.md:32- Finding
API Key Persisted in an Unprotected Plaintext File
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is mostly scoped to ComPDF PDF encryption and decryption, but it needs review because it can steer users into obsolete RC4 encryption and stores the ComPDF API key in a local plaintext file.
Install only if you are comfortable sending PDFs and document passwords to ComPDF and storing the ComPDF API key locally. Prefer AES-256 explicitly for new encryption, avoid RC4 unless you have a narrow legacy requirement, and protect or rotate the API key if the skill directory may be synced, shared, or published.
SKILL.md:32API Key Persisted in an Unprotected Plaintext File
references/official-api-reference.md:7020Obsolete RC4 Encryption Is Supported, Defaulted, and Demonstrated
Referenced artifact was not completely inspected
3. Read the matching heading in `references/official-api-reference.md`. Use its exact endpoint path, request fields, request mode, and response fields; do not i
Referenced artifact was not completely inspected
6. Resolve credentials only from `api_key` in the directory containing this `SKILL.md`. Read its first non-empty line. Do not inspect environment variables or a
The reference file exposes a much broader capability surface than the skill metadata advertises, including conversion, editing, AI extraction, and comparison endpoints. In an agent setting, this mismatch can enable unintended or covert use of high-impact actions on user documents under the cover of a narrowly described encrypt/decrypt skill.
Documenting broad document-conversion APIs in an encrypt/decrypt skill creates unnecessary privilege expansion and a misleading trust boundary. An agent could leverage these extra endpoints to transform or export user content into easier-to-exfiltrate formats unrelated to the stated purpose.
Including AI document parsing and extraction APIs in a skill presented as PDF security materially expands access from access-control operations into full content extraction. That creates a risk of sensitive-document exfiltration or overcollection, especially because these endpoints can process uploaded files and return structured extracted data.
The documentation describes uploading user files to a third-party ComPDF API but does not clearly warn users that document contents leave the local environment and are stored/processed externally. For document-security workflows, this omission is especially risky because users may assume encryption-related handling is local or privacy-preserving by default.
PDF editing and content-modification features such as delete, extract, insert, watermark, and compression exceed the stated access-protection purpose and broaden the blast radius of misuse. In an agentic workflow, these actions can silently alter, strip, or repackage user documents in ways the user did not intend.
The file documents operations such as page deletion and decryption/removal of protections as standard features, but it does not include a caution that these actions alter document contents or protections and may be irreversible if originals are not retained. For markdown guidance, safety-relevant behaviors that affect user data integrity should be accompanied by explicit warnings.
Several parameter descriptions switch from English to Chinese-only text inside an otherwise English reference, which can prevent users from understanding operational details unless they know Chinese. This is a natural-language locale policy issue because the file does not offer a language choice or clearly justify the locale-specific constraint.
This line is one of multiple Chinese-only parameter descriptions embedded in the English reference, creating inconsistent accessibility for users who expect a single language. Because no opt-in or locale selection is provided, this conflicts with the requirement to avoid forcing a specific language unexpectedly.
The extraction-mode and options descriptions are partially or fully in Chinese, despite the surrounding content being English. Users are not given an explicit choice of locale, so critical usage details become accessible only to readers of one language.