Back to skill

Security audit

Widget

Security checks for vulnerabilities and agentic risk

Overview

The skill is a disclosed macOS widget helper, but it needs review because its widget installer can overwrite files outside the widget folder and setup makes persistent host changes.

Install only if you are comfortable with a skill that can run shell scripts, install or start Übersicht, copy files into ~/.claude, and modify/delete files in the Übersicht widgets directory. Avoid passing custom target names to install-widget.sh until path validation is added, and review any requested delete or setup action before allowing it.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/install-widget.sh:18
Finding

Arbitrary File Overwrite Through Target-Name Path Traversal

Content
View full analysis
&2 exit 1 fi if [ -z "$APP_PATH" ]; then echo "Übersicht.app not found. Run bash scripts/setup.sh first." >&2 exit 1 fi if [ ! -d "$WIDGET_DIR" ]; then echo "Widget directory not found: $WIDGET_DIR" >&2 echo "Run bash scripts/setup.sh first so Übersicht can create the widget directory." >&2 exit 1 fi cp "$SOURCE_FILE" "$WIDGET_DIR/$TARGET_NAME" ``` ### Technical Analysis The optional target filename is taken directly from the second command-line argument and appended to the widget directory without validation or canonicalization: ```bash TARGET_NAME="${2:-$(basename "$SOURCE_FILE")}" cp "$SOURCE_FILE" "$WIDGET_DIR/$TARGET_NAME" ``` Although the default value uses `basename`, a caller-supplied value can contain directory traversal sequences such as `../`. The operating system resolves those sequences before the copy is performed, allowing the destination to escape the intended Übersicht widget directory. The script does not reject: - Absolute or traversal-based paths - Directory separators - Non-`.jsx` filenames - Existing destination files - Destinations whose canonical parent is outside the widget directory Because `cp` overwrites existing files by default, exploitation can replace any file writable by the current user. ### Attack Path A concrete exploitation sequence is: 1. Create a file containing attacker-controlled shell commands: ```bash cat > /tmp/payload <<'EOF' echo "attacker-controlled command" > /tmp/widgetdesk-executed EOF ``` 2. Invoke the i ...[truncated 1331 chars]
Remediation
View remediation
&2 exit 1 fi ``` 2. Explicitly reject absolute paths, separators, and parent-directory references: ```bash if [[ "$TARGET_NAME" == /* || "$TARGET_NAME" == *"/"* || "$TARGET_NAME" == *"\\"* || "$TARGET_NAME" == "." || "$TARGET_NAME" == ".." ]]; then echo "Target name must be a filename, not a path" >&2 exit 1 fi ``` 3. Construct the destination only after validation: ```bash DESTINATION="$WIDGET_DIR/$TARGET_NAME" ``` 4. Canonicalize and verify the destination parent where platform support permits: ```bash canonical_widget_dir="$(cd "$WIDGET_DIR" && pwd -P)" canonical_parent="$(cd "$(dirname "$DESTINATION")" && pwd -P)" if [ "$canonical_parent" != "$canonical_widget_dir" ]; then echo "Destination escapes the widget directory" >&2 exit 1 fi ``` 5. Avoid silently overwriting an existing widget. Either refuse replacement by default: ```bash cp -n -- "$SOURCE_FILE" "$DESTINATION" ``` or require a separate explicit `--force` option before overwriting. 6. Add regression tests covering `../`, absolute paths, embedded separators, hidden files, malformed extensions, and valid kebab-case widget names. ]]>
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (43)

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The skill advertises widget management, but the documentation instructs use of setup scripts that install host dependencies, start applications, and populate skill files under the user's home directory. That is materially broader than CRUD on widget files and can change the host environment in ways a user may not expect from the manifest alone.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The skill advertises widget management, but the documentation instructs use of setup scripts that install host dependencies, start applications, and populate skill files under the user's home directory. That is materially broader than CRUD on widget files and can change the host environment in ways a user may not expect from the manifest alone.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The skill advertises widget management, but the documentation instructs use of setup scripts that install host dependencies, start applications, and populate skill files under the user's home directory. That is materially broader than CRUD on widget files and can change the host environment in ways a user may not expect from the manifest alone.

Content

No source excerpt is available for this finding.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- When working inside a WidgetDesk repo clone, run `bash scripts/setup.sh` first

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
96% confidence
Finding

The raw deletion command uses a user-controlled placeholder in a shell command: rm ~/Library/Application Support/Übersicht/widgets/{name}.jsx. If name is not strictly validated and safely escaped, an agent could be induced to delete unintended files via path traversal, globbing, or shell metacharacter injection; even without injection, permanent deletion of local files is inherently high risk.

Content

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

~/Library/Application\ Support/Übersicht/widgets/{name}.jsx

Delete a widget

rm ~/Library/Application\ Support/Übersicht/widgets/{name}.jsx

text

Prefer the `scripts/` helpers for host operations. Only write raw widget files directly when creating or replacing actual JSX content.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `now-playing.jsx` | Apple Music now playing | Bottom center |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `weather-canvas.jsx` | Animated weather card | Top left |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `git-pulse.jsx` | Local Git activity heatmap | Top right |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `memo-capsule.jsx` | Local quick-note capsule | Top center |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `volume-knob.jsx` | System volume control knob | Right side |

Lp1

High
Category
MCP Least Privilege
Confidence
98% confidence
Finding

The script has broad shell execution capability and performs filesystem changes, process launching, and installation actions, but the declared skill description only mentions widget management. This mismatch is dangerous because users or reviewers may not expect installer-level behavior from a skill, weakening informed consent and increasing the chance of unintended code execution.

Content

No source excerpt is available for this finding.

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
70% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · scripts/setup.sh (reported line 73)May include surrounding context.

sh
else
    if [ ! -f "$zip_path" ] || ! verify_sha256 "$zip_path" "$sha256"; then
      echo -e "${YELLOW}→${NC} 正在下载 Übersicht ${version}..."
      curl -fL "$url" -o "$zip_path"
    fi
    if ! verify_sha256 "$zip_path" "$sha256"; then
      echo -e "${RED}✗${NC} Übersicht 安装包校验失败"

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

This file implements a Git activity monitoring widget, but the declared skill is for managing Übersicht desktop widgets. That mismatch matters because the code performs unrelated local data collection from the user's home directory, which can bypass user expectations and consent boundaries for the stated skill purpose. In an agent skill ecosystem, capability/purpose mismatch is dangerous because it can hide surveillance-like behavior inside a seemingly innocuous tool.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The manifest describes a skill whose function is to manage Übersicht widgets themselves. This code does not implement widget lifecycle management; instead, it defines a specific weather widget template that fetches current weather data and renders animated UI, which is a materially different behavior from the manifest's claimed scope.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The trigger text says to use this skill whenever the user asks for desktop widgets, desktop gadgets, or widgets, which is broad enough to match casual requests. Because the skill also recommends setup and host-modifying scripts, overbroad invocation increases the chance of activating privileged behavior in contexts where the user did not intend system changes.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The skill directs the agent to run host setup and app-management scripts as a first step, including starting Übersicht and preparing the environment. This expands the trust boundary from widget file management to system configuration and execution of local scripts, increasing the chance of unintended host changes.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The setup script is described as installing missing host dependencies, which is a significant capability escalation for a widget skill. Dependency installation can fetch and execute external software, modify package-manager state, and create persistent system changes unrelated to the user's immediate widget request.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The documentation includes direct destructive operations such as deleting widget files with rm, but does not require confirmation, backup, or a safer recovery path. In an agent context, omission of explicit warnings makes accidental data loss more likely, especially if filenames are user-supplied or ambiguous.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

This markdown skill guidance forces a specific language for all readers, which can violate language/locale policy when no user opt-in or justified regional constraint is provided. The file contains instructional content only in Chinese and does not indicate that the skill is intended exclusively for a Chinese-speaking audience.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.