T05 · Unauthorized Access and Privilege Escalation
- Location
src/tools/security-audit.js:66- Finding
Unrestricted Caller-Controlled Filesystem Reads
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is a coherent code review assistant, but it can be asked to read local files outside a project and can generate unsafe HTML reports.
Review this skill before installing in sensitive environments. Use it only in a sandbox or workspace-scoped runtime, avoid letting untrusted prompts choose file paths, do not open generated HTML reports from untrusted code until escaping is fixed, and confirm any real AI-provider integration and data handling before enabling external analysis.
src/tools/security-audit.js:66Unrestricted Caller-Controlled Filesystem Reads
src/tools/report-generator.js:330Stored HTML Injection in Generated Review Reports
File: ${results.summary?.filePath || 'Not specified'}
``` Critical issue fields and analyzed source snippets are also embedded without escaping: ```javascript criticalIssues.forEach((issue, index) => { html += `Location: Line ${issue.line}
Severity: ${issue.severity}
Suggestion: ${issue.suggestion || 'Refer to best practices'}
`; if (issue.codeSnippet) { html += `${issue.codeSnippet}Referenced artifact was not completely inspected
node test/basic.test.js
The README states that AI features are integrated with the iFlytek Spark API, but it does not clearly warn users that reviewed source code may be sent to a third-party service when AI analysis is enabled. In a code-review skill, uploaded code can contain proprietary logic, secrets, credentials, or regulated data, so missing disclosure can lead to unintended data exposure and compliance violations.
The skill advertises AI-driven review and notes that external network access is used for AI analysis, but it does not clearly warn users that submitted source code may be transmitted to a third-party AI provider. In a code-review context, this can expose proprietary code, credentials, secrets, or regulated data to an external service without informed consent.
The manifest description is entirely in Chinese, while the skill is otherwise presented as a general-purpose code review assistant with no documented locale limitation or user language choice. This creates a natural-language policy concern because it implicitly constrains the skill to a specific language without opt-in or justification.
This code includes multiple user-facing console messages and descriptive text in Chinese, such as initialization and setup logs, while the skill does not provide any user opt-in or alternative locale handling. Under the stated policy, forcing a specific language without user choice is a natural-language policy violation.
The file’s descriptive strings and user-facing messages are written in Chinese, and the implementation presents these messages directly without any indication that users can choose another language. This can violate language or locale policy when the skill imposes a single language by default without opt-in or documented regional justification.
The control flow in generateAIRecommendations says that if an AI API key and provider are supplied, it will use the real API. However, callIflytekSparkAPI is explicitly documented and implemented as a simulated implementation that returns mock data after a timeout. This is an active contradiction between the code comments/control-flow intent and the actual behavior.
When an API key and provider are configured, the function passes the full code and issue data to callIflytekSparkAPI, which represents transmission to an external service. Although there is a console log about calling the API, there is no explicit user disclosure or confirmation that source code may be sent off-system, and this operation is not clearly justified as an expected deploy-like action in the file itself.
getAIRecommendationDescription advertises provider-backed AI capabilities, including real-time AI analysis, batch processing, and API-key-enabled full functionality. In reality, the only provider-specific function is a mock that does not make network requests and instead synthesizes recommendations locally. This creates an intent-code divergence in the skill's own descriptive interface.
This JavaScript file contains user-facing natural-language descriptions, messages, and console output exclusively in Chinese. The policy only permits a fixed language when the skill offers a language choice or clearly documents a justified locale constraint, neither of which appears here.
This JavaScript file contains natural-language comments and user-visible console output in Chinese, such as the analyzer description and status messages. Under the policy rule for language/locale, forcing a specific language without user opt-in or justification is a policy violation.
The status log 📊 分析代码质量... is a user-visible string in Chinese, and similar messages later in the file also assume Chinese as the only language. This violates the language/locale policy unless the skill offers a language choice or is clearly documented as region-specific.
The completion and error messages are emitted only in Chinese, including success, warning, and failure text. Because the file provides no mechanism for locale selection and no documented regional constraint, this is a natural-language policy issue.
This JavaScript file contains natural-language descriptions and user-facing console messages in Chinese, such as the file header and analyzer output text. Because the skill does not offer language selection or justify a Chinese-only locale, it conflicts with the policy against forcing a specific language without user opt-in.
The analyzer prints status, warning, and error messages in Chinese, including progress and failure output. These are natural-language strings that impose a specific language on users or operators without any visible mechanism to choose another locale.
The file’s user-facing natural-language strings and documentation are entirely in Chinese, including the tool description and execution messages. This creates a locale/language constraint without any indication that the user can choose another language or opt in, which matches the language-policy violation category.
This code's descriptive comments and runtime console messages are entirely in Chinese, including user-visible status and error text. Under the stated policy, forcing a specific language without user opt-in is a natural-language locale violation unless the constraint is explicitly documented and justified, which is not present here.
This JavaScript file contains all user-facing text in Chinese, including the tool description and execution-status messages, with no indication that the skill is China-specific or that users can choose another language. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation.
The generated HTML sets lang="zh-CN", and the file consistently emits Chinese-only report titles, labels, and messages. This forces a specific language/locale on users without any opt-in, fallback, or documented region-specific justification, which matches the language/locale policy violation criteria.
This JavaScript file contains natural-language strings and comments such as '安全审计工具' and '执行安全审计...', with no indication that users can choose another language. Per the policy, forcing a specific language/locale without opt-in is a natural-language policy violation.
This .js file contains natural-language strings and comments in Chinese, including user-facing console output throughout the test flow. Under the policy rule, forcing a specific language without user opt-in is a locale/language policy violation, and this file provides no mechanism to select another language or justification that it is intentionally region-specific.
Natural-language content throughout the README is presented only in Chinese, which can impose a language constraint on users without opt-in. The policy allows locale constraints when they are explicitly justified or when users are offered a choice, neither of which appears here.
The natural-language content throughout the skill documentation is presented in Chinese, including usage guidance and operational instructions. The file does not indicate that users can choose another language or that the Chinese-only presentation is a documented, justified locale constraint.
The code standards section says '使用 TypeScript 开发' at L360, but the documented project structure lists src/index.js and JavaScript-based examples throughout the file (for example L187-L226 and L324-L335). This is an active documentation-to-implementation contradiction rather than a mere omission.
The manifest-style metadata uses Chinese-only descriptions in fields intended to describe the skill, but provides no indication that the skill is China-specific or that users can choose another language. This can violate language/locale policy expectations when a skill implicitly forces a language without user opt-in.
Detected: suspicious.dynamic_code_execution, suspicious.exposed_secret_literal