T09 · Insecure Skill Coding Practices
- Location
scripts/hotel_analysis.py:73- Finding
Unescaped User-Controlled Data Injected into Generated Markdown Reports
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill appears to be a basic hotel report generator, but its advertised automatic hotel-search capability is not implemented and it has avoidable input-handling and dependency risks.
Review this before installing if you need real automatic competitor discovery: the packaged script does not implement that feature. If used anyway, run it only on trusted Excel files or manually entered data, review generated Markdown before sharing, and consider pinning/removing dependencies before installation.
scripts/hotel_analysis.py:73Unescaped User-Controlled Data Injected into Generated Markdown Reports
requirements.txt:1Unpinned and Unnecessary Third-Party Dependencies Increase Supply-Chain Exposure
The skill description promises automatic nearby-hotel discovery and report generation, but the reported implementation does not actually perform that workflow and includes a non-functional auto-fetch path. This mismatch is dangerous because users and orchestrators may make trust and execution decisions based on false capability claims, leading to silent failures, misleading analysis, or unsafe assumptions about external data collection.
The README presents all user-facing instructions in Chinese and does not indicate that the skill is region-specific or provide any opt-in for language selection. This can violate language/locale policy when users are not given a choice or informed of the restriction.
The skill advertises executable behavior with file-writing capability but does not declare any tool scope such as permissions or allowed-tools. That creates an authorization and transparency gap: a host system or user cannot easily determine what the skill is permitted to do, increasing the risk of unintended file modification or abuse if the implementation writes reports or other artifacts.
The natural-language description and instructions are entirely in Chinese, with no indication that users may choose another language or that the skill is intentionally limited to a Chinese-speaking or region-specific audience. The policy requires flagging language or locale constraints when they are imposed without user opt-in or clear justification.
The manifest describes a skill that 'automatically searches nearby hotels' and generates a competitive analysis report. In this implementation, the CLI accepts manually provided competitors or imports them from Excel, while the '--auto-fetch' path only prints that API configuration is required and does not perform any search. This is a substantive mismatch between the advertised capability and the actual code behavior.
The skill description omits a clear warning that it may query an external map service API for nearby-hotel data. This is a transparency and privacy issue because users may not realize that their hotel name, location context, or usage patterns could be sent to a third party.
The dependency is specified with a lower bound only, which allows future installs to resolve to different versions over time. This weakens build reproducibility and can unintentionally introduce vulnerable or breaking releases into the skill's environment.
requests>=2.28.0
pandas>=1.5.0
openpyxl>=3.0.0
pyyaml>=6.0
The manifest does not pin requests, so it is impossible to verify from this file whether deployment will use a version affected by known advisories. Because requests handles outbound HTTP traffic and may interact with credentials, ambiguity around its installed version creates avoidable supply-chain and runtime risk.
Using an unpinned pandas version means installations are not reproducible and may pull in newer releases with security or compatibility issues. In security-sensitive workflows, this increases supply-chain uncertainty even if no exploit is present in the file itself.
requests>=2.28.0
pandas>=1.5.0
openpyxl>=3.0.0
pyyaml>=6.0
argparse>=1.4.0
Because pandas is not pinned, the security posture of the installed environment cannot be validated from the manifest alone. This is a weaker issue than active vulnerable code, but it still undermines assurance and reproducibility.
An unpinned openpyxl dependency can resolve to different versions across environments, making it hard to verify whether known vulnerable releases are excluded. This is especially relevant for libraries that process complex file formats such as spreadsheets.
requests>=2.28.0
pandas>=1.5.0
openpyxl>=3.0.0
pyyaml>=6.0
argparse>=1.4.0
The requirements file does not establish which openpyxl version will be installed, so known vulnerable historical releases cannot be ruled out. Since openpyxl processes spreadsheet content, inability to verify patch level is a meaningful but low-severity dependency management risk.
PyYAML has a history of unsafe deserialization issues, and leaving it unpinned makes it unclear which behavior and security fixes will be present at install time. In a skill ecosystem, YAML is commonly used for configuration, so version drift can materially increase risk if unsafe loading is used elsewhere in the project.
requests>=2.28.0
pandas>=1.5.0
openpyxl>=3.0.0
pyyaml>=6.0
argparse>=1.4.0
# Optional dependencies
PyYAML has multiple past advisories involving unsafe parsing behavior, and the unpinned manifest prevents confirmation that only patched versions will be installed. Given the common use of YAML for configuration in skills, this uncertainty is more concerning than for a purely auxiliary package.
Dependencies lack version pinning, allowing potential malicious package updates. Consider pinning versions.
pandas>=1.5.0
openpyxl>=3.0.0
pyyaml>=6.0
argparse>=1.4.0
# Optional dependencies
# scrapling>=1.0.0 # For OTA scraping (advanced mode)