{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-70659","id":"CVE-2026-70659","title":"stable-diffusion.cpp out-of-bounds write in imatrix loading","description":"stable-diffusion.cpp is a pure C/C++ library for running diffusion model (Stable Diffusion, Flux, Wan, Qwen Image, Z-Image, and more) inference. From master-742-1a13107 until master-763-4fcc6fe, IMatrixCollector::load_imatrix in src/runtime/imatrix.cpp reuses the values and counts vectors for entries with the same tensor name but resizes them only when they are empty. An untrusted .imatrix file ca","descriptionLong":"stable-diffusion.cpp is a pure C/C++ library for running diffusion model (Stable Diffusion, Flux, Wan, Qwen Image, Z-Image, and more) inference. From master-742-1a13107 until master-763-4fcc6fe, IMatrixCollector::load_imatrix in src/runtime/imatrix.cpp reuses the values and counts vectors for entries with the same tensor name but resizes them only when they are empty. An untrusted .imatrix file can provide a small nval for the first entry and a larger nval for a second entry with the same name, causing the accumulation loop to write attacker-controlled floating-point and integer values beyond both heap buffers. Loading the file through the --imat-in conversion path can corrupt the heap or crash the process before a model is required. This issue is fixed in master-763-4fcc6fe.","published":"2026-11-05T15:26:33.019Z","updated":"2026-11-14T07:06:08.573312831Z","reserved":"2026-08-04T21:48:08.613Z","status":"Awaiting Analysis","rejected":false,"assigner":"GitHub_M","metric":{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","rating":"high","source":"GitHub_M"},"metrics":[{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","rating":"high","source":"GitHub_M"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","rating":"high","source":"github.com"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","rating":"high","source":"OSV"}],"rating":"high","products":["leejet stable-diffusion.cpp"],"affectedProducts":[{"vendor":"leejet","product":"stable-diffusion.cpp","defaultStatus":null,"versions":[{"version":"< master-763-4fcc6fe","status":"affected"}],"platforms":[]}],"packages":[],"cwes":["CWE-787","CWE-1284"],"aliases":["GHSA-6q7q-2v9c-x8m7"],"references":[{"url":"https://github.com/leejet/stable-diffusion.cpp/security/advisories/GHSA-6q7q-2v9c-x8m7","tags":["x_refsource_CONFIRM","advisory"]},{"url":"https://github.com/leejet/stable-diffusion.cpp/pull/1750","tags":["x_refsource_MISC","fix"]},{"url":"https://github.com/leejet/stable-diffusion.cpp/commit/4fcc6fef10c6f686801c6e257b22cd6a3deb906b","tags":["x_refsource_MISC","fix"]},{"url":"https://github.com/leejet/stable-diffusion.cpp/releases/tag/master-763-4fcc6fe","tags":["x_refsource_MISC","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/70xxx/CVE-2026-70659.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-70659","tags":["advisory"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"total"},"epss":0.00128,"epssPercentile":0.02502,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-70659","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-70659","ok":true,"note":"Awaiting Analysis"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-70659","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-70659","ok":true,"note":"scored 2026-11-19"}],"aiTitle":true,"tech":[],"critical":[],"attention":null}