Back to skill

Security audit

还活着么监测服务

Security checks for vulnerabilities and agentic risk

Overview

This skill is a safety check-in service, but it exposes sensitive personal data without access controls and its emergency alerts appear unreliable.

Do not use this for real safety monitoring or sensitive personal data until it has authentication and per-user authorization, encrypted/access-controlled storage, rotated secrets, HTTPS deployment guidance, clear consent and retention policies, and verified emergency-alert delivery. At most, treat it as an isolated local prototype.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
Findings (4)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
src/index.js:42
Finding
Unauthenticated Access and Modification of Sensitive User Records<![CDATA[ ## Vulnerability Details **File Location**: `src/index.js:42-169` **Vulnerability Type**: Missing authentication and object-level authorization with unrestricted CORS **Risk Level**: Critical ### Evidence ```js setupMiddleware() { this.app.use(express.json()); this.app.use((req, res, next) => { res.header('Access-Control-Allow-Origin', '*'); next(); }); this.app.use((req, res, next) => { console.log(`[${new Date().toISOString()}] ${req.method} ${req.path}`); next(); }); } ``` The following sensitive routes are installed without any intervening authentication or authorization middleware: ```js this.app.post('/register', async (req, res) => { // Registration is selected entirely through userId supplied by the caller. }); this.app.post('/checkin', async (req, res) => { // Check-ins are recorded for userId supplied by the caller. }); this.app.get('/status/:userId', (req, res) => { // The requested user is selected directly from the path parameter. }); this.app.get('/history/:userId', (req, res) => { // Check-in history is selected directly from the path parameter. }); this.app.post('/emergency-contacts', async (req, res) => { // Emergency contacts are updated using userId supplied by the caller. }); ``` The underlying status method returns the complete user object: ```js return { ...user, hoursSinceLastCheckin, status, currentTime: now.toISOString() }; ``` ### Technical Analysis The service does not establish an authenticated identity and does not verify that a caller is authorized to access the supplied `userId`. This creates insecure direct object reference and broken object-level authorization vulnerabilities. A caller who knows or guesses a user ID can retrieve status and check-in history. The status response spreads the complete user record into the response, including phone numbers and emergency-contact details. Check-in history can expose messages, mood information, timestamps, and location. ...[truncated 1663 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Require authentication on every endpoint except a minimal health check. 2. Derive the target user identity from a validated session or signed token rather than trusting a caller-supplied `userId`. 3. Enforce object-level authorization before every read or mutation. 4. Separate user and administrator capabilities through explicit roles and least-privilege policies. 5. Prevent registration from silently overwriting an existing user. 6. Require additional verification for emergency-contact changes and notify the account owner when contacts are modified. 7. Return data-transfer objects containing only fields required by each endpoint; never spread the complete stored user object into a response. 8. Restrict CORS to explicitly trusted HTTPS origins and define permitted methods and headers. 9. Add schema validation, rate limiting, audit logging, and user-ID enumeration protections. 10. Add tests proving that one identity cannot read, check in for, register over, or modify contacts for another identity. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
src/utils/userManager.js:56
Finding
Sensitive Personal and Location Data Stored in Plaintext<![CDATA[ ## Vulnerability Details **File Location**: `src/utils/userManager.js:56-77` **Vulnerability Type**: Unencrypted sensitive-data storage with unspecified file permissions **Risk Level**: High ### Evidence ```js saveUsers() { try { fs.writeFileSync(this.usersFile, JSON.stringify(this.users, null, 2)); } catch (error) { console.error('保存用户数据失败:', error.message); } } saveCheckins() { try { fs.writeFileSync(this.checkinsFile, JSON.stringify(this.checkins, null, 2)); } catch (error) { console.error('保存签到记录失败:', error.message); } } ``` The records written by these methods include sensitive fields: ```js this.users[userId] = { userId, name: userData.name, phone: userData.phone, emergencyContacts: userData.emergencyContacts || [], createdAt: new Date().toISOString(), lastCheckin: null, status: '未签到', consecutiveDays: 0 }; ``` ```js const checkin = { timestamp: now.toISOString(), message: checkinData.message || '今天还活着!', mood: checkinData.mood || '😊', location: checkinData.location || '未知' }; ``` ### Technical Analysis The application serializes user and check-in objects directly into `users.json` and `checkins.json`. There is no encryption at rest, field-level encryption, explicit restrictive file mode, or access-controlled database. The stored information includes names, phone numbers, emergency contacts, timestamps, personal messages, moods, and location. This is particularly sensitive because the application's purpose permits inferences about an individual's wellbeing, routine, and periods of absence. This implementation also conflicts with the documentation's assertion that all data is encrypted. ### Attack Path 1. An attacker obtains read access to the application directory through a compromised process, exposed backup, container escape, overly broad volume mount, local account, or separate file-disclosure flaw. 2. The attacker reads `src/data/users.json`. 3. The attacker obtains names, phone ...[truncated 885 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Migrate sensitive records to an access-controlled database rather than application-directory JSON files. 2. Encrypt sensitive data at rest using a vetted authenticated-encryption scheme and keys stored outside the repository and data directory. 3. Consider field-level encryption for phone numbers, contact destinations, messages, moods, and locations. 4. Apply strict ownership and permissions to all data files and directories, such as owner-only access where supported. 5. Minimize collected data and avoid storing location unless it is strictly necessary and explicitly consented to. 6. Implement documented retention and secure-deletion policies. 7. Protect backups with equivalent encryption and access controls. 8. Do not silently continue after persistence failures; surface operational failures safely so the monitoring service does not falsely report successful storage. 9. Update the privacy documentation so its claims match the implemented controls. 10. Add automated tests that verify file permissions, encryption, retention, and redaction behavior. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
skill.json:12
Finding
Hardcoded Payment API Bearer Credential<![CDATA[ ## Vulnerability Details **File Location**: `skill.json:12` and `README.md:84` **Vulnerability Type**: Hardcoded secret committed to distributable project files **Risk Level**: High ### Evidence `skill.json` contains a concrete API key: ```json "apiKey": "sk_e390b52cb259fc4f4aa1489547a48375d72876acdee75de57101d9e0e833fcb7" ``` The same key is published in the environment configuration example in `README.md`: ```env SKILLPAY_API_KEY=sk_e390b52cb259fc4f4aa1489547a48375d72876acdee75de57101d9e0e833fcb7 ``` The payment implementation uses the configured value as a bearer credential: ```js headers: { 'Authorization': `Bearer ${this.apiKey}`, 'Content-Type': 'application/json' } ``` ### Technical Analysis A bearer credential is embedded in both metadata and documentation distributed with the package. Anyone with access to the source archive can extract it without authentication. Although the reviewed application routes do not currently call the payment methods, `src/payment.js` is capable of submitting the credential to `https://api.skillpay.me/v1`. If the exposed value is active, possession of the key may be sufficient to invoke operations permitted to its account. The absence of current route invocation does not make a published credential safe. Repository history, package caches, mirrors, and previous downloads can retain it after ordinary file deletion. ### Attack Path 1. The attacker downloads or otherwise obtains the project package. 2. The attacker opens `skill.json` or `README.md` and extracts the bearer key. 3. The attacker identifies the configured service from `src/payment.js`. 4. The attacker sends requests to the SkillPay API using `Authorization: Bearer <exposed-key>`. 5. Any operation authorized to that key can be invoked until the credential is revoked, expires, or is restricted by additional server-side controls. ### Impact Assessment The precise external privileges depend on the unknown server-side scope and validity of th ...[truncated 419 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Revoke and rotate the exposed key immediately. 2. Review provider-side access logs for unauthorized activity from the time the key was first committed. 3. Remove the credential from `skill.json`, `README.md`, repository history, release archives, package registries, and cached build artifacts where feasible. 4. Store runtime credentials only in a secret manager or protected environment variable. 5. Place only placeholders such as `SKILLPAY_API_KEY=` in documentation. 6. Scope replacement credentials to the minimum required operations, tenant, amount, network, and lifetime. 7. Add automated secret scanning to pre-commit hooks and CI pipelines. 8. Prevent application startup or payment operations when the key is absent rather than embedding fallback credentials. 9. Avoid retaining the complete key as a long-lived public object property when a narrower credential-handling design is possible. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
src/utils/alertMonitor.js:133
Finding
Emergency Alert Content Is Discarded by Mismatched Notifier Implementations<![CDATA[ ## Vulnerability Details **File Location**: `src/utils/alertMonitor.js:133-173`, with affected implementations in `src/notifiers/telegram.js`, `src/notifiers/discord.js`, and `src/notifiers/email.js` **Vulnerability Type**: Safety-critical notification integrity and availability failure **Risk Level**: High ### Evidence The alert monitor passes the emergency message through an unsupported `title` option: ```js async sendNotification(contact, message) { const results = {}; // Telegram if (contact.telegram && this.telegram) { try { results.telegram = await this.telegram.sendTrendingReport( contact.telegram, [], { title: message } ); } catch (error) { console.error('Telegram通知失败:', error.message); } } // Discord if (contact.discord && this.discord) { try { results.discord = await this.discord.sendTrendingReport([], { title: message }); } catch (error) { console.error('Discord通知失败:', error.message); } } // Email if (contact.email && this.email) { try { results.email = await this.email.sendTrendingReport( contact.email, [], { title: message } ); } catch (error) { console.error('Email通知失败:', error.message); } } console.log(`已通知 ${contact.name} (${contact.relation})`); return results; } ``` The Telegram formatter ignores `options.title` and builds an unrelated report: ```js formatMessage(repos, options = {}) { const { language = 'All', since = 'daily' } = options; const timeLabel = { daily: 'Today', weekly: 'This Week', monthly: 'This Month' }[since] || 'Today'; let message = `🔥 *GitHub Trending - ${timeLabel}*\n`; if (language && language !== 'all') { message += `📚 Language: *${language}*\n`; } message += `📅 ${new Date().toLocaleDateString('en-US', { year: 'numeric', month: 'long', day: 'numeric' })}\n\n`; if (!repos || repos.length === 0) { message += '❌ ...[truncated 2884 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Replace the unrelated notifier interface with a dedicated contract such as `sendAlert(recipient, subject, message, severity)`. 2. Implement that contract separately for Telegram, Discord, and email. 3. Ensure each implementation includes the exact generated alert content and appropriate safety-service branding. 4. Remove GitHub Trending command handlers, formatters, promotional content, and copied product descriptions. 5. Treat a contact as notified only after at least one configured channel confirms successful delivery. 6. Record per-channel success, failure reason, timestamp, and retry state without logging sensitive message contents unnecessarily. 7. Add retries with bounded exponential backoff and a dead-letter or operator-escalation mechanism. 8. Validate channel destinations during contact registration and provide periodic delivery tests. 9. Add end-to-end tests that trigger 24-hour and 48-hour conditions and assert the exact recipient, severity, and message content for every notifier. 10. Add monitoring that raises an operational alarm when no configured channel successfully delivers an emergency notification. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (53)

Known Vulnerable Dependency: axios==1.13.6 — 16 advisory(ies): CVE-2026-44494 (axios Vulnerable to Full Man-in-the-Middle via Prototype Pollution Gadget in `co); CVE-2026-44495 (axios Vulnerable to Credential Theft and Response Hijacking via Prototype Pollut); CVE-2025-62718 (Axios has a NO_PROXY Hostname Normalization Bypass that Leads to SSRF) +13 more

High
Category
Supply Chain
Confidence
97% confidence
Finding
The lockfile pins axios 1.13.6, and the static finding reports multiple known advisories including SSRF-related NO_PROXY bypass issues and prototype-pollution-based exploitation paths. In this skill context, axios is a likely network-facing dependency for health checks, so dependency compromise could directly affect outbound request safety, credential handling, or response trust.

Known Vulnerable Dependency: brace-expansion==5.0.4 — 5 advisory(ies): CVE-2026-13149 (brace-expansion: DoS via exponential-time expansion of consecutive non-expanding); CVE-2026-33750 (brace-expansion: Zero-step sequence causes process hang and memory exhaustion); CVE-2026-45149 (brace-expansion: Large numeric range defeats documented `max` DoS protection) +2 more

High
Category
Supply Chain
Confidence
80% confidence
Finding
brace-expansion 5.0.4 is a development-only transitive dependency here, primarily through tooling such as nodemon/minimatch, and the reported issues are DoS-style expansion problems. Since it is not part of the production runtime path of the skill, the practical exploitability is much lower, though still a real supply-chain weakness in development environments.

Known Vulnerable Dependency: form-data==4.0.5 — 1 advisory(ies): CVE-2026-12143 (form-data: CRLF injection in form-data via unescaped multipart field names and f)

High
Category
Supply Chain
Confidence
89% confidence
Finding
form-data 4.0.5 is flagged for CRLF injection via unescaped multipart field names or filenames. If this skill constructs multipart requests using untrusted input, an attacker may be able to inject malformed headers or manipulate downstream HTTP message structure.

Known Vulnerable Dependency: lodash==4.17.23 — 2 advisory(ies): CVE-2025-13465 (lodash vulnerable to Prototype Pollution via array path bypass in `_.unset` and ); CVE-2021-23337 (lodash vulnerable to Code Injection via `_.template` imports key names)

High
Category
Supply Chain
Confidence
91% confidence
Finding
lodash 4.17.23 is associated with prototype pollution and code-injection-related advisories. Even if the specific vulnerable APIs are not confirmed in use from the lockfile alone, this dependency can become dangerous if untrusted object paths or template input are processed anywhere in the application or transitive libraries.

Known Vulnerable Dependency: nodemailer==6.10.1 — 12 advisory(ies): CVE-2026-82661 (Nodemailer: CRLF injection in Nodemailer List-* header comments allows arbitrary); GHSA-2x7j-588g-ccc2 (Nodemailer: Quadratic (O(n²)) time complexity in addressparser allows remote den); GHSA-8m3c-c648-2xjj (Nodemailer: resolveContent() on a MailMessage bypasses disableFileAccess/disable) +9 more

High
Category
Supply Chain
Confidence
95% confidence
Finding
nodemailer 6.10.1 is flagged with multiple advisories including header injection, content resolution bypasses, and denial-of-service issues. In a monitoring skill that may send email alerts, this is particularly relevant because attacker-controlled message metadata or content could affect outbound mail generation or local/network resource access.

Known Vulnerable Dependency: path-to-regexp==0.1.12 — 1 advisory(ies): CVE-2024-45296 (path-to-regexp vulnerable to Regular Expression Denial of Service via multiple r)

High
Category
Supply Chain
Confidence
93% confidence
Finding
path-to-regexp 0.1.12 is a known ReDoS risk and is brought in via Express routing internals. If the application exposes routes influenced by attacker-controlled paths or complex matching, crafted requests could trigger excessive regex backtracking and degrade availability.

Known Vulnerable Dependency: picomatch==2.3.1 — 2 advisory(ies): CVE-2026-33672 (Picomatch: Method Injection in POSIX Character Classes causes incorrect Glob Mat); CVE-2026-33671 (Picomatch has a ReDoS vulnerability via extglob quantifiers)

High
Category
Supply Chain
Confidence
80% confidence
Finding
picomatch 2.3.1 is flagged for glob-related parsing and ReDoS issues, but in this lockfile it appears only as a dev-tooling dependency under chokidar/readdirp. That makes this a real vulnerable package but less dangerous for the deployed skill unless untrusted glob input is processed in development or CI automation.

Known Vulnerable Dependency: undici==6.21.3 — 13 advisory(ies): CVE-2026-1525 (Undici has an HTTP Request/Response Smuggling issue); CVE-2026-6733 (undici vulnerable to HTTP response queue poisoning via keep-alive socket reuse); CVE-2026-1527 (Undici has CRLF Injection in undici via `upgrade` option) +10 more

High
Category
Supply Chain
Confidence
96% confidence
Finding
undici 6.21.3 is flagged with multiple serious HTTP parsing and smuggling related advisories. This project includes network-centric libraries such as discord.js that depend on undici, so protocol-level issues could affect outbound HTTP integrity, response handling, or enable cross-request contamination in persistent connections.

Known Vulnerable Dependency: ws==8.19.0 — 2 advisory(ies): CVE-2026-45736 (ws: Uninitialized memory disclosure); CVE-2026-48779 (ws: Memory exhaustion DoS from tiny fragments and data chunks)

High
Category
Supply Chain
Confidence
94% confidence
Finding
ws 8.19.0 is flagged for memory disclosure and memory exhaustion issues. Because this project depends on discord.js and related websocket functionality, a vulnerable ws implementation can materially impact confidentiality or availability when handling crafted websocket traffic.

Known Vulnerable Dependency: axios==1.13.6 — 16 advisory(ies): CVE-2026-44494 (axios Vulnerable to Full Man-in-the-Middle via Prototype Pollution Gadget in `co); CVE-2026-44495 (axios Vulnerable to Credential Theft and Response Hijacking via Prototype Pollut); CVE-2025-62718 (Axios has a NO_PROXY Hostname Normalization Bypass that Leads to SSRF) +13 more

High
Category
Supply Chain
Confidence
96% confidence
Finding
The analysis indicates the allowed axios version range resolves to a release with multiple known advisories, including SSRF-related and prototype-pollution-assisted attack paths. In a monitoring service that likely makes outbound HTTP requests, this can materially increase the risk of server-side request forgery, credential leakage, or response manipulation.

Known Vulnerable Dependency: nodemailer==6.10.1 — 12 advisory(ies): CVE-2026-82661 (Nodemailer: CRLF injection in Nodemailer List-* header comments allows arbitrary); GHSA-2x7j-588g-ccc2 (Nodemailer: Quadratic (O(n²)) time complexity in addressparser allows remote den); GHSA-8m3c-c648-2xjj (Nodemailer: resolveContent() on a MailMessage bypasses disableFileAccess/disable) +9 more

High
Category
Supply Chain
Confidence
96% confidence
Finding
The analysis indicates the allowed nodemailer version range resolves to a release with multiple known advisories, including header injection and content resolution issues. In a service that may send emergency or notification emails, these flaws could enable message tampering, abuse of mail-sending behavior, denial of service, or exposure of sensitive mail-related data.

Missing User Warnings

Medium
Confidence
94% confidence
Finding
The documented API collects and transmits sensitive personal data, including names, phone numbers, and emergency-contact details, but the README does not mention consent, retention, access controls, or privacy obligations. In this context, users may deploy or integrate the service without realizing they are processing regulated or highly sensitive relationship and safety data.

External Transmission

Medium
Category
Data Exfiltration
Content
### 注册用户

```bash
curl -X POST http://localhost:3000/register \
  -H "Content-Type: application/json" \
  -d '{
    "userId": "user123",
Confidence
92% confidence
Finding
The example shows transmission of sensitive personal and emergency-contact data over plain HTTP, which is unsafe outside a strictly local development context. If copied into real deployments or proxied insecurely, this exposes names, phone numbers, and safety-monitoring data to interception or tampering.

Missing User Warnings

Medium
Confidence
91% confidence
Finding
The automatic escalation workflow can notify contacts, label a user high-risk, and encourage in-person follow-up, but the README does not warn about false positives, missed check-ins, device failure, or abuse scenarios. For a safety-monitoring service, omitting these limitations can lead to harmful overreaction, privacy intrusion, or unnecessary emergency escalation.

Intent-Code Divergence

Medium
Confidence
89% confidence
Finding
The README makes a concrete security claim that all data is encrypted at rest, but the document provides no implementation details, key-management guidance, or evidence that storage encryption actually exists. For a service handling sensitive health-status and emergency-contact data, an unsupported encryption claim can mislead users into trusting the system with highly sensitive information under false assumptions.

Missing User Warnings

Medium
Confidence
94% confidence
Finding
The skill explicitly collects highly sensitive personal data, including names, phone numbers, emergency contacts, check-in history, inferred wellness status, and possibly location, but provides no privacy notice, consent flow, retention policy, access control expectations, or disclosure guidance. In this context, the data concerns vulnerable individuals and third parties, so misuse or exposure could enable stalking, social engineering, harassment, and disclosure of health- or safety-related status.

Natural-Language Policy Violations

Medium
Confidence
95% confidence
Finding
Line L15 explicitly advertises a Chinese interface, which is a natural-language locale constraint. The file does not mention any opt-in, alternative language support, or a justified region-specific requirement, so this may violate language/locale policy expectations.

Natural-Language Policy Violations

Medium
Confidence
86% confidence
Finding
The display name, description, category, and tags are all written in Chinese, with no indication that the skill is region-specific or that users can choose another language. This can violate language or locale policy when a skill implicitly enforces a specific language without opt-in or documented justification.

Vague Triggers

Medium
Confidence
90% confidence
Finding
The skill describes a safety-critical monitoring and emergency notification service, but the manifest provides no trigger scope, consent model, identity checks, or invocation constraints for actions involving check-ins, status access, and emergency contacts. In this context, ambiguity is dangerous because unauthorized use, silent enrollment, or unrestricted status queries could expose sensitive wellbeing data or trigger false emergency workflows affecting vulnerable users.

Context-Inappropriate Capability

Medium
Confidence
87% confidence
Finding
The class/doc comment and exposed routes indicate a user check-in and status monitoring service ('还活着么监测服务') handling registration, check-ins, status, history, and emergency contacts. Initializing a SkillPay payment module is a separate monetization capability that is not explained or justified by the stated monitoring purpose in this file.

Missing User Warnings

Medium
Confidence
88% confidence
Finding
This code reads multiple sensitive credentials from environment variables, including payment, Telegram, Discord, and email secrets. While the file contains internal startup logs, it does not include any user-facing warning, confirmation, or explanatory comment/docstring that the service depends on and accesses these secrets.

Missing User Warnings

Medium
Confidence
89% confidence
Finding
The registration and check-in endpoints accept sensitive personal data such as name, phone number, emergency contacts, mood, and location, yet this file shows no authentication, authorization, consent handling, or transport-security enforcement. In this context, the service is specifically designed to collect welfare-monitoring data, so exposing these endpoints without visible access controls makes privacy abuse and unauthorized data access significantly more dangerous.

Missing User Warnings

Medium
Confidence
88% confidence
Finding
This code posts generated report content to a Discord webhook, which is a network transmission of repository metadata to an external service. Although failures are logged, there is no confirmation prompt or explicit user-facing warning near the operation itself explaining that data will be sent to Discord.

Intent-Code Divergence

Medium
Confidence
95% confidence
Finding
The command handlers tell users they are "Subscribed" and "Unsubscribed from daily updates," but the code only sends reply messages and does not persist any subscription state or schedule notifications. This is an active contradiction between the user-facing intent expressed in the command implementation/documentation context and the actual behavior.

External Transmission

Medium
Category
Data Exfiltration
Content
class SkillPayment {
  constructor(apiKey) {
    this.apiKey = apiKey;
    this.baseURL = 'https://api.skillpay.me/v1';
    this.pricePerCall = 0.001; // USDT
  }
Confidence
60% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Static analysis

No suspicious patterns detected.