{
  "schemaVersion": "guard-threat-campaign/v1",
  "id": "HGTC-2026-76022335",
  "slug": "cve-2026-137567-llama-cpp-rpc-server-out-of-bounds-write",
  "title": "llama.cpp RPC server writes below the buffer it meant to check (CVE-2026-137567)",
  "aliases": [
    "CVE-2026-137567"
  ],
  "summary": "CVE-2026-137567 is an out-of-bounds write in the ggml RPC server that ships with llama.cpp, in builds b11450 through b12657, fixed in b12658. The RPC server runs model compute for a client on another machine and takes tensor commands from whoever connects, with no credentials asked. Its copy_tensor handler checks a copy only at one end: the end of the write must land inside the destination buffer, and the destination pointer itself is never compared with the buffer's base address. A client can learn that base from the server's own BUFFER_GET_BASE answer, then send a copy whose destination sits below the base, and the server writes the source bytes at that heap address, which can crash the server or run code in its process. VulnCheck rates the flaw 9.8 Critical under CVSS 3.1 and 9.3 under CVSS 4.0, as CWE-787. The fix, commit 03813c56 of November 23, 2026, is the b12658 tag itself and rewrites the server's request validation in one place. This page gives operators the two readings that settle exposure (build number and who can reach the RPC port), the crash and connection hunt that works around the missing log line, the refused-write test to run after updating, and the firewall step that closes the path until then. The CVE is not in the CISA KEV catalog read for this page, and no source read here reports attacks in the wild.",
  "status": "published",
  "severity": "critical",
  "confidence": "high",
  "uncertainty": "The affected range rests on the CVE record; HOL confirmed the one-sided check in the code at the record's named commit and read the fix commit's patch, but did not reproduce the write or audit the rewritten server end to end.",
  "firstObservedAt": "2026-11-23T00:00:00.000Z",
  "lastObservedAt": "2026-11-26T00:00:00.000Z",
  "publishedAt": "2026-11-30T10:05:09.053Z",
  "reviewedAt": "2026-11-30T10:03:41.806Z",
  "expiresAt": "2026-11-26T00:00:00.000Z",
  "reviewer": "HOL Guard Security Publishing",
  "sources": [
    {
      "id": "nvd-cve-2026-137567",
      "label": "NVD record for CVE-2026-137567 (VulnCheck CNA, CVSS 3.1 9.8, CVSS 4.0 9.3, CWE-787)",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-137567",
      "sourceType": "vulnerability_database",
      "observedAt": "2026-11-26T00:00:00.000Z"
    },
    {
      "id": "vulncheck-llama-rpc-copy-tensor",
      "label": "VulnCheck advisory: llama.cpp b11450 before b12658 out-of-bounds write via RPC copy_tensor",
      "url": "https://www.vulncheck.com/advisories/llama-cpp-b11450-before-b12658-out-of-bounds-write-via-rpc-copy-tensor",
      "sourceType": "vendor_advisory",
      "observedAt": "2026-11-26T00:00:00.000Z"
    },
    {
      "id": "llama-vulnerable-code-ggml-rpc",
      "label": "Vulnerable ggml-rpc.cpp at commit 46f4da2 (tag b12657): copy_tensor checks the write end against the buffer end and never the destination against the buffer base",
      "url": "https://github.com/ggml-org/llama.cpp/blob/46f4da217419ecac95708600e0f6ebc4bdb91cfd/ggml/src/ggml-rpc/ggml-rpc.cpp",
      "sourceType": "vendor_advisory",
      "observedAt": "2026-11-26T00:00:00.000Z"
    },
    {
      "id": "llama-fix-commit-03813c5",
      "label": "llama.cpp fix commit 03813c56 (pull request 32651, the b12658 tag): typed request helpers and a single validation step on the RPC server",
      "url": "https://github.com/ggml-org/llama.cpp/commit/03813c56e47f6cd7a9b9bc2ad8edcebed88ce342",
      "sourceType": "vendor_advisory",
      "observedAt": "2026-11-23T00:00:00.000Z"
    },
    {
      "id": "cisa-kev",
      "label": "CISA Known Exploited Vulnerabilities catalog, version 2026.11.27 (CVE absent)",
      "url": "https://www.cisa.gov/known-exploited-vulnerabilities-catalog",
      "sourceType": "government",
      "observedAt": "2026-11-27T00:00:00.000Z"
    }
  ],
  "artifacts": [
    {
      "id": "llama-cpp-ggml-rpc-server-b11450-before-b12658",
      "artifactClass": "package",
      "ecosystem": "generic",
      "name": "llama.cpp ggml RPC server (rpc-server), copy_tensor handler in ggml-rpc.cpp",
      "version": "Builds b11450 through b12657; fixed in b12658",
      "defanged": false
    }
  ],
  "indicators": [],
  "timeline": [
    {
      "id": "fix-committed",
      "occurredAt": "2026-11-23T00:00:00.000Z",
      "eventType": "disclosure",
      "summary": "The fix landed on November 23, 2026 as commit 03813c56 through pull request 32651: typed request helpers and a single validation step on the RPC server, with rpc_check_region checking each request against the tensor it names. The commit is the b12658 release tag itself.",
      "sourceIds": [
        "llama-fix-commit-03813c5"
      ]
    },
    {
      "id": "cve-published",
      "occurredAt": "2026-11-26T00:00:00.000Z",
      "eventType": "disclosure",
      "summary": "The CVE record for CVE-2026-137567 was published on November 26, 2026, naming llama.cpp b11450 before b12658, with the VulnCheck CVSS 3.1 score of 9.8, the CVSS 4.0 score of 9.3 and CWE-787.",
      "sourceIds": [
        "nvd-cve-2026-137567",
        "vulncheck-llama-rpc-copy-tensor"
      ]
    },
    {
      "id": "vulnerable-code-read",
      "occurredAt": "2026-11-30T00:00:00.000Z",
      "eventType": "first_observed",
      "summary": "Read in this run on November 30, 2026: the ggml-rpc.cpp code at commit 46f4da2 (tag b12657, the state the record points at) shows copy_tensor checking the write end against the buffer end only, with no comparison of the destination pointer against the buffer base.",
      "sourceIds": [
        "llama-vulnerable-code-ggml-rpc"
      ]
    },
    {
      "id": "kev-absence-read",
      "occurredAt": "2026-11-30T00:00:00.000Z",
      "eventType": "first_observed",
      "summary": "Read in this run on November 30, 2026: the CISA KEV catalog at version 2026.11.27 holds 1,808 entries and no entry for CVE-2026-137567.",
      "sourceIds": [
        "cisa-kev"
      ]
    }
  ],
  "coverage": [
    {
      "assertionId": "guard-evidence-pack",
      "relationship": "provides_evidence",
      "limitation": "The campaign rests on the NVD record for CVE-2026-137567 read firsthand through the NVD API, the VulnCheck advisory page, the vulnerable ggml-rpc.cpp code at commit 46f4da2 (tag b12657) read firsthand, the fix commit 03813c56 read firsthand as a patch, the llama.cpp release tags read firsthand, and the CISA KEV feed, all read firsthand in this run. HOL did not reproduce the flaw."
    }
  ],
  "policies": [
    {
      "policyId": "update-llama-cpp-b12658",
      "purpose": "Update every llama.cpp RPC server host to build b12658 or later, because builds b11450 through b12657 check only the end of a copy_tensor write against the destination buffer's end and never check the destination pointer against the buffer base, so an unauthenticated client that learns the base with BUFFER_GET_BASE can write source bytes below it and crash the server or run code in its process (CVE-2026-137567)",
      "status": "available",
      "limitation": "Hosts already on b12658 or a later build carry the fix; the policy names the first fixed build from the record and the tag line."
    }
  ],
  "limitations": [
    "The flaw needs a network path to the RPC server's port; a server reachable only by its one trusted client machine gives an outside attacker no way in.",
    "The successful below-base write leaves no log line in the vulnerable code, because the log fires only on the upper-bound refusal the attack passes; detection works from crash, restart and connection records.",
    "No exploitation in the wild is reported by any source read for this page, and the CVE is absent from the CISA KEV catalog version read in this run.",
    "Builds before b11450 are outside the record's stated range and this page makes no claim about them."
  ],
  "correctionHref": "/guard/security/campaigns/cve-2026-137567-llama-cpp-rpc-server-out-of-bounds-write/corrections"
}
