Back to skill

Security audit

Searx Search

Security checks for vulnerabilities and agentic risk

Overview

The skill is a real web-search helper, but it under-discloses that one query may be sent to many public third-party search servers.

Review before installing. Use this only if you are comfortable with search queries and network metadata being sent to public SearX instances, potentially up to ten per search. Avoid sensitive, confidential, credential-like, personal, or regulated queries unless the skill is changed to use a vetted or self-hosted endpoint and the documented retry limit is enforced.

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
Findings (1)

other

Warning
Location
scripts/search_searx.sh:20
Finding
Search Queries Are Disclosed to More Third-Party Instances Than Documented## Vulnerability Details **File Location**: `scripts/search_searx.sh`, lines 20 and 29–44 **Vulnerability Type**: Excessive Third-Party Search Query Disclosure **Risk Level**: Medium ### Complete Code Snippet ```bash # Extract HTTPS URLs from the JSON using node for accuracy. INSTANCES=($(echo "$INSTANCE_LIST" | node -e "const data = JSON.parse(require('fs').readFileSync(0, 'utf8')); const urls = Object.keys(data.instances || {}).filter(u => u.startsWith('https://')); console.log(urls.slice(0, 20).join('\n'));")) if [[ ${#INSTANCES[@]} -eq 0 ]]; then echo "未找到可用的 SearX 实例。" exit 1 fi fi MAX_ATTEMPTS=10 ATTEMPT=0 for URL in "${INSTANCES[@]}"; do ((ATTEMPT++)) if (( ATTEMPT > MAX_ATTEMPTS )); then break fi # Encode query for URL. ENCODED_QUERY=$(node -e "console.log(encodeURIComponent(process.argv[1]))" "$QUERY" 2>/dev/null) if [[ -z "$ENCODED_QUERY" ]]; then # Fallback: simple space replacement ENCODED_QUERY=$(echo "$QUERY" | sed 's/ /%20/g') fi SEARCH_URL="${URL%/}/search?q=${ENCODED_QUERY}&format=json" RESPONSE=$(curl -s -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36" "${SEARCH_URL}" 2>/dev/null) ``` ### Technical Analysis The Skill documentation states that searches retry using no more than three SearX instances. The implementation instead extracts up to 20 dynamically supplied HTTPS endpoints and configures a maximum of ten attempts. Each attempted request places the user-provided query in the URL query string and transmits it to a public, independently operated SearX server. An HTTPS URL protects the request while in transit, but the selected server can still observe and retain the search query, source IP address, user agent, request timing, and related network metadata. The registry is downloaded dynamically from `searx.space`, and the code accepts every listed URL that begins with `https://` without applying an operator allowlist or trust poli ...[truncated 1633 chars]
Remediation
## Remediation Suggestions 1. Make implementation behavior match the documented three-instance limit: ```bash MAX_ATTEMPTS=3 ``` 2. Extract no more than three endpoints, or preferably choose them from a maintained allowlist of reviewed operators: ```javascript console.log(urls.slice(0, 3).join('\n')); ``` 3. Clearly disclose that queries and network metadata are sent to independently operated third-party SearX services. 4. Request explicit user confirmation before sending queries likely to contain personal, confidential, regulated, or credential-like data. 5. Apply a trust policy to registry entries rather than accepting every URL based solely on an `https://` prefix. Relevant criteria may include operator identity, privacy policy, logging policy, jurisdiction, and recent availability. 6. Add connection and total request timeouts to prevent unresponsive instances from delaying execution: ```bash curl --connect-timeout 5 --max-time 15 ... ``` 7. Enforce successful HTTP status handling with `--fail` or explicitly inspect `%{http_code}` before processing a response. This aligns implementation with the documented requirement that only HTTP 200 responses be accepted. 8. Consider using a single trusted search provider or a user-configured self-hosted SearX instance when search confidentiality is important.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • 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 (11)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding
A documented limit of up to two alternative retries sets user and platform expectations, but the actual behavior reportedly attempts up to 10 instances. This mismatch is dangerous because it expands external data disclosure and outbound network activity beyond what reviewers and users consented to, undermining trust and policy enforcement.

External Script Fetching

High
Category
Supply Chain
Content
fi

# Fetch instance list (JSON) and extract URLs.
INSTANCE_LIST=$(curl -s https://searx.space/data/instances.json 2>/dev/null)
if [[ -z "$INSTANCE_LIST" ]]; then
  # Fallback to a hard‑coded list of known public instances when the fetch fails.
  INSTANCES=(
Confidence
90% confidence
Finding
This duplicate finding points to the same risky behavior: remote discovery of search backends from a third-party source and use of arbitrary public instances without trust controls. Because the skill's purpose is web search, this directly increases privacy and integrity risk by routing user queries through unknown operators.

External Script Fetching

High
Category
Supply Chain
Content
fi

# Fetch instance list (JSON) and extract URLs.
INSTANCE_LIST=$(curl -s https://searx.space/data/instances.json 2>/dev/null)
if [[ -z "$INSTANCE_LIST" ]]; then
  # Fallback to a hard‐coded list of known public instances when the fetch fails.
  INSTANCES=(
Confidence
90% confidence
Finding
This duplicate finding points to the same risky behavior: remote discovery of search backends from a third-party source and use of arbitrary public instances without trust controls. Because the skill's purpose is web search, this directly increases privacy and integrity risk by routing user queries through unknown operators.

Lp3

Medium
Category
MCP Least Privilege
Confidence
93% confidence
Finding
The skill declares network and shell-capable behavior but does not specify any tool scope such as permissions or allowed-tools. This creates unnecessary ambiguity about what the skill is authorized to do and increases the risk of over-broad execution in environments that rely on manifest restrictions for containment.

Vague Triggers

Medium
Confidence
94% confidence
Finding
The trigger conditions are broad enough to activate on common requests for general web searching, which can cause the skill to be invoked frequently and send user queries to third-party infrastructure. In this context, that increases privacy exposure and the chance of unintentional use without clear user awareness.

Missing User Warnings

Medium
Confidence
97% confidence
Finding
The skill sends user search queries to public third-party SearX instances but does not warn users about that data transfer. This is dangerous because queries may contain sensitive personal, corporate, or security-related information, and public instances are outside the operator's control and may log or inspect requests.

Missing User Warnings

Medium
Confidence
94% confidence
Finding
The script sends user search terms to arbitrary public SearX instances discovered from a third-party directory, with no disclosure, consent, or trust policy. In this skill context, queries may contain sensitive prompts, current interests, or operational data, and public instances can log or profile that traffic.

Natural-Language Policy Violations

Low
Confidence
82% confidence
Finding
The file presents Chinese trigger phrases and a Chinese-only failure message without indicating that language selection is optional or user-driven. This can violate language/locale policy expectations by implying a fixed locale rather than offering a choice.

Natural-Language Policy Violations

Low
Confidence
95% confidence
Finding
The script emits Chinese-only status and error messages such as the prompt for a search keyword, which imposes a specific language on users. There is no indication that the tool is intentionally region-specific or that users can opt into another language.

Natural-Language Policy Violations

Low
Confidence
95% confidence
Finding
This line outputs a Chinese-only message when no SearX instances are found, enforcing a locale choice without user opt-in. The file contains no documentation indicating that Chinese is a required or justified language for this skill.

Natural-Language Policy Violations

Low
Confidence
95% confidence
Finding
The final failure message is presented only in Chinese, which violates the language-choice policy absent user opt-in or a documented locale restriction. Nothing in the file indicates that the script is region- or language-specific by design.

Static analysis

No suspicious patterns detected.