Back to skill

Security audit

zhipu web fetch

Security checks for vulnerabilities and agentic risk

Overview

This is a straightforward Zhipu-backed web page reader with disclosed external API use and no hidden persistence, though users should avoid sensitive URLs and note the wrapper script's weak input validation.

Use this skill only when you are comfortable sending the target URL and remote retrieval request to Zhipu's service under your ZHIPU_API_KEY. Avoid confidential intranet pages, localhost/cloud-metadata targets, authenticated links, and pre-signed URLs, and pass only trusted option values until the wrapper uses proper JSON encoding and validation.

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

Warning
Location
scripts/zhipu_fetch.sh:21
Finding

Unsafe JSON Construction Allows Request-Body Injection

Content
View full analysis
Remediation
View remediation
&2 exit 1 } if (( TIMEOUT < 1 || TIMEOUT > 300 )); then echo "Error: timeout must be between 1 and 300 seconds" >&2 exit 1 fi case "$RETURN_FORMAT" in markdown|text) ;; *) echo "Error: format must be markdown or text" >&2 exit 1 ;; esac PAYLOAD=$(jq -n \ --arg url "$URL" \ --argjson timeout "$TIMEOUT" \ --argjson no_cache "$NO_CACHE" \ --arg return_format "$RETURN_FORMAT" \ --argjson retain_images "$RETAIN_IMAGES" \ --argjson no_gfm "$NO_GFM" \ --argjson keep_img_data_url "$KEEP_IMG_DATA_URL" \ --argjson with_images_summary "$WITH_IMAGES_SUMMARY" \ --argjson with_links_summary "$WITH_LINKS_SUMMARY" \ '{ url: $url, timeout: $timeout, no_cache: $no_cache, return_format: $return_format, retain_images: $retain_images, no_gfm: $no_gfm, keep_img_data_url: $keep_img_data_url, with_images_summary: $with_images_summary, with_links_summary: $with_links_summary }') ``` 3. If adding `jq` is undesirable, use another available JSON serializer that correctly escapes quotes, backslashes, Unicode, and control characters. Avoid manually assembling JSON. 4. Add tests covering quotes, backslashes, newlines, tabs, duplicate-property injection attempts, nonnumeric timeouts, extreme timeout values, missing argument values, and unsupported output formats. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (5)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
84% confidence
Finding

The skill uses shell via curl and a wrapper script but does not declare any tool scope or allowed-tools constraints. This weakens defense-in-depth by allowing broader execution context than necessary and makes it harder for a host system to enforce least privilege for a network-capable skill.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill sends user-supplied URLs and the fetched page contents to Zhipu's external Reader API, but the description does not clearly warn users that their inputs and retrieved data leave the local environment. This creates a privacy and data-handling risk, especially if users provide internal, sensitive, or authenticated URLs.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
92% confidence
Finding

The skill is explicitly designed to transmit a target URL to an external service, which then retrieves and parses the page content. In context this behavior is expected, but it is still security-relevant because it can expose sensitive destinations or data to a third party and could be misused to fetch internal or private resources if callers are not restricted.

Content

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

Quick Start

Basic cURL Usage

bash
curl --request POST \

External Transmission

Medium
Category
Data Exfiltration
Confidence
94% confidence
Finding

This cURL call sends the requested URL and payload to an external endpoint, creating a data exfiltration channel for any URL the user provides. In the context of a web-fetching skill, this is expected functionality, but it becomes security-relevant because users may supply sensitive internal or private URLs and the script does not constrain or prominently disclose that remote processing occurs.

Content

Scanner excerpt · scripts/zhipu_fetch.sh (reported line 82)May include surrounding context.

sh
EOF
)

# Execute cURL request
curl -s --request POST \
  --url https://open.bigmodel.cn/api/paas/v4/reader \
  --header "Authorization: Bearer $ZHIPU_API_KEY" \

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The script transmits the user-supplied URL, fetch options, and the bearer-authenticated request to a third-party API service, but it provides no runtime warning, consent gate, or data-handling notice to the user. In a URL-reading skill, users may assume the fetch happens locally; sending internal, sensitive, or pre-signed URLs to an external provider can expose confidential endpoints and metadata.

Content

No source excerpt is available for this finding.