GHSA-4P8P-PJPQ-2W7H

Vulnerability from github – Published: 2026-11-09 21:13 – Updated: 2026-11-09 21:13
VLAI
Summary
tsParticles: Malformed JSON requests can terminate the @tsparticles/mcp-server HTTP process
Details

Summary

The HTTP mode of @tsparticles/mcp-server parses incoming /mcp request bodies with JSON.parse() outside a request-local error boundary. A single malformed JSON request causes the async request handler to throw and terminates the Node.js process.

This was verified on v4.3.0 at commit 0266d469aa2d719cb66a9c6bf09aded4186ec17c. Version 4.3.1 appears to fix this by returning HTTP 400 for invalid JSON.

Affected Code

The vulnerable handler is:

if (req.method === "POST" && req.url === "/mcp") {
  const body = await new Promise<string>((resolve, reject) => {
    const chunks: Buffer[] = [];
    req.on("data", (chunk) => chunks.push(Buffer.from(chunk)));
    req.on("end", () => resolve(Buffer.concat(chunks).toString("utf8")));
    req.on("error", reject);
  });

  const parsedBody = body ? JSON.parse(body) : undefined;
  await transport.handleRequest(req, res, parsedBody);
}

The JSON.parse() call is not wrapped in try/catch.

Reproduction

Start the HTTP server and send this malformed request:

POST /mcp HTTP/1.1
Content-Type: application/json
Mcp-Protocol-Version: 2025-11-25

{"jsonrpc":

Observed result in 3 out of 3 runs:

exit_code=1
SyntaxError: Unexpected end of JSON input
at Server.<anonymous> (integrations/mcp-server/src/index.ts:407:38)

Impact

An unauthenticated remote attacker can terminate the exposed MCP process with a single malformed request. The service remains unavailable until restarted by an external supervisor.

Recommendation

Wrap request parsing in a local try/catch and return a bounded HTTP 400 response such as:

{"error":"Invalid JSON"}

The process should remain alive after malformed requests.

Show details on source website

{
  "affected": [
    {
      "database_specific": {
        "last_known_affected_version_range": "\u003c= 4.3.0"
      },
      "package": {
        "ecosystem": "npm",
        "name": "@tsparticles/mcp-server"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "4.3.1"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "aliases": [
    "CVE-2026-76892"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-248"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-11-09T21:13:55Z",
    "nvd_published_at": "2026-11-04T23:17:58Z",
    "severity": "HIGH"
  },
  "details": "## Summary\n\nThe HTTP mode of `@tsparticles/mcp-server` parses incoming `/mcp` request bodies with `JSON.parse()` outside a request-local error boundary. A single malformed JSON request causes the async request handler to throw and terminates the Node.js process.\n\nThis was verified on `v4.3.0` at commit `0266d469aa2d719cb66a9c6bf09aded4186ec17c`. Version `4.3.1` appears to fix this by returning HTTP 400 for invalid JSON.\n\n## Affected Code\n\nThe vulnerable handler is:\n\n    if (req.method === \"POST\" \u0026\u0026 req.url === \"/mcp\") {\n      const body = await new Promise\u003cstring\u003e((resolve, reject) =\u003e {\n        const chunks: Buffer[] = [];\n        req.on(\"data\", (chunk) =\u003e chunks.push(Buffer.from(chunk)));\n        req.on(\"end\", () =\u003e resolve(Buffer.concat(chunks).toString(\"utf8\")));\n        req.on(\"error\", reject);\n      });\n\n      const parsedBody = body ? JSON.parse(body) : undefined;\n      await transport.handleRequest(req, res, parsedBody);\n    }\n\nThe `JSON.parse()` call is not wrapped in `try/catch`.\n\n## Reproduction\n\nStart the HTTP server and send this malformed request:\n\n    POST /mcp HTTP/1.1\n    Content-Type: application/json\n    Mcp-Protocol-Version: 2025-11-25\n\n    {\"jsonrpc\":\n\nObserved result in 3 out of 3 runs:\n\n    exit_code=1\n    SyntaxError: Unexpected end of JSON input\n    at Server.\u003canonymous\u003e (integrations/mcp-server/src/index.ts:407:38)\n\n## Impact\n\nAn unauthenticated remote attacker can terminate the exposed MCP process with a single malformed request. The service remains unavailable until restarted by an external supervisor.\n\n## Recommendation\n\nWrap request parsing in a local `try/catch` and return a bounded HTTP 400 response such as:\n\n    {\"error\":\"Invalid JSON\"}\n\nThe process should remain alive after malformed requests.",
  "id": "GHSA-4p8p-pjpq-2w7h",
  "modified": "2026-11-09T21:13:55Z",
  "published": "2026-11-09T21:13:55Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/tsparticles/tsparticles/security/advisories/GHSA-4p8p-pjpq-2w7h"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-76892"
    },
    {
      "type": "WEB",
      "url": "https://github.com/tsparticles/tsparticles/pull/5875"
    },
    {
      "type": "WEB",
      "url": "https://github.com/tsparticles/tsparticles/commit/25fb70e7f527a91568adaef576570289083f243b"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/tsparticles/tsparticles"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N",
      "type": "CVSS_V4"
    }
  ],
  "summary": "tsParticles: Malformed JSON requests can terminate the @tsparticles/mcp-server HTTP process"
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Vulnerability timeline

Sightings and recorded dates, grouped by day · UTC

JSON
How durations are calculated

Following the VTEM framework (Black Hat USA 2015), time to patch starts when the vendor or a coordinator was informed, total time to patch at discovery, and disclosure to patch at public disclosure; vendor response time runs from the report to its acknowledgement. Time to exploit and time unpatched start at the earliest discovery or report, falling back to public disclosure. Unpatched time ends at the first recorded patch, or the calculation time when no patch is recorded. Exploitation to patch shows the interval between those two events; a published proof of concept is a public exploit, not exploitation.

Each result shows its source dates. A negative interval means the end event came first; when date-only inputs leave the order open, the result says so. Date-only inputs are approximate. The earliest evidence wins: KEV report dates and sightings are labelled as such. Records describing another vulnerability are listed but never calculated from, and a PoC alone does not establish exploitation. Missing patch evidence does not prove that no patch exists. Filters below change the event list only.

Events included in the timeline

Loading timeline…


    Loading…

    Loading…

    Loading…

    Related by attack behaviour

    Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.