Back to skill

Security audit

alibabacloud-alinux-sysom-inspection

Security checks for vulnerabilities and agentic risk

Overview

The skill has a coherent Alibaba Cloud SysOM inspection purpose, but its setup and runtime authority are broad enough that users should review it before installing.

Install only if you trust the publisher and are comfortable granting Alibaba Cloud SysOM permissions, possible service activation, agent installation, fleet inspection, and local report storage. Avoid running the documented curl | sudo bash command unless you can independently verify the installer contents and integrity; prefer a reviewed, pinned, least-privilege installation path.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T03 · Remote Payload Retrieval and Execution

Error
Location
SKILL.md:39
Finding

Mutable Remote Installation Script Is Executed Directly as Root

Content
View full analysis
Remediation
View remediation
install.sh" | sha256sum --check - # Verify a detached signature as well where available. less install.sh bash install.sh ``` The installer should not be run with `sudo` unless its reviewed operations explicitly require it. ]]>

T08 · Insecure Dependencies

Error
Location
scripts/sysom_cli/__main__.py:12
Finding

CLI Automatically Installs Unpinned Dependencies at Runtime

Content
View full analysis
pip package name _DEPS = { "requests": "requests", "alibabacloud_tea_openapi": "alibabacloud-tea-openapi", "alibabacloud_tea_util": "alibabacloud-tea-util", } def _ensure_deps() -> None: missing = { pip_name for mod_name, pip_name in _DEPS.items() if importlib.util.find_spec(mod_name) is None } if not missing: return print( f"[Setup] Installing missing dependencies: {', '.join(sorted(missing))}", file=sys.stderr) try: subprocess.check_call( [sys.executable, "-m", "pip", "install", "--quiet", *sorted(missing)], ) ``` The function is invoked during module loading: ```python _ensure_deps() ``` The ordinary initialization path in `scripts/init.sh` also resolves dependencies from the network: ```bash python3 -m venv "$SCRIPT_DIR/.venv" "$SCRIPT_DIR/.venv/bin/python" -m pip install --upgrade pip "$SCRIPT_DIR/.venv/bin/pip" install -r "$SCRIPT_DIR/requirements.txt" ``` The dependency declarations are ranges rather than a reproducible lock with hashes: ```text requests>=2.31.0 alibabacloud-tea-openapi>=0.4.4,<1.0.0 alibabacloud-tea-util>=0.3.14,<1.0.0 ``` Build dependencies in `scripts/pyproject.toml` are also not exactly pinned: ```toml [build-system] requires = ["setuptools>=45", "wheel"] build-backend = "setuptools.build_meta" [project] name = "sysom-inspection" version = "0.1.0" description = "SysOM inspection CLI" requires-python = ">=3.8" dependencies = [ "requests>=2.31.0", "alibabacloud-tea-o ...[truncated 2811 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
Findings (28)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared description promises operational diagnostics for ECS instances, including health inspection, anomaly detection, and automated deep memory diagnosis. However, the provided code chunk does not inspect system state or perform any diagnosis at all. It only initializes a local Python virtual environment and installs dependencies. While setup scripts can be a supporting detail, this chunk by itself does not exhibit the declared functionality and instead has a materially different immediate purpose: environment initialization. Therefore, the description does not accurately represent what the supplied code chunk actually does.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared description promises substantial system inspection and diagnostic behavior, but the provided code chunk does not implement any of it. The file only contains an encoding header and no executable logic. This is a clear description-to-code mismatch because the actual code has no observable functionality related to ECS instance health, anomaly detection, or diagnosis.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared description promises substantial inspection and diagnostic functionality, but the provided code chunk does not implement any of it. Since the code is effectively empty, the actual behavior does not match the stated primary purpose. There are no undeclared capabilities present; rather, the issue is that the claimed capabilities are unsupported by the supplied code.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Yes, this is a mismatch. The declared description promises substantial operational behavior for ECS health inspection and automated diagnosis, but the provided code chunk contains only an empty init.py file. There is no evidence of system metric collection, anomaly detection, deep diagnosis, trigger processing, or any other functionality matching the description. This is not merely a partial implementation detail; the supplied code does not implement the declared primary purpose at all.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The code chunk does not perform instance health inspection, anomaly detection, memory/disk/CPU/load analysis, leak detection, or deep diagnosis triggering. Its sole purpose is credential acquisition and role assumption for Alibaba Cloud access. While authentication can be a supporting component of a broader diagnostic tool, this chunk itself implements materially different capabilities involving credential access and cloud authentication resources that are not reflected in the declared description. Therefore this description does not accurately represent what this specific code chunk actually does.

Content

No source excerpt is available for this finding.

External Script Fetching

High
Category
Supply Chain
Confidence
98% confidence
Finding

Fetching a remote script with curl and piping it directly to bash removes any opportunity for integrity verification, code review, or safe staging before execution. Because the script runs as root in this same command, compromise of the hosting bucket, DNS/TLS trust, or the distribution path could yield immediate full-system compromise.

Content

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

If it is missing, install it:

bash
curl -fsSL --connect-timeout 1000 https://sysom-prd-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/sysom_prd/skill_cli/install.sh | sudo bash

Then verify only the binary:

Chaining Abuse

High
Category
Tool Misuse
Confidence
97% confidence
Finding

The direct pipeline from network fetch to sudo bash is a classic unsafe command chain that combines untrusted input and immediate privileged execution. This chaining magnifies risk by preventing validation checkpoints and turning any upstream compromise into root-level arbitrary code execution.

Content

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

If it is missing, install it:

bash
curl -fsSL --connect-timeout 1000 https://sysom-prd-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/sysom_prd/skill_cli/install.sh | sudo bash

Then verify only the binary:

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill goes beyond read-only inspection and can activate SysOM and install an agent on the target instance. Those are state-changing operations with security and operational consequences, and the code performs them after only a generic prompt, which can lead to unintended software deployment and privilege use in environments expecting diagnostics only.

Content

No source excerpt is available for this finding.

Cloud Metadata Access

High
Category
Server-Side Request Forgery
Confidence
85% confidence
Finding

Code accesses a cloud instance metadata endpoint (e.g. 169.254.169.254). A single request can return temporary IAM credentials, making this a high-value SSRF target for credential theft.

Content

Scanner excerpt · scripts/sysom_cli/lib/auth.py (reported line 57)May include surrounding context.

python
def _fetch_ram_role_credentials(role_name: str) -> Optional[Dict[str, str]]:
    url = f"http://100.100.100.200/latest/meta-data/ram/security-credentials/{role_name}"
    try:
        response = requests.get(url, timeout=3)
        if response.status_code != 200:

Cloud Metadata Access

High
Category
Server-Side Request Forgery
Confidence
85% confidence
Finding

Code accesses a cloud instance metadata endpoint (e.g. 169.254.169.254). A single request can return temporary IAM credentials, making this a high-value SSRF target for credential theft.

Content

Scanner excerpt · scripts/sysom_cli/lib/auth.py (reported line 73)May include surrounding context.

python
def _fetch_ram_role_credentials(role_name: str) -> Optional[Dict[str, str]]:
    url = f"http://100.100.100.200/latest/meta-data/ram/security-credentials/{role_name}"
    try:
        response = requests.get(url, timeout=3)
        if response.status_code != 200:

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
84% confidence
Finding

The skill clearly instructs use of shell, network access, environment variables, and likely file access, but it does not declare any explicit tool scope such as allowed-tools or permissions. This weakens least-privilege controls and makes it harder for a host agent or reviewer to constrain dangerous capabilities before execution.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Broad trigger keywords like 'inspection', 'instance diagnosis', and 'memory usage' can cause the skill to activate for generic admin requests outside the user's specific intent. In this skill, unintended activation is more dangerous because execution may lead to broad ECS inspection, diagnosis workflows, and possible installation of a privileged CLI.

Content

No source excerpt is available for this finding.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
93% confidence
Finding

The skill instructs users to run an installation pipeline under sudo, which executes fetched code with root privileges. In context, this is especially dangerous because the command is positioned as a routine setup step for an operational skill, increasing the chance that users run it without review.

Content

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

If it is missing, install it:

bash
curl -fsSL --connect-timeout 1000 https://sysom-prd-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/sysom_prd/skill_cli/install.sh | sudo bash

Then verify only the binary:

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The skill advertises batch and region-wide inspection with auto-diagnosis and report generation, but it does not require an explicit warning or user confirmation about scanning up to 5000 instances and collecting metrics/log-derived findings. This creates a meaningful risk of overbroad access, unintended data exposure, and surprising operational impact if triggered accidentally or by an under-informed user.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

This text specifies a fixed output language (Chinese) for LLM-generated reports, which is a natural-language locale constraint. Because no alternative language option or explicit justification is provided, it may violate language/locale policy expectations requiring user choice or documented constraint.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

A health-inspection skill should not silently modify the host environment by downloading and installing Python packages on execution. This behavior increases risk because it can trigger arbitrary third-party package code during install, creates nondeterministic behavior across environments, and may be abused in compromised or intercepted package supply chains.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
91% confidence
Finding

The CLI automatically invokes pip at runtime to install packages, which introduces a supply-chain and unexpected code-execution path unrelated to the core inspection operation. Even though shell injection is not present because arguments are passed as a list and package names are hardcoded, installing and executing packages during normal CLI startup expands the trust boundary to package indexes, network transport, and the local Python environment.

Content

Scanner excerpt · scripts/sysom_cli/__main__.py (reported line 31)May include surrounding context.

python
print(
        f"[Setup] Installing missing dependencies: {', '.join(sorted(missing))}", file=sys.stderr)
    try:
        subprocess.check_call(
            [sys.executable, "-m", "pip", "install",
                "--quiet", *sorted(missing)],
        )

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The code asks for a broad confirmation to 'activate and install SysOM' but does not clearly disclose that it will perform state-changing actions on the account and instance. This weak consent flow increases the risk of users authorizing unexpected system modification, agent deployment, and service-linked role creation without understanding the impact.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The code persists inspection reports to local disk and those reports may include process command lines and memory diagnostics extracted from diagnosis results. Command lines often contain secrets, internal paths, host details, or tenant data, so writing them unredacted to disk increases exposure through local file access, backups, and log collection.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
83% confidence
Finding

The manifest describes an ECS health inspection skill focused on anomaly detection and diagnosis. In this file, the skill implements credential harvesting from process environment variables and ~/.aliyun/config.json, which is a sensitive capability not mentioned in the manifest and not obviously inherent to simple local inspection logic.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The helper can retrieve instance-role credentials from the ECS metadata service and can also assume additional RAM roles via STS, which materially broadens the trust and access boundary of the skill. In the context of an inspection/diagnosis skill, this creates an unexpected identity-access path that could expose privileged cloud credentials or enable cloud-side actions beyond local health inspection if other parts of the skill are compromised or overly permissive.

Content

No source excerpt is available for this finding.

Unverifiable Dependency: setuptools has 10 known advisory(ies) (CVE-2013-1633 (Setuptools vulnerable to Man-in-the-middle attacks); CVE-2025-47273 (setuptools has a path traversal vulnerability in PackageIndex.download that lead); CVE-2024-6345 (setuptools vulnerable to Command Injection via package URL) +7 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependency has known vulnerabilities (CVEs). Using packages with unpatched security flaws exposes the environment to known exploits.

Content

No source excerpt is available for this finding.

Unverifiable Dependency: wheel has 4 known advisory(ies) (CVE-2026-24049 (Wheel Affected by Arbitrary File Permission Modification via Path Traversal in w); CVE-2022-40898 (pypa/wheel vulnerable to Regular Expression denial of service (ReDoS)); CVE-2022-40898 (An issue discovered in Python Packaging Authority (PyPA) Wheel 0.37.1 and earlie) +1 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependency has known vulnerabilities (CVEs). Using packages with unpatched security flaws exposes the environment to known exploits.

Content

No source excerpt is available for this finding.

Unverifiable Dependency: requests has 16 known advisory(ies) (CVE-2014-1830 (Exposure of Sensitive Information to an Unauthorized Actor in Requests); CVE-2024-47081 (Requests vulnerable to .netrc credentials leak via malicious URLs); CVE-2024-35195 (Requests `Session` object does not verify requests after making first request wi) +13 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependency has known vulnerabilities (CVEs). Using packages with unpatched security flaws exposes the environment to known exploits.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
97% confidence
Finding

The dependency manifest does not pin exact versions, which makes builds non-reproducible and can cause different environments to install different releases. In a security-sensitive automation skill that performs instance inspection and diagnosis, this increases supply-chain risk because a newly published vulnerable or malicious package version could be pulled in unintentionally.

Content

Scanner excerpt · scripts/requirements.txt (reported line 1)May include surrounding context.

text
requests>=2.31.0
alibabacloud-tea-openapi>=0.4.4,<1.0.0
alibabacloud-tea-util>=0.3.14,<1.0.0

Static analysis

Detected: suspicious.exposed_resource_identifier

Plaintext HTTP endpoint targets a CGNAT/Tailscale-range address.

Critical
Code
suspicious.exposed_resource_identifier
Location
scripts/sysom_cli/lib/auth.py:57