Back to skill

Security audit

umeng-app-analysis

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly provides a disclosed Umeng analytics CLI, but it also ships and imports broader authenticated SDK wrappers for undeclared account-changing and non-App analytics operations.

Install only if you are comfortable granting the skill access to Umeng analytics credentials and with the package containing broader Umeng SDK capabilities than the documented commands. Prefer running it in an isolated environment with least-privilege Umeng credentials, pinned dependencies, and explicit review before any account-changing API use such as creating apps or events.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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 (2)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:16
Finding

Unpinned Third-Party Dependency Installation

Content
View full analysis

Vulnerability Details

File Location: SKILL.md:16
Vulnerability Type: Unpinned dependency and supply-chain exposure
Risk Level: Medium

Vulnerable Code

bash
pip install requests

Technical Analysis

The installation instructions retrieve requests without a fixed version or integrity hash. Package resolution therefore depends on the state of the configured Python package index at installation time. The bundled SDK subsequently imports and executes this environment-provided package.

Although no malicious dependency is embedded in the reviewed project, this installation pattern does not provide reproducible or integrity-verified dependency resolution. A compromised upstream release, package-index compromise, unsafe index configuration, or incompatible future release could alter the code executed by the Skill after the project itself has been audited.

Attack Path

  1. A user follows the documented pip install requests instruction.
  2. pip queries the user's configured package indexes and resolves an uncontrolled version of requests and its transitive dependencies.
  3. A compromised package release, maliciously configured index, or dependency-resolution attack supplies attacker-controlled package content.
  4. Package installation or a later import executes the supplied code.
  5. Because the Skill runs with Umeng credentials in its environment, malicious dependency code could access those credentials and any files or network resources available to the Skill process.

Impact Assessment

Successful exploitation would provide code execution with the privileges of the user running the installation or Skill. The potential scope includes access to UMENG_API_KEY, UMENG_API_SECURITY, command-line access tokens, readable local files, and network resources available to that process.

The finding does not demonstrate that the current requests package is malicious; it identifies an avoidable ...[truncated 55 chars]

Remediation
View remediation

Remediation Suggestions

  1. Replace the free-form installation command with a reviewed, version-pinned dependency manifest.
  2. Pin both direct and transitive dependencies to known-good versions.
  3. Record cryptographic hashes and install with hash verification, for example:
    bash
    python3 -m pip install --require-hashes -r requirements.txt
    
  4. Generate and review the lock file using a reproducible dependency-management process.
  5. Install dependencies in an isolated virtual environment rather than the system Python environment.
  6. Configure pip to use only trusted package indexes and avoid untrusted extra indexes.
  7. Periodically scan pinned dependencies for published vulnerabilities and update them through a controlled review process.

T09 · Insecure Skill Coding Practices

Warning
Location
sdk/aop/api/base.py:308
Finding

Outbound API Requests Lack Explicit Timeouts

Content
View full analysis

Vulnerability Details

File Location: scripts/umeng.py:47-49; sdk/aop/api/base.py:308-314
Vulnerability Type: Unbounded network wait and denial of service
Risk Level: Medium

Vulnerable Code

The CLI invokes the SDK without supplying a timeout:

python
def call_api(req):
    """Execute an API call and output the result."""
    try:
        resp = req.get_response()

The transport passes the default timeout=None through to requests.post:

python
def _do_request(self, url, data=None, files=None, **kwargs):
    try:
        if files:
            return requests.post(url, data=data, files=files, **kwargs)
        else:
            return requests.post(url, data=data, **kwargs)
    except requests.RequestException as e:
            self.raise_aop_error(str(e))

Technical Analysis

BaseApi.get_response() defines its timeout parameter as None, and call_api() invokes it without overriding that value. The resulting requests.post() operation has no application-level connection or read deadline.

A remote endpoint, network intermediary, or degraded connection can accept the connection and then stop making progress. The Skill process may consequently remain blocked indefinitely. The exception handler does not mitigate this condition because no timeout exception is generated unless a timeout is configured.

The endpoint is fixed to gateway.open.umeng.com and HTTPS certificate verification is not disabled, which limits arbitrary endpoint substitution in the reviewed CLI. Nevertheless, upstream failure, network interference, or a compromised endpoint can still trigger the availability issue.

Attack Path

  1. The Agent invokes any command that calls the Umeng API.
  2. The process opens an HTTPS request to the configured endpoint.
  3. The upstream server or a network intermediary accepts the connection but delays or withholds the response.
  4. Because no connect o ...[truncated 580 chars]
Remediation
View remediation

Remediation Suggestions

  1. Configure explicit connect and read timeouts for every outbound request, for example:
    python
    DEFAULT_TIMEOUT = (5, 30)
    
    def _do_request(self, url, data=None, files=None, **kwargs):
        kwargs.setdefault("timeout", DEFAULT_TIMEOUT)
        try:
            if files:
                return requests.post(url, data=data, files=files, **kwargs)
            return requests.post(url, data=data, **kwargs)
        except requests.Timeout as e:
            self.raise_aop_error("API request timed out: " + str(e))
        except requests.RequestException as e:
            self.raise_aop_error(str(e))
    
  2. Permit callers to select stricter timeouts while enforcing a safe finite default.
  3. If retries are required, use a small bounded retry count with exponential backoff and jitter.
  4. Do not automatically retry state-changing operations such as create-event unless the API provides idempotency guarantees.
  5. Add tests that simulate connection delays and stalled response bodies to verify that the process exits within the configured deadline.
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (60)

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The implementation reportedly returns mini-program share overview data rather than the broad app-analytics functionality described. Mislabeling a narrowly scoped or different-product API as a comprehensive analytics tool makes it easier for unintended data flows and hidden capabilities to bypass review.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

This request class exposes an API for order-analysis data tied to plan/unit IDs, which is outside the declared scope of a skill meant for Umeng App analytics. That mismatch can enable unauthorized access to different business data domains than users or operators expect, increasing the risk of over-privileged data retrieval and accidental sensitive-data exposure.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

This file adds a signed, authenticated API wrapper for creating a new Umeng app/data source, which is a state-changing administrative capability. That is materially broader than the skill’s declared read/query-focused analytics purpose, so if the agent can invoke this request it could perform unauthorized provisioning in the user’s Umeng account rather than only retrieving statistics.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The exposed endpoint URI implements provisioning of a new Umeng app/data source, which is not justified by the stated use case of querying and analyzing app statistics. In an agent setting, unnecessary write/admin operations expand attack surface and enable misuse such as resource sprawl, unauthorized account changes, or preparing additional assets for later abuse.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.