Back to skill

Security audit

huawei-cloud-obs-list-excel

Security checks for vulnerabilities and agentic risk

Overview

The skill performs the advertised reporting task, but its installation steps weaken download security and need review before use.

Before use, replace the dependency helper with installation in a dedicated virtual environment using certificate verification and reviewed versions. Obtain KooCLI through Huawei's verified distribution instructions. Use credentials restricted to bucket listing, keep secrets out of chat, and avoid relying on endpoint overrides or result limits during SDK fallback until those defects are fixed.

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

T08 · Insecure Dependencies

Error
Location
scripts/ensure_env.py
Finding

Dependency installation disables TLS authentication for package mirrors

Content
View full analysis

Impact

Arbitrary code execution with the installing user's privileges, including access to files and credentials available to that process.

Vulnerability Patterns
  • Output HandlingUnvalidated Output Injection, Cross-Context Output, Unbounded Output
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (11)

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
88% confidence
Finding

Although CLI setup can support the declared task, this chunk introduces remote script execution with effects that cannot be established from the supplied code. That is materially broader than read-only OBS access and local report generation, and the description does not disclose this installation behavior or the external script source. The chunk does not establish that the downloaded script is malicious or that it modifies OBS.

Content

No source excerpt is available for this finding.

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

The installation instructions execute a downloaded, mutable installer with bash without verifying its signature or a trusted, pinned checksum. If the distribution endpoint or installer is compromised, following these instructions could execute arbitrary code with the user's privileges, potentially accessing cloud credentials and local files. Installing KooCLI is relevant to the skill, so this is an unsafe installation practice rather than evidence of malicious tool-parameter manipulation; the skill's read-only OBS restrictions do not constrain the installer.

Content

Scanner excerpt · references/cli-installation-guide.md (reported line 30)May include surrounding context.

bash
# Linux/macOS quick start
curl -sSL https://cn-north-4-res.hcccloud.com/cli/latest/install.sh -o install.sh
bash install.sh
hcloud version

Skill declares no tool scope ('permissions' or 'allowed-tools') but code capabilities were detected: env, file_write, 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.

Requires Chinese-language workbook labels and error messages without user opt-in.

Medium
Category
Output Handling
Confidence
98% confidence
Finding

The verification criteria fix workbook titles and headers to Chinese and require error paths to emit a Chinese hint on stderr. No user language choice or documented justification for this language constraint is provided.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
96% confidence
Finding

The subprocess call does not introduce shell injection: it uses an argument list with no shell, and its callers construct controlled pip commands. However, those commands install executable dependencies from mirrors using --trusted-host, which disables HTTPS certificate verification for those hosts; a network attacker able to intercept that traffic could substitute malicious packages and execute code during installation or the subsequent import. This installation path runs when dependencies are missing or --upgrade is requested, and the skill's read-only OBS guard does not constrain malicious dependency code.

Content

Scanner excerpt · scripts/ensure_env.py (reported line 77)May include surrounding context.

python
def run_cmd(cmd, timeout=300):
    try:
        proc = subprocess.run(
            cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE,
            timeout=timeout, universal_newlines=True,
        )

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/list_obs_buckets_excel.py (reported line 250)May include surrounding context.

python
guard_write_intent(" ".join(extra))
        cmd.extend(extra)
    try:
        proc = subprocess.run(
            cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE,
            timeout=120, universal_newlines=True,
        )

Tainted flow: 'cmd' from os.environ.get (line 240, credential/environment) → subprocess.run (code execution)

Medium
Category
Data Flow
Confidence
65% confidence
Finding

Data from a source is assigned to a variable that is later passed to a sink, creating a variable-mediated taint flow.

Content

Scanner excerpt · scripts/list_obs_buckets_excel.py (reported line 250)May include surrounding context.

python
guard_write_intent(" ".join(extra))
        cmd.extend(extra)
    try:
        proc = subprocess.run(
            cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE,
            timeout=120, universal_newlines=True,
        )

The workbook format mandates Chinese-language headers without offering a language choice.

Low
Category
Output Handling
Confidence
88% confidence
Finding

The skill requires a fixed header row using Chinese labels, regardless of the user's preferred language. It provides neither a language-selection option nor a documented locale-specific justification for this output constraint.

Content

No source excerpt is available for this finding.

The spreadsheet format requires Chinese column headers without offering a language choice.

Low
Category
Output Handling
Confidence
90% confidence
Finding

The acceptance criterion mandates fixed Chinese headers for generated spreadsheets. It provides neither user opt-in nor a documented justification for requiring Chinese output regardless of the user's language.

Content

No source excerpt is available for this finding.

SDK fallback does not enforce the declared --page-size result cap.

Low
Category
Excessive Agency
Confidence
100% confidence
Finding

The manifest states that --page-size caps the returned bucket count. Although the fallback accepts page_size at L366, it never uses that value: it makes an unparameterized list_buckets request and returns every normalized bucket, allowing reports and stdout output to contain more records than requested.

Content

No source excerpt is available for this finding.

SDK fallback silently ignores the explicitly selected endpoint.

Low
Category
Excessive Agency
Confidence
100% confidence
Finding

The manifest promises that --endpoint overrides the region-derived OBS endpoint. When hcloud is unavailable, the fallback passes only the region and limit to the SDK function, which selects its endpoint through ObsRegion (L397–L408), so requests do not honor the caller's explicit endpoint selection.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.