Back to skill

Security audit

Web Extractor

Security checks for vulnerabilities and agentic risk

Overview

This web extraction skill has a coherent purpose, but its instructions expose user URLs to a third-party service and use unsafe shell and temporary-file patterns that users should review before installing.

Install only if you are comfortable sending requested webpage URLs to r.jina.ai. Do not use it with private, internal, signed, tokenized, or credential-bearing links. A safer version should validate http/https URLs, avoid shell interpolation, use unique temporary files, and explicitly ignore instructions contained in fetched webpage text.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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 (4)

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:16
Finding
Unvalidated URL Substitution Can Enable Shell Command Injection## Vulnerability Details **File Location**: `SKILL.md`, line 16 **Vulnerability Type**: Shell command injection through unsafe input interpolation **Risk Level**: High ### Vulnerable Code ```bash # Extract webpage content and save it as a Markdown file curl -s https://r.jina.ai/<URL> > /tmp/web-content.md ``` ### Technical Analysis The documented workflow instructs the agent to substitute a user-provided URL directly into a shell command. It does not require URL validation, shell escaping, or use of a process execution interface that keeps arguments separate from shell syntax. If an implementation performs direct string substitution, shell metacharacters in the supplied value may terminate or modify the `curl` command. Merely quoting a URL is not a complete defense if the command is still assembled unsafely or evaluated through a shell. ### Attack Path 1. An attacker asks the agent to summarize a URL containing shell control characters or command substitution syntax. 2. The agent inserts the supplied value into the documented command template. 3. The resulting command is passed to a shell. 4. The shell interprets the injected syntax as an additional command rather than as part of the URL. 5. The injected command executes with the same operating-system privileges as the agent process. ### Impact Assessment Successful exploitation could permit arbitrary command execution within the agent's security context. The attacker could read or modify files accessible to the process, access environment variables and credentials, alter task output, invoke available tools, or perform network requests. The issue does not independently demonstrate privilege escalation beyond the agent's existing account.
Remediation
## Remediation Suggestions - Accept only syntactically valid `http` or `https` URLs. - Reject embedded credentials, control characters, and unexpected URL schemes. - Parse the URL with a dedicated URL parser rather than regular-expression substitution. - Invoke `curl` through an argument-array API without a shell, for example by passing the URL as one isolated process argument. - Do not use `eval`, shell command concatenation, or equivalent dynamic interpretation. - Apply process sandboxing and restrict filesystem and network privileges to those required for retrieval.

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:16
Finding
Predictable Files in a Shared Temporary Directory Permit File Clobbering and Task Collisions## Vulnerability Details **File Location**: `SKILL.md`, lines 16-29 **Vulnerability Type**: Unsafe temporary-file handling **Risk Level**: Medium ### Vulnerable Code ```bash curl -s https://r.jina.ai/<URL> > /tmp/web-content.md ``` ```bash curl -s "https://r.jina.ai/https://www.bbc.com/news/technology-xxx" > /tmp/news.md ``` ### Technical Analysis The workflow writes extraction results to fixed, predictable names under the shared `/tmp` directory. Shell redirection follows symbolic links and normally truncates an existing target. A local attacker who can create entries in `/tmp` may pre-create one of these paths as a symbolic link to another file writable by the agent. Predictable names also allow concurrent or sequential tasks to overwrite one another's content. An attacker or another task could replace the temporary content before it is read, causing the agent to summarize attacker-controlled data. ### Attack Path 1. A local attacker predicts that the skill will use `/tmp/web-content.md` or `/tmp/news.md`. 2. The attacker creates a symbolic link at that path pointing to another file writable by the agent, or repeatedly replaces the temporary file with malicious content. 3. The skill executes shell redirection to the predictable path. 4. The linked destination is truncated and overwritten, or attacker-controlled content is consumed during the subsequent read. 5. This results in file corruption, content substitution, or cross-task information exposure. ### Impact Assessment The maximum file-clobbering scope is limited to files writable by the operating-system identity running the agent. Exploitation may corrupt application data or configuration, manipulate the resulting summary, and expose fetched content between concurrent tasks. It does not by itself grant access to files that the agent account cannot already modify.
Remediation
## Remediation Suggestions - Create a unique private temporary directory with an OS-provided secure primitive such as `mktemp -d`. - Use unpredictable file names and permissions that restrict access to the current process identity. - Open temporary output files with exclusive creation and no-follow semantics where available. - Avoid shell redirection when a process API can write directly to a securely opened file descriptor. - Keep each request's files isolated and delete temporary data in a guaranteed cleanup step. - Verify that the file remains the expected regular file before reading it.

T01 · Skill Instruction Hijacking

Error
Location
SKILL.md:19
Finding
Untrusted Extracted Web Content Is Passed Directly to the Agent## Vulnerability Details **File Location**: `SKILL.md`, lines 19-21 **Vulnerability Type**: Indirect prompt injection through externally controlled webpage content **Risk Level**: High ### Relevant Instruction The workflow directs the agent to read the generated Markdown file and summarize its core points. No instruction requires the agent to treat commands, policies, or tool-use requests found in that file solely as untrusted webpage data. ### Technical Analysis Webpage content is controlled by external publishers and may include text specifically designed to manipulate an AI agent. Filtering scripts, navigation elements, advertisements, or CSS does not remove natural-language prompt injection. The extraction service can therefore return text that tells the agent to ignore its task, disclose contextual information, invoke tools, access files, or produce attacker-selected output. Passing that text directly into an agent without a trust boundary creates an instruction/data confusion vulnerability. The legitimate functionality only requires summarization and does not require granting extracted content authority over tool use or session goals. ### Attack Path 1. An attacker publishes or modifies a webpage containing adversarial instructions. 2. A user requests that the skill summarize that page. 3. The page is retrieved through `r.jina.ai` and stored as Markdown. 4. The agent reads the extracted text without an explicit untrusted-content boundary. 5. The agent interprets embedded instructions as actionable requests. 6. Depending on the tools and permissions available to the agent, it may alter the summary, disclose accessible context, or perform unintended actions. ### Impact Assessment At minimum, exploitation can compromise summary integrity and redirect the current session's objective. If the summarizing agent retains access to tools, files, credentials, or network operations, the injected text may induce actions within ...[truncated 125 chars]
Remediation
## Remediation Suggestions - Explicitly state that all extracted webpage content is untrusted data and that instructions found within it must never be followed. - Place extracted text inside clearly delimited data boundaries. - Use a constrained summarization prompt that permits only factual extraction and summarization. - Disable tool calls, filesystem access, network access, memory writes, and other side effects during the summarization stage. - Separate retrieval from summarization and provide the summarizer only the minimum content needed. - Detect and flag instruction-like content, but do not rely on detection alone as the security boundary. - Require confirmation before any action outside returning a textual summary.

other

Warning
Location
SKILL.md:16
Finding
Target URLs Are Disclosed to an External Extraction Service## Vulnerability Details **File Location**: `SKILL.md`, lines 16-29 **Vulnerability Type**: Third-party disclosure of URLs and URL-embedded secrets **Risk Level**: Medium ### Vulnerable Code ```bash curl -s https://r.jina.ai/<URL> > /tmp/web-content.md ``` ```bash curl -s "https://r.jina.ai/https://www.bbc.com/news/technology-xxx" > /tmp/news.md ``` ### Technical Analysis The requested target URL is included in a request sent to the third-party `r.jina.ai` service. Consequently, the service receives the complete target value rather than the agent fetching the page directly. URLs may expose private hostnames, sensitive paths, search terms, document identifiers, signed query parameters, access tokens, or other bearer credentials. The skill does not document this disclosure, obtain informed consent, or require redaction and validation before transmission. ### Attack Path 1. A user supplies a sensitive URL, such as a signed link or a URL containing an access token. 2. The agent embeds the complete URL into the `r.jina.ai` request. 3. DNS, transport, and application-layer metadata are exposed to the external service. 4. The service can observe and potentially retain the target URL and any secrets contained in it. 5. If the URL contains reusable credentials, those credentials may be used within their validity and authorization scope. ### Impact Assessment Exposure includes the user's browsing target and all sensitive information embedded in the URL. If a URL contains a bearer token or signed authorization parameter, impact may extend to unauthorized access to the resource covered by that credential. This behavior does not itself prove that `r.jina.ai` is malicious, but disclosure to it is unnecessary unless third-party proxying is explicitly accepted as part of the task.
Remediation
## Remediation Suggestions - Clearly disclose that the complete target URL will be sent to a third party and obtain explicit user consent. - Prefer direct local retrieval when third-party processing is not necessary. - Reject URLs containing user information, credentials, fragments with sensitive data, access tokens, or signed query parameters. - Redact sensitive query parameters before transmission where doing so preserves functionality. - Block private, loopback, link-local, and otherwise restricted destinations unless they are explicitly required and safely handled. - Document the external service's privacy, retention, and security assumptions. - Apply strict request timeouts, response-size limits, and content-type validation.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (3)

Vague Triggers

Medium
Confidence
92% confidence
Finding
The trigger phrases are generic user intents such as extracting web pages or summarizing news, which can cause the skill to activate for many ordinary requests without the user clearly understanding that an external fetch will occur. In this skill’s context, broad activation increases the chance of unintended data transmission and use of the external r.jina.ai service.

Missing User Warnings

Medium
Confidence
98% confidence
Finding
The skill instructs the agent to send user-supplied URLs to r.jina.ai and then process returned page content, but it does not warn the user that both the requested URL and fetched content are handled by an external service. This creates a meaningful privacy and data-governance risk, especially if users provide sensitive, internal, or authenticated links under the assumption that processing is local.

Natural-Language Policy Violations

Low
Confidence
83% confidence
Finding
The natural-language description, triggers, and examples are entirely specified in Chinese, with no indication that users may interact in other languages or choose their preferred locale. This can be a language-policy issue when a skill effectively imposes one language without opt-in or justification.

Static analysis

No suspicious patterns detected.