Public vulnerability disclosure

CVE-2026-59176

Functype: MCP set_functype_version Package Alias RCE via Unsanitized pnpm install + Dynamic Import

publishedCWE-829

Functype is a family of TypeScript functional programming libraries. Prior to 1.4.4, the `set_functype_version` MCP tool in `functype-mcp-server` accepts an unconstrained `version` string using only `z.string()` validation in `packages/mcp-server/src/index.ts` and interpolates it into `functype@<version>` for `pnpm add`. Package-alias syntaxes such as `file:`, `npm:`, URLs, or paths can cause an arbitrary local or remote package to be installed as functype. Immediately afterward, `initDocsData(true)` in `packages/mcp-server/src/lib/docs/data.ts` resolves `functype/cli` and dynamically imports the newly installed module, executing attacker-controlled JavaScript with the MCP server process's privileges. Any MCP client able to send a `tools/call` request invoking the tool can exploit the flaw; the tool is enabled by default without authentication in `stdio` mode. A connected AI assistant susceptible to indirect prompt injection can also be induced to invoke it from a malicious document or web page. In non-default `TRANSPORT_TYPE=httpStream` deployments, a network-accessible attacker does not require local access. Successful execution can read process secrets, modify files, or terminate the server. This issue is fixed in `version` 1.4.4.

Technical severity7.8 highCVSS 3.1 · CNA: GitHub_M
Published2026-10-28Source updated 2026-11-03
Collected2026-11-033 attributed sources

Fixes and workarounds

Fix

functype-mcp-server (npm): OSV reports a fixed version 1.4.4. Check the advisory for supported release branches.

Source: OSV GHSA-wcjj-9m6g-2fr2

Affected products and versions

Affected products, source version ranges and reporting authorities
ProductVersionsAuthority
functype
jordanburke
< 1.4.4 (affected) CNA: GitHub_M
functype-mcp-server

functype-mcp-server
npm
≥ 0; < 1.4.4 (affected, semver); OSV events: introduced 0; fixed 1.4.4
Source events (semver)
[
  {
    "introduced": "0"
  },
  {
    "fixed": "1.4.4"
  }
]

Other versions: unaffected
OSV GHSA-wcjj-9m6g-2fr2

Version ranges are source assertions. Check the vendor advisory and your installed configuration before determining exposure.

CVSS assessments

CVSS scores, vectors and reporting authorities
Version / scoreVectorAuthority
3.1 / 7.8
high
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:HCNA: GitHub_M

Exploit evidence

References

For agents and automation

Read public disclosures for free as Markdown or JSON. Compatible browsers also expose native WebMCP tools to search disclosures, read this page, and discover API access.

Use the ontology-linked Cyber API with x402 pay per request, or a Y2 Pro or Elite API key with the intel:cyber scope.

Endpoints and access details

https://api.y2.dev/api/v2/cyber/cves
https://api.y2.dev/api/v2/cyber/cves/{cveId}

A workspace owner or admin can create a Pro or Elite API key. Send Authorization: Bearer <Y2_API_KEY> from your trusted agent runtime.

For x402, omit Authorization and read the HTTP 402 payment challenge before signing a retry. Public browser tools do not make payments.

Agent access JSON · OpenAPI · CVE API guide