Back to skill

Security audit

Pet Restricted Area Alert Skill | 宠物禁区预警技能

Security checks for vulnerabilities and agentic risk

Overview

ClawScan marked this skill suspicious because its reported behavior does not clearly match its pet-monitoring description and includes privacy and account-handling concerns.

Consider not installing until the publisher explains the mismatch with the pet-monitoring description, the account-registration and API-secret handling, and how video uploads and report access are disclosed and authorized. The scan was partial, so the missing referenced path leaves some evidence incomplete; the suspicious verdict is not a finding that the author acted maliciously.

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 (26)

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The visible implementation does not substantiate the declared monitoring purpose. It contains no camera or sensor processing, behavior classification, monitoring loop, or alert delivery. The commented-out subprocess code does not execute and should not be treated as an active capability. Imported base classes and API services could provide additional behavior, but their implementations are not supplied; this assessment is limited to the visible code.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
92% confidence
Finding

The supplied chunk implements user-account database infrastructure rather than pet-behavior detection or real-time alerting. Generic database operations could support a monitoring skill, but the concrete personal-profile and authentication-token functionality is not explained by the declared purpose. No pet-monitoring or alert-delivery logic appears in this chunk. This assessment is limited to the supplied file; it does not establish what other skill components implement or indicate any token exfiltration.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
91% confidence
Finding

Ordinary formatting, polling, filesystem helpers, and HTTP transport could support the declared monitoring functionality and are not independently mismatches. However, the supplied code also implements an undeclared account-provisioning and billing workflow: it resolves identity from local files or a database, calls /sys/phoneLogin with registration enabled, persists returned credentials, and handles payment failures with recharge instructions. These account and billing behaviors extend beyond the stated pet-monitoring purpose. No pet detection or alert logic appears in this chunk, although its absence from a shared utility file does not establish that the complete skill lacks those features.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
90% confidence
Finding

The supplied code implements a video-analysis reporting workflow. It does not visibly monitor a live feed, identify the three declared pet behaviors, or issue intrusion alerts. Polling for an analysis report is not itself real-time event monitoring. Imported service implementations could provide pet-specific analysis, but that is not established by this chunk. File validation and API submission are supporting implementation details, not independent grounds for the mismatch.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
87% confidence
Finding

The code accepts a video file or URL and delegates processing to skill.get_output_analysis(). It contains no visible monitoring loop, event-specific detection configuration, or alert-delivery logic. This makes the demonstrated behavior materially narrower and more generic than the declared real-time pet-monitoring purpose. The imported skill implementation is not supplied, so it could provide pet-specific analysis internally; however, that functionality and the promised real-time alerts cannot be established from this chunk. User-identifier resolution, history retrieval, and output-file writing are supporting features, not independently treated as suspicious capabilities.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
81% confidence
Finding

The generic AI-analysis endpoints could support the declared monitoring functionality and are not inherently mismatched. However, DETAIL_EXPORT_URL explicitly targets a health-service order-report export endpoint, which is outside the stated purpose. The finding is limited to this unrelated resource configuration; the supplied code does not demonstrate that reports are actually accessed or exported.

Content

No source excerpt is available for this finding.

The request helper silently provisions backend accounts and can use the API secret as the registration identity.

High
Category
Excessive Agency
Confidence
98% confidence
Finding

When tokens are missing, the helper prioritizes API_SECRET_KEY as the username and can send it to the login/registration endpoint as both openId and mobile. This exposes a credential as ordinary identity data that may be retained in account records or logs, while silently creating an account as a side effect of a pet-monitoring request.

Content

No source excerpt is available for this finding.

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.

Generic history-report phrases automatically trigger this pet-monitoring skill without requiring pet-related context.

Medium
Category
Trigger Abuse
Confidence
94% confidence
Finding

Generic requests such as querying historical reports can automatically invoke this skill's cloud history retrieval without establishing pet-monitoring intent. Because the workflow mandates remote retrieval and displays report data and links, an unrelated request can cause unintended access or disclosure of household-monitoring history.

Content

No source excerpt is available for this finding.

The analysis workflow lacks a privacy warning about sending home-monitoring media to an external API.

Medium
Category
Output Handling
Confidence
91% confidence
Finding

The workflow instructs automatic processing of household footage without a clear privacy notice or informed approval for external media transfer. Although API use is mentioned, users are not clearly told that private interior footage and incidental recordings of people will leave their environment.

Content

No source excerpt is available for this finding.

The --export-env-only option promises not to run analysis, but execution still invokes video analysis.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The export-only flag is parsed but never checked, so supplying it together with a valid input still reaches video analysis. Users relying on the explicit promise of no analysis can unintentionally initiate external processing of private household footage and potentially incur charges.

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 video contents are passed to an analysis API without disclosure of the upload.

Medium
Category
Output Handling
Confidence
90% confidence
Finding

The code reads the complete local video and supplies it as a file payload to the analysis API without a visible disclosure or consent check. In a home-monitoring context, that payload may reveal occupants, private rooms, and household routines beyond the pet behavior being analyzed.

Content

No source excerpt is available for this finding.

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

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The program accepts an export-only flag promising no analysis but never branches on its value. When an input is also supplied, execution still invokes video analysis, violating the user's explicit no-processing expectation and potentially causing unintended remote media processing.

Content

No source excerpt is available for this finding.

The skill includes management of demographic profiles and credentials unrelated to its declared pet-monitoring purpose (L448–L465).

Medium
Category
Excessive Agency
Confidence
86% confidence
Finding

The User model stores real names, email addresses, birthdays, sex, age, and authentication tokens, and UserDao exposes inherited CRUD operations over those records. Although recipient identification could support alerts, managing demographic profiles and general-purpose credentials is not justified by the stated intrusion-detection and pet-alerting scope; DAO initialization also creates and migrates the system-user schema (L180–L215).

Content

No source excerpt is available for this finding.

The ai_chat docstring claims to invoke the OpenClaw agent through subprocess (L26), but the invocation is disabled and no analysis is performed (L61–L82).

Medium
Category
Excessive Agency
Confidence
100% confidence
Finding

The documented agent invocation is entirely commented out. Instead, the method assigns an empty dictionary to result and accesses result.stderr, raising an exception that is caught, so calls return None rather than the documented analysis result or session ID. This contradicts the method's stated analysis functionality, rather than merely changing an implementation detail.

Content

No source excerpt is available for this finding.

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

Medium
Category
Output Handling
Confidence
97% confidence
Finding

At L101, opening a path in 'w' mode immediately truncates an existing file, even before the caller writes anything. The generically named helper has no docstring, comment, confirmation, or user-facing message explaining this behavior; exception tracing does not disclose successful truncation.

Content

No source excerpt is available for this finding.

HTTP requests can silently trigger remote account registration using the current identity.

Medium
Category
Output Handling
Confidence
95% confidence
Finding

The generic request helper can submit a remote login request with register=1 and silent=1 when credentials are unavailable, without an explicit registration action. This creates an undisclosed account-provisioning and identity-disclosure side effect that is not apparent from the skill's pet-monitoring purpose.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
97% confidence
Finding

This POST transmits identity fields to the configured backend, and the visible caller can populate both fields with API_SECRET_KEY. External communication is not inherently unsafe for a monitoring skill, but sending an authentication secret as registration data is an unnecessary credential disclosure; the actual destination and transport cannot be verified from this source.

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"):

Configuration loading silently creates directories and files, including during module import.

Low
Category
Output Handling
Confidence
91% confidence
Finding

YamlUtil.load creates parent directories and writes a YAML file when the requested path does not exist, without a log, confirmation, or explanatory comment/docstring. BaseEnum.init_subclass invokes this loader (L052–L058), so importing the module can modify the filesystem even though no explicit save was requested.

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)

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 441)May include surrounding context.

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

            return query.scalar()
        finally: