{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-85670","id":"CVE-2026-85670","title":"tokenizers BpeBuilder Buffer Overflow via merge token","description":"tokenizers (Hugging Face) is affected by an out-of-bounds buffer access in BpeBuilder::build (tokenizers/src/models/bpe/model.rs). When loading a tokenizer.json via Tokenizer::from_file/from_str, the builder sizes a scratch buffer to the longest vocabulary key, then writes each concatenated merge rule into it. A merge whose concatenated token exceeds the longest vocabulary key overruns the buffer,","descriptionLong":"tokenizers (Hugging Face) is affected by an out-of-bounds buffer access in BpeBuilder::build (tokenizers/src/models/bpe/model.rs). When loading a tokenizer.json via Tokenizer::from_file/from_str, the builder sizes a scratch buffer to the longest vocabulary key, then writes each concatenated merge rule into it. A merge whose concatenated token exceeds the longest vocabulary key overruns the buffer, which Rust turns into a panic that aborts the process in Rust and FFI embeddings. This occurs at load time with no encoding required, so an attacker who supplies a crafted tokenizer.json can cause a denial of service. A secondary defect at the same location can cause a usize underflow (panic in debug, potential memory corruption in release) when continuing_subword_prefix is set and a merge token is shorter than the prefix. Observed in version 0.23.1.","published":"2026-09-04T14:32:25.391Z","updated":"2026-10-28T02:30:33.192603323Z","reserved":"2026-09-04T13:32:36.617Z","status":"Awaiting Analysis","rejected":false,"assigner":"VulnCheck","metric":{"version":"4.0","score":7.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","rating":"high","source":"VulnCheck"},"metrics":[{"version":"4.0","score":7.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","rating":"high","source":"VulnCheck"},{"version":"4.0","score":7.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","rating":"high","source":"vulncheck.com"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","rating":"unrated","source":"OSV"},{"version":"3.1","score":6.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H","rating":"medium","source":"VulnCheck"},{"version":"3.1","score":6.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H","rating":"medium","source":"vulncheck.com"}],"rating":"high","products":["huggingface tokenizers"],"affectedProducts":[{"vendor":"huggingface","product":"tokenizers","defaultStatus":"unaffected","versions":[{"version":"0","lessThanOrEqual":"0.23.2","status":"affected","versionType":"semver"}],"platforms":[]}],"packages":[],"cwes":["CWE-787"],"aliases":[],"references":[{"url":"https://github.com/huggingface/tokenizers/issues/2094","tags":["issue-tracking","exploit","report"]},{"url":"https://github.com/huggingface/tokenizers","tags":["product","package"]},{"url":"https://github.com/huggingface/tokenizers/blob/v0.23.2/tokenizers/src/models/bpe/model.rs","tags":["technical-description","article"]},{"url":"https://www.vulncheck.com/advisories/tokenizers-bpebuilder-buffer-overflow-via-merge-token","tags":["third-party-advisory","advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/85xxx/CVE-2026-85670.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-85670","tags":["advisory"]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":true,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial"},"epss":0.00467,"epssPercentile":0.41127,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-85670","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-85670","ok":true,"note":"Awaiting Analysis"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-85670","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-85670","ok":true,"note":"scored 2026-11-18"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}