Back to skill

Security audit

Stranger Recognition Skill | 陌生人识别技能

Security checks for vulnerabilities and agentic risk

Overview

ClawScan rates this skill suspicious with high confidence: scanners report undisclosed account, identity, and facial-reference enrollment behavior, along with risks around remote media submission and persistent credentials.

Consider the suspicious verdict and the reported privacy and account side effects before installing. The scanners recommend not installing; review whether remote media processing, account creation, credential storage, and facial enrollment are acceptable, noting that some service behavior could not be verified.

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
  • Output HandlingUnvalidated Output Injection, Cross-Context Output, Unbounded Output
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • YARA SignaturesMalware Match, Webshell Match, Cryptominer Match
Findings (25)

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The recognition workflow aligns with the description, but the code also exposes an explicit enrollment operation through --enroll yes. It requires --person-name and forwards enroll, person_name, and person_id to skill.get_output_analysis; dedicated result formatting handles enrollment responses. Adding biometric identity records is a distinct, state-changing capability beyond comparing faces to detect strangers, and it is not disclosed in the declared purpose. The underlying service implementation is not supplied, so successful database modification cannot be independently verified from this chunk.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
90% confidence
Finding

The visible implementation does not substantiate the declared surveillance functionality and instead provides generic scaffolding and a nonfunctional agent-chat helper. It does not actually execute an external command. BaseSkill and ApiService implementations are not supplied, so any surveillance capabilities inherited from those classes cannot be verified.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
89% confidence
Finding

Ordinary formatting, filesystem, and HTTP helpers can support the declared skill, and the absence of facial-recognition logic in a shared utility file alone would not establish a mismatch. However, this chunk also implements automatic remote account provisioning, persistent identity management, and a payment dependency that the description does not disclose. Its request wrapper additionally forwards configured credentials to arbitrary caller-supplied absolute URLs; the code does not restrict those credentials to the configured service origin. These are material behaviors beyond the stated stranger-recognition purpose. The supplied chunk does not establish malicious intent or show that these paths are actually invoked.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
83% confidence
Finding

Generic AI-analysis endpoints could support the declared functionality and are not inherently mismatched. However, DETAIL_EXPORT_URL explicitly targets /health/order/api/getReportDetailExport, introducing an unrelated health-report resource. This is a configuration-level mismatch: the chunk defines that endpoint but does not itself request or export any reports. The absence of facial-recognition logic in a configuration-only chunk is not, by itself, evidence of a mismatch.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
80% confidence
Finding

The visible code delegates video analysis to skill.get_output_analysis and offers a separate history-listing operation through skill.get_output_analysis_list. It contains no explicit facial comparison, known-person reference handling, stranger classification, image-detection interface, or warning behavior. The imported service implementation is not supplied, so stranger recognition could exist behind that call; however, the exposed general analysis and account-history functionality is not accurately described by the narrow declared purpose. Network calls and optional output-file writing are supporting implementation details, not independently treated as mismatches.

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: "stranger-recognition-analysis"
description: "Identifies strangers appearing in surveillance areas through facial comparison; supports video stream and image detection, suitable for stranger warnings in residential communities, units, access control, and other scenarios. | 陌生人识别技能,通过人脸比对识别监控区域出现的陌生人员,支持视频流和图片检测,适用于小区、单位、门禁等场景的陌生人预警"
version: "1.0.24"
license: "MIT-0"
---

# 🕵️ Stranger Recognition Skill | 陌生人识别技能
> **智能分析中枢** · 图片/视频智能分析 · 结构化报告 · �

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 analysis workflow lacks a clear privacy warning about remote processing of surveillance media and facial data.

Medium
Category
Output Handling
Confidence
89% confidence
Finding

The workflow directs users to submit surveillance media without a clear, prominent warning that local files and facial information will be processed remotely. Although cloud APIs and storage are mentioned elsewhere, they do not adequately explain the sensitive-data transfer, retention, or recipient, creating a risk of uninformed disclosure of biometric and bystander data.

Content

No source excerpt is available for this finding.

The --export-env-only option promises not to execute analysis, but the code ignores it and still submits media for recognition.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The CLI accepts --export-env-only and explicitly promises not to perform analysis, but never checks the flag before identity initialization or media submission. With valid media arguments, a supposedly non-executing invocation can disclose sensitive surveillance media and can also request facial enrollment.

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 submitted to the analysis service without disclosure of the upload.

Medium
Category
Output Handling
Confidence
90% confidence
Finding

The helper reads the complete local media file and passes its contents to the remote analysis operation without a disclosure or authorization gate in this path. Remote analysis is legitimate functionality, but surveillance footage can contain sensitive faces, locations, and bystanders whose data should not be transferred without informed authorization.

Content

No source excerpt is available for this finding.

The --export-env-only option promises not to execute analysis, but supplying it does not prevent video analysis.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The parser advertises --export-env-only as preventing analysis, but execution never branches on that argument. When supplied with valid input, the command still initializes identity and submits video, defeating a user's explicit expectation that no analysis or sensitive-data transfer will occur.

Content

No source excerpt is available for this finding.

The save() method is documented as creating a new record, but can silently overwrite an existing user.

Medium
Category
Excessive Agency
Confidence
96% confidence
Finding

Any add failure triggers an update by ID, followed by a username-or-realname fallback that copies nearly every column, including identifiers and authentication tokens. If an untrusted or conflicting model reaches save(), an operation described as creation can overwrite another user's identity or credentials; the fallback is particularly unsafe because realname is treated as an identity selector.

Content

No source excerpt is available for this finding.

FileUtil.open silently opens files in write mode, truncating existing content.

Medium
Category
Output Handling
Confidence
96% confidence
Finding

The generically named open helper always uses mode 'w', which immediately truncates an existing file. No docstring, comment, confirmation, or action log discloses this destructive behavior; the exception handler only handles failures.

Content

No source excerpt is available for this finding.

Recognition requests can silently provision a remote platform account and persist its credentials, beyond the described detection functionality.

Medium
Category
Excessive Agency
Confidence
92% confidence
Finding

The request helper can invoke phoneLogin with silent=1 and register=1, creating a remote account without a separate enrollment decision in this code path. Remote authentication may support recognition, but automatic registration and credential retention are additional privacy-relevant side effects not disclosed by the supplied detection-focused description.

Content

No source excerpt is available for this finding.

HTTP requests can silently register a remote account and persist returned authentication tokens locally.

Medium
Category
Output Handling
Confidence
93% confidence
Finding

A normal HTTP operation can implicitly register an account and save returned token and openToken values through UserDao, introducing durable authentication state without a separate persistence decision. In a surveillance-related skill, this undisclosed identity linkage is privacy-relevant, and local credential storage also creates an additional exposure surface.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
90% confidence
Finding

This POST transmits the selected identity to a remote login/registration service as both openId and mobile, and the caller can select API_SECRET_KEY as that identity. Consequently, a configured secret can be copied into identity fields that may be retained or logged as account data; ordinary recognition networking does not justify treating a credential as a public identifier.

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
94% confidence
Finding

YamlUtil.load creates parent directories and writes a YAML file when the requested path does not exist, without a comment, docstring, log, or confirmation disclosing this side effect. Because BaseEnum.init_subclass invokes this loader when the configuration classes are defined (L052–L058), merely importing the module can modify the filesystem, which is unexpected for a configuration read operation.

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:

ai_chat documents an agent invocation, but its implementation never invokes an agent or produces an analysis result.

Low
Category
Excessive Agency
Confidence
99% confidence
Finding

The docstring at L26 explicitly claims that this method invokes openclaw agent through subprocess, but the command and subprocess invocation are commented out at L48–L66. Instead, L68 initializes a dictionary, and accessing result.stderr at L70 raises an exception that is caught and suppressed, causing the method to return None rather than the documented analysis result or session ID.

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/util.py (reported line 30)May include surrounding context.

python
elif isinstance(cur, dict):
                        cur = cur.get(part, default)
                    else:
                        cur = getattr(cur, part)
                return cur
            except Exception:
                return default