Back to skill

Security audit

alibabacloud-bastionhost-network-diag

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed, read-only Alibaba Cloud Bastion Host diagnostic helper, with cloud access that is sensitive but aligned with its purpose.

Before installing, ensure the agent will use a least-privilege Alibaba Cloud profile with only the listed read-only Bastion Host and Cloud Firewall permissions. Review each displayed aliyun command before allowing execution, because the results may reveal instance metadata, endpoints, firewall protection state, and traffic-log details.

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
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Rogue AgentSelf-Modification, Session Persistence
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
Findings (3)

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill advertises activation for broad symptoms even when the user does not mention Bastion Host, which increases the chance the agent runs cloud-enumeration logic in unrelated contexts. That can lead to unnecessary access to cloud metadata and diagnostic APIs based on weak intent matching, violating least-privilege and potentially exposing infrastructure details.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
87% confidence
Finding

The skill permits autonomous execution of CLI-based cloud queries after user authorization, which still creates a meaningful risk because the workflow can enumerate instances, endpoints, firewall assets, and traffic logs. In a mis-triggered or over-broad invocation, this turns the agent into an automated reconnaissance tool against the user's cloud environment.

Content

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

md
- **Only perform read-only queries; strictly prohibit any write, modify, or delete operations**
- All Alibaba Cloud API calls must use `aliyun-cli` commands
- After the user explicitly authorizes automatic execution, the Agent may automatically execute the read-only `aliyun-cli` query commands listed in this Skill
- Before executing each command, display the command to be executed and explain its purpose
- If `aliyun-cli` is unavailable, credentials are not configured, or permissions are insufficient, stop automatic execution and inform the user of manual troubleshooting steps
- In uncertain situations, prioritize asking the user for additional information; do not perform write operations on your own

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

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

md
- After the user explicitly authorizes automatic execution, the Agent may automatically execute the read-only `aliyun-cli` query commands listed in this Skill
- Before executing each command, display the command to be executed and explain its purpose
- If `aliyun-cli` is unavailable, credentials are not configured, or permissions are insufficient, stop automatic execution and inform the user of manual troubleshooting steps
- In uncertain situations, prioritize asking the user for additional information; do not perform write operations on your own
- **Never expose or persist credentials**: do not copy, back up, move, print, `cat`, or read the aliyun CLI config/credential file (`~/.aliyun/config.json`) or any file containing an AccessKey, AccessKeySecret, or STS token, and never write credentials to any file. Credentials are pre-configured by the runtime environment; do not modify or back them up.
- **Run every `aliyun-cli` command as a SINGLE LINE** without backslash (`\`) line continuations, so that the command and all of its parameters appear on one physical line.

Static analysis

No suspicious patterns detected.