Back to skill

Security audit

Child Drowsiness / Fatigue Detection | 儿童打瞌睡/疲劳检测

Security checks for vulnerabilities and agentic risk

Overview

ClawScan marks this skill suspicious because scanners report broad account, network, and file capabilities alongside concerns about handling children’s video and unclear alignment with its stated fatigue-analysis purpose.

The verdict is suspicious, and the scanner recommends not installing. Before considering it, verify the missing or delegated analysis behavior and understand whether video is sent to a remote service, how reports and account data are retained, and whether analysis only runs after clear authorization. Coverage was marked partial because a referenced local path was missing, so the evidence does not establish that all behavior was reviewed.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Output HandlingUnvalidated Output Injection, Cross-Context Output, Unbounded Output
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
Findings (27)

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The supplied chunk contains no camera capture, facial analysis, eye-closure measurement, head-nod detection, glossiness analysis, or fatigue-score calculation. Generic helpers could support such a system, but the automatic remote account provisioning, persistent identity management, and authenticated service-access workflow are substantial behaviors not represented in the description. These operations generally occur when the relevant methods are called, rather than unconditionally at import. This assessment is limited to the supplied chunk and does not establish what other skill files implement.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The visible implementation does not substantiate the declared fatigue-monitoring purpose and instead provides generic skill scaffolding and a nonfunctional chat wrapper. No external agent command actually executes in this chunk. Imported base and API-service implementations are not supplied, so any functionality or side effects they might provide cannot be determined from this evidence.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The supplied code's primary function is user-account database management, not fatigue detection. Persistence could support a larger application, but this chunk specifically manages identity data and tokens without any demonstrated connection to fatigue measurements. Those capabilities are not represented by the declared description. This assessment is limited to the supplied chunk; it does not establish what other skill files implement.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The supplied code implements a general API-access layer rather than the declared video-analysis functionality. Network helpers could support a larger fatigue-monitoring system, but this chunk provides no such connection, and its user-lookup and download-link capabilities are not described. These methods define capabilities; the chunk does not show them being invoked or establish malicious activity. The assessment is limited to the supplied code.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

The visible implementation is an asynchronous video-analysis API client with report retrieval and history features, rather than a real-time fatigue-monitoring implementation. File validation, uploading, and polling can be supporting implementation details, but the batch-input workflow materially differs from the declared live-camera behavior, and report-history retrieval is an additional undeclared capability. The imported API service might perform fatigue analysis remotely, but its implementation is not supplied, so the claimed measurements and scoring cannot be verified from this chunk.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
88% confidence
Finding

The code explicitly exposes account-linked analysis-history retrieval, a capability beyond the declared fatigue-monitoring function. Its visible analysis workflow takes an existing video path or URL, rather than capturing a live camera stream. The actual analysis is delegated to skill.get_output_analysis, whose implementation is not supplied, so the presence or absence of the claimed fatigue measurements and scoring cannot be verified from this chunk. API delegation and optional output-file writing are supporting implementation details, not independent grounds for the mismatch.

Content

No source excerpt is available for this finding.

YARA rule 'agent_skill_mcp_tool_poisoning_metadata': MCP/tool metadata poisoning indicators in tool schemas or skill manifests [agent_skills]

High
Category
YARA Match
Confidence
80% confidence
Finding

YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).

Content

Scanner excerpt · SKILL.md (reported line 3)May include surrounding context.

md
---
name: "smyx-child-drowsiness-fatigue-detection-analysis"
description: "Using a fixed camera in the classroom or above the home desk, the system analyzes the child's (student's) facial video in real time, detecting eye closure ratio (PERCLOS — the proportion of time eyes are closed more than 80% within a unit time), head-nodding frequency (rapid downward nod followed by lift), and changes in eye-region glossiness, and computes a comprehensive fatigue index (0-100). | 通过教室或家庭书桌的固定摄像头,实时分析儿童(学生)的面部视频,检测眼部闭合比例(PERCLOS,单位时间内眼睛闭合超过80%的时间占比

Skill declares no tool scope ('permissions' or 'allowed-tools') but code capabilities were detected: env, file_read, file_write, network, shell.

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

The default trigger selects fatigue detection for any requested analysis of a child's study-area facial video, without requiring fatigue-related intent.

Medium
Category
Trigger Abuse
Confidence
92% confidence
Finding

The default trigger authorizes fatigue analysis based on the presence of a child's facial study video, without requiring that the user request that inference. Because the workflow uses cloud processing and persistent reports, this can expand a general video-analysis request into unintended processing and retention of sensitive information about minors; the general guardian-consent note does not enforce task-specific authorization.

Content

No source excerpt is available for this finding.

The --export-env-only option promises not to run analysis, but the program ignores it and proceeds with video analysis.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The program parses --export-env-only but never checks it, so supplying it with an input still invokes the analysis workflow. A caller relying on the explicit promise of no analysis can unintentionally submit sensitive children's video for remote processing, and identity initialization also occurs before any such safeguard.

Content

No source excerpt is available for this finding.

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · skills/smyx_analysis/scripts/skill.py (reported line 28)May include surrounding context.

python
result_json = JsonUtil.parse(result_json_pure_text, result_json_pure_text)

        result_json_common_ai_response = result_json.get("commonAiResponse") if isinstance(result_json,
                                                                                           dict) else result_json
        if result_json_common_ai_response:
            result_json = result_json_common_ai_response

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · skills/smyx_analysis/scripts/skill.py (reported line 33)May include surrounding context.

python
result_json = result_json_common_ai_response

        result_json_health_ai_response = result_json.get("healthAiResponse") if isinstance(result_json,
                                                                                           dict) else result_json
        if result_json_health_ai_response:
            result_json = result_json_health_ai_response

Local input files are passed to the analysis API without disclosure that their contents will be uploaded.

Medium
Category
Output Handling
Confidence
94% confidence
Finding

The local-file branch reads the complete file and passes its bytes to the remote analysis operation without an upload-specific consent check. For children's facial footage, accepting a local path without clearly disclosing the transfer and obtaining appropriate authorization creates a significant privacy risk; naming an API elsewhere is not equivalent to informed upload consent.

Content

No source excerpt is available for this finding.

The documented environment-export-only option does not prevent video analysis.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The environment-export-only flag is accepted but never consulted before identity resolution and video analysis. When an input is supplied, a supposedly non-analysis invocation still processes the video, potentially causing unintended remote disclosure of sensitive footage.

Content

No source excerpt is available for this finding.

The service exposes general-purpose remote modification and deletion capabilities unrelated to fatigue detection.

Medium
Category
Excessive Agency
Confidence
88% confidence
Finding

L77-L95 implement HTTP PUT and DELETE operations against caller-supplied URLs, forwarding arbitrary arguments without restricting them to a fatigue-analysis service. Modifying or deleting arbitrary remote resources is not an obvious requirement of the manifest's stated purpose of analyzing facial video and computing fatigue indicators. These are exposed capabilities; this file does not establish that they are invoked during analysis.

Content

No source excerpt is available for this finding.

The skill includes shared user-account and authentication-token management unrelated to real-time fatigue detection.

Medium
Category
Excessive Agency
Confidence
88% confidence
Finding

The User model stores account identifiers, personal information, and authentication tokens (L452–L461), while UserDao exposes inherited read, update, and delete operations over those records. DAO initialization also creates tables and migrates sys_user (L180–L215); managing this account store is not an obvious requirement of the manifest's camera-based fatigue analysis.

Content

No source excerpt is available for this finding.

ai_chat documents an agent invocation but never executes it or produces analysis.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The docstring states that this method invokes openclaw agent through subprocess and returns an analysis result or session ID. However, command construction and execution are commented out; the method instead assigns an empty dictionary to result, accesses its nonexistent stderr attribute, catches the resulting exception, and implicitly returns None. The documented agent-analysis operation therefore never occurs.

Content

No source excerpt is available for this finding.

FileUtil.open silently truncates existing files without disclosing its write behavior.

Medium
Category
Output Handling
Confidence
96% confidence
Finding

Opening a path with mode 'w' immediately truncates any existing file, even before the caller writes anything. This generically named helper has no docstring, explanatory comment, confirmation, or user-facing log disclosing that destructive behavior; exception tracing does not disclose successful truncation.

Content

No source excerpt is available for this finding.

The HTTP helper silently registers or logs into a remote user account and persists returned account credentials, a capability not disclosed by the fatigue-analysis manifest.

Medium
Category
Excessive Agency
Confidence
97% confidence
Finding

An ordinary request can initiate silent remote registration or login and persist returned tokens in the local user database without an explicit enrollment step. This undisclosed identity-management side effect is especially sensitive for a child-monitoring skill, where operators may expect local analysis rather than remote account creation.

Content

No source excerpt is available for this finding.

Ordinary HTTP requests can silently trigger remote user registration without disclosure.

Medium
Category
Output Handling
Confidence
96% confidence
Finding

The helper explicitly sets silent=1 and register=1 when obtaining credentials, making account creation an implicit side effect of a normal HTTP operation. This crosses a consent boundary not disclosed in the fatigue-analysis description and duplicates the registration aspect of the broader account-management finding.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
95% confidence
Finding

This POST sends the selected identity to a remote login service as both openId and mobile without an explicit consent step. The surrounding code can select API_SECRET_KEY as that identity, potentially placing a credential into account-profile fields; no transmission of facial video is demonstrated by this call.

Content

Scanner excerpt · skills/smyx_common/scripts/util.py (reported line 561)May include surrounding context.

python
"source": ConstantEnum.DEFAULT__SKILL_HUB_NAME
            }
            try:
                _response = requests.post(_url, json=_data)
                if _response.status_code == 200:
                    _response_json = _response.json()
                    if _response_json and _response_json.get("success"):

Loading configuration silently creates directories and files, including during module import.

Low
Category
Output Handling
Confidence
93% confidence
Finding

YamlUtil.load creates the parent directory and writes a YAML file when the requested path does not exist, without a log, prompt, docstring, or explanatory comment disclosing that side effect. BaseEnum.init_subclass invokes this loader as classes are defined (L044–L058), so merely importing the module can modify the filesystem.

Content

No source excerpt is available for this finding.

Dynamic attribute access via getattr()

Low
Category
Dangerous Code Execution
Confidence
50% confidence
Finding

Dynamic getattr() with a non-literal attribute name can access arbitrary object attributes, potentially bypassing access controls.

Content

Scanner excerpt · skills/smyx_common/scripts/dao.py (reported line 243)May include surrounding context.

python
username = getattr(model, "username", None)
            if username:
                column_names = self.__model__.__table__.columns.keys()
                update_data = {key: getattr(model, key) for key in column_names if key != "username"}
                return self.update_by_username(username, **update_data)

            return None

Dynamic attribute access via getattr()

Low
Category
Dangerous Code Execution
Confidence
50% confidence
Finding

Dynamic getattr() with a non-literal attribute name can access arbitrary object attributes, potentially bypassing access controls.

Content

Scanner excerpt · skills/smyx_common/scripts/dao.py (reported line 353)May include surrounding context.

python
column_names = self.__model__.__table__.columns.keys()

            for key in column_names:
                value = getattr(model, key)
                setattr(instance, key, value)

            session.commit()

Dynamic attribute access via getattr()

Low
Category
Dangerous Code Execution
Confidence
50% confidence
Finding

Dynamic getattr() with a non-literal attribute name can access arbitrary object attributes, potentially bypassing access controls.

Content

Scanner excerpt · skills/smyx_common/scripts/dao.py (reported line 326)May include surrounding context.

python
if filters:
                for key, value in filters.items():
                    query = query.filter(getattr(self.__model__, key) == value)

            if offset:
                query = query.offset(offset)