Back to skill

Security audit

Huawei Cloud Swr Image Automation

Security checks for vulnerabilities and agentic risk

Overview

This is a legitimate Huawei Cloud SWR automation guide, but it includes enabled auto-deploy and other mutating cloud commands that could affect live workloads without strong enough guardrails.

Review this skill before installing if it will be used against production Huawei Cloud accounts. Use least-privilege IAM scoped to specific SWR namespaces/repositories and regions, prefer read-only checks first, require explicit human approval before create/update/delete commands, start with syncAuto=false and --enable=false where possible, avoid broad condition=.* production triggers, and use override=true only when overwrite intent is 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
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (31)

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · references/iam-policies.md (reported line 24)May include surrounding context.

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · references/swr-automation-api-guide.md (reported line 260)May include surrounding context.

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · references/task-trigger-management.md (reported line 21)May include surrounding context.

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · references/task-trigger-management.md (reported line 91)May include surrounding context.

md
name: huawei-cloud-swr-image-automation
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
80% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
description: |
  Huawei Cloud SWR (Software Repository for Container) image automation and operations skill using hcloud CLI.
  Use this skill when the user wants to: (1) configure cross-region image sync (auto or manual), (2) manage SWR triggers for auto-deploy to CCE/CCI, (3) query available sync target regions, (4) check sync job status, (5) create/update/delete trigger configurations.
  Trigger: user mentions "SWR automation", "SWR 自动化", "镜像同步", "SWR sync", "跨区域同步", "cross-region sync", "触发器", "SWR trigger", "自动部署", "auto deploy", "镜像复制", "image replication", "SWR 触发器"
tags: [swr, image-automation, image-sync, trigger, auto-deploy]
---

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
91% confidence
Finding

This concrete example creates an enabled deployment trigger targeting a cluster, which can automate updates to workloads whenever matching images are pushed. In a cloud operations skill, presenting this as a standard command without strong guardrails increases the chance of unintended or unsafe production changes and can amplify the impact of a malicious or mistaken image push.

Content

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

See Task: Trigger Management for detailed workflows.

bash
# Create a trigger for auto-deploy to CCE
hcloud SWR CreateTrigger --namespace=group-dev --repository=my-app --name=deploy-trigger --trigger_type=all --condition=".*" --action=update --app_type=deployments --application=my-deployment --cluster_ns=default --enable=true --trigger_mode=cce --cluster_id=<cluster-id> --cluster_name=<cluster-name> --cli-region=cn-north-4

# List all triggers for a repository

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The skill instructs users to create an enabled auto-deploy trigger for CCE/CCI without clearly warning that future image pushes can automatically modify running workloads. In this context, that can cause unintended production changes, rapid propagation of bad or compromised images, and reduced human oversight over deployment events.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The document includes a tag deletion command for the target region without an explicit warning that deleting image tags is a destructive action that may permanently remove deployment artifacts relied on by downstream systems. In an automation/troubleshooting skill, users may copy-paste commands directly, so the lack of a clear caution increases the risk of accidental production impact or data loss.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

This section documents creation of auto-deploy triggers that allow future image pushes to autonomously update CCE/CCI workloads. While this is core functionality of SWR, it still represents autonomous infrastructure-changing behavior, and in the context of an agent skill it is risky because the agent may help a user configure unattended deployment actions without emphasizing review gates or blast-radius controls.

Content

Scanner excerpt · references/swr-automation-api-guide.md (reported line 163)May include surrounding context.

1. Create Trigger

bash
# Create trigger for auto-deploy to CCE (all pushes)
hcloud SWR CreateTrigger --namespace=group-dev --repository=my-app --name=deploy-trigger --trigger_type=all --condition=".*" --action=update --app_type=deployments --application=my-deployment --cluster_ns=default --enable=true --trigger_mode=cce --cluster_id=<cluster-id> --cluster_name=<cluster-name> --cli-region=cn-north-4

# Create trigger for specific tag pattern (semver)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The trigger creation examples enable automatic deployment updates to CCE/CCI but do not clearly warn that subsequent image pushes can immediately modify running workloads. In an automation skill, omission of this operational safety warning can cause users to create deployment triggers that propagate unreviewed or unintended images into production-like environments.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The manifest limits this skill to SWR image sync automation, sync status, available regions, and trigger configuration. These lines instruct use of hcloud SWR CreateNamespace, which creates registry namespaces and expands the skill into broader repository administration not declared in the stated purpose.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The DR example performs cross-region replication with override enabled and includes namespace creation, but it does not prominently warn that this can propagate sensitive images across jurisdictions or overwrite existing target artifacts. In an infrastructure automation context, unclear guidance around replication and overwrite semantics can cause unintended data exposure, compliance issues, or destructive replacement of images in another region.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

These scenario steps actively instruct users to create namespaces in multiple regions, which is a separate SWR administration action from the manifest's stated image sync and trigger management purposes. This documents capability expansion rather than a purely internal implementation detail.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

This scenario is centered on creating matching namespaces across regions, which is broader than the manifest's declared SWR sync/trigger automation responsibilities. It presents namespace lifecycle management as part of the skill despite that capability not being declared.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The examples create triggers that automatically roll workloads on any matching image push, including broad patterns like --trigger_type=all with condition=.*. In an operations skill, this can cause unintended or unsafe production-like changes if users apply examples without understanding that any pushed image may immediately affect running services.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
## Common Scenarios

### S1: CI/CD Auto-deploy Pipeline

Set up automatic deployment updates when CI pushes new images:

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · references/task-trigger-management.md (reported line 124)May include surrounding context.

md
## Common Scenarios

### S1: CI/CD Auto-deploy Pipeline

Set up automatic deployment updates when CI pushes new images:

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The production scenario demonstrates automatic deployment of production workloads from semver-tag pushes without a prominent warning about the operational risk. If a compromised CI pipeline, mistaken tag, or unreviewed image is pushed, the trigger can propagate that change directly into production with little friction.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The verification guide includes create and delete operations against real SWR resources as part of normal validation, but it does not explicitly warn users that these steps will modify or remove cloud configuration. In a cloud operations skill, users may treat verification steps as safe to run blindly, which can lead to unintended repository replication changes or deletion of sync configuration in production environments.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The manual sync and trigger-management sections can initiate image replication and automated deployment actions in downstream CCE/CCI systems, yet the document does not explicitly warn that these commands may cause operational changes beyond SWR itself. Because triggers can update running workloads automatically, presenting them as routine verification steps increases the risk of accidental rollout, service disruption, or propagation of unintended images.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.