Skip to main content
Vulnerability Database/CVE-2026-102911

CVE-2026-102911: zosmaai pi-llm-wiki RCE Vulnerability

CVE-2026-102911 is a remote code execution vulnerability in zosmaai pi-llm-wiki that enables OS command injection through the wiki_capture_source MCP tool. This article covers technical details, affected versions, and mitigation.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-102911 Overview

CVE-2026-102911 is an OS command injection vulnerability in the zosmaai/pi-llm-wiki project, affecting versions up to and including 0.11.7. The flaw resides in the wiki_capture_source MCP (Model Context Protocol) tool implemented in mcp/index.ts. An attacker can manipulate the url argument to inject arbitrary operating system commands. The issue is classified under CWE-77: Improper Neutralization of Special Elements used in a Command. Exploitation occurs remotely and requires only low privileges. A public exploit has been disclosed, and the maintainers have released version 0.11.8 to address the flaw.

Critical Impact

A remote authenticated attacker can execute arbitrary OS commands on the host running the pi-llm-wiki MCP server through a crafted url argument, leading to full compromise of confidentiality, integrity, and availability.

Affected Products

  • zosmaai/pi-llm-wiki versions up to and including 0.11.7
  • wiki_capture_source MCP tool defined in mcp/index.ts
  • Downstream deployments exposing the vulnerable MCP tool to LLM agents

Discovery Timeline

Technical Details for CVE-2026-102911

Vulnerability Analysis

The wiki_capture_source MCP tool accepts a url argument that is passed into a shell invocation without sanitization. The vulnerable code path in extensions/llm-wiki/lib/source-extractors.ts executed sh -c with an interpolated command string that embedded the attacker-controlled source value directly into the shell command line. Because sh -c re-parses its argument, any shell metacharacters (backticks, $(...), ;, &&, |) inside the URL are interpreted as command syntax rather than data. Attackers with the ability to invoke the MCP tool can inject arbitrary commands that run with the privileges of the pi-llm-wiki process.

Root Cause

The root cause is unsafe construction of a shell command using string interpolation. The extractor invoked markitdown through sh -c "uvx --from 'markitdown[docx,pdf]' markitdown \"${source}\" 2>/dev/null || echo \"\"", embedding an untrusted argument into the shell. Double-quoting is insufficient because command substitution ($(...), backticks) still executes inside double quotes in POSIX shells.

Attack Vector

Exploitation is remote and requires the ability to call the wiki_capture_source MCP tool, typically via an LLM agent or an MCP client connected to the server. The attacker supplies a url argument containing shell metacharacters. When the extractor forwards the value to sh -c, the injected payload executes on the server. Because MCP tools are often invoked automatically by LLM agents, prompt injection through untrusted documents or web content can indirectly trigger the vulnerability.

typescript
// Security patch in extensions/llm-wiki/lib/source-extractors.ts
// fix(source-extractors): prevent OS command injection via sh -c (CWE-78) #185
    if (!(await hasMarkItDown(pi, signal))) return "";
    const mdResult = await exec(
      pi,
-     "sh",
-     ["-c", `uvx --from 'markitdown[docx,pdf]' markitdown "${source}" 2>/dev/null || echo ""`],
+     "uvx",
+     ["--from", "markitdown[docx,pdf]", "markitdown", source],
      { signal, timeout: markitdownTimeoutMs() },
    );
    return mdResult.stdout.trim() ? mdResult.stdout : "";

Source: GitHub commit 360867034e79175b45c8e04a98e4ca712bbaca35. The patch removes the sh -c wrapper and executes uvx directly with an argument array, so source is passed as a discrete argv element and never re-interpreted by a shell.

Stop Remote Code Execution Before It Runs

Singularity™ Endpoint detects and blocks exploit attempts at machine speed, including zero-days and novel attack techniques.

Stop Exploit Attempts

Detection Methods for CVE-2026-102911

Indicators of Compromise

  • Child processes of the pi-llm-wiki Node.js runtime spawning sh, bash, or unexpected binaries such as curl, wget, nc, or python shortly after MCP tool invocations.
  • Outbound network connections from the pi-llm-wiki host to unfamiliar IP addresses immediately following wiki_capture_source calls.
  • MCP request logs containing url argument values with shell metacharacters like `, $(, ;, |, or &&.

Detection Strategies

  • Instrument the MCP server to log every wiki_capture_source invocation with the raw url value and correlate against a deny-list of shell metacharacters.
  • Enable process-lineage telemetry on hosts running pi-llm-wiki to flag node -> sh -> * chains that deviate from the expected node -> uvx -> markitdown pattern.
  • Hunt for anomalous file writes, cron modifications, or SSH key changes originating from the pi-llm-wiki service account.

Monitoring Recommendations

  • Forward MCP tool invocation logs and endpoint process telemetry to a centralized analytics platform for behavioral baselining.
  • Alert on any process spawned by the pi-llm-wiki service whose command line does not match the allow-listed extractor binaries (uvx, markitdown).
  • Monitor for prompt-injection patterns in ingested documents that attempt to coerce agents into calling wiki_capture_source with crafted URLs.

How to Mitigate CVE-2026-102911

Immediate Actions Required

  • Upgrade zosmaai/pi-llm-wiki to version 0.11.8 or later, which contains patch commit 360867034e79175b45c8e04a98e4ca712bbaca35.
  • Audit MCP client configurations and revoke access for any untrusted agents that can invoke the wiki_capture_source tool.
  • Review historical MCP invocation logs for url arguments containing shell metacharacters and investigate matches as potential intrusions.

Patch Information

The fix is available in pi-llm-wiki v0.11.8 via commit 360867034e79175b45c8e04a98e4ca712bbaca35. The patch replaces sh -c with a direct invocation of uvx, passing source as an argv element. This eliminates shell re-parsing and closes the injection vector. Additional context is available in Issue #185 and Pull Request #186.

Workarounds

  • If immediate upgrade is not possible, disable or unregister the wiki_capture_source MCP tool in mcp/index.ts until the patched release is deployed.
  • Restrict access to the MCP server so only trusted, authenticated clients can invoke tools, and place the service behind a network policy that blocks arbitrary outbound egress.
  • Run the pi-llm-wiki process under a least-privilege user with no shell, and apply seccomp or AppArmor profiles to prevent unexpected process execution.
bash
# Upgrade to the patched release
npm install zosmaai/pi-llm-wiki@0.11.8

# Verify installed version
npm ls pi-llm-wiki | grep 0.11.8

# Confirm the vulnerable sh -c pattern is no longer present
grep -R "sh\",\s*\[\"-c\"" node_modules/pi-llm-wiki/ || echo "No vulnerable pattern found"

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.