Skip to main content

SentencePiece CVE-2026-1260

HIGH
Buffer Overflow (CWE-119)
2026-01-22 cve-coordination@google.com GHSA-38vq-g6vr-w8wf
8.5
CVSS 4.0 · Vendor: google
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Craft malformed SentencePiece model file
  2. Delivery
    Distribute via model hub or upload
  3. Exploit
    Victim loads model in app
  4. Execution
    Trigger invalid memory access in parser
  5. Persist
    Corrupt memory / crash or execute code
  6. Impact
    Impact host process integrity and availability

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A06:2021 - Vulnerable and Outdated Components
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, buffer size validation
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Privilege Escalation

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the victim application to load a specially crafted SentencePiece model file that was NOT produced by the normal spm_train training procedure - i.e., a deliberately malformed .model artifact whose internal structure deviates from legitimately trained models. The CVSS 4.0 vector (AV:L, UI:P) confirms the trigger is local file loading with passive user interaction, not a network-facing entry point. Limiting factors that reduce realistic risk: the attacker must deliver the hostile model and get a user/process to load it (so environments that only load self-trained or signed/trusted models are effectively not exposed); there is no remote unauthenticated path, no actively exploited status (not in CISA KEV), EPSS is 0.00%, and no POC is referenced. The condition that materially matters for defenders is whether the deployment ingests third-party, user-uploaded, or unverified tokenizer models.

Impact

Signals are mixed and should be read carefully. The vendor CVSS 4.0 vector (AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H, score 8.5) describes a local attack vector requiring passive user interaction (loading the model) with high impact to confidentiality, integrity, and availability - high severity but NOT remote-unauthenticated. EPSS is 0.00% (0th percentile), there is no CISA KEV listing, and no POC is referenced, so there is no evidence of opportunistic mass exploitation. The realistic risk is therefore a supply-chain/untrusted-artifact problem: it matters specifically where applications ingest third-party or user-uploaded tokenizer models. Note the apparent tension between PR:N (no privileges) and the requirement to deliver a crafted file plus user interaction - the effective barrier to exploitation is social/distribution (getting the victim to load a hostile model), not authentication. Red Hat shipping RHSA-2026:3782 and RHSA-2026:3713 indicates the library is redistributed inside enterprise products, which broadens exposure even though standalone deployment is niche.

Exploit ScenarioDerived

An attacker publishes a poisoned SentencePiece .model file to a model hub, shared repository, or sends it directly, and a developer or service loads it into an application linked against SentencePiece < 0.2.1. Loading the crafted model triggers the invalid memory access (CWE-119), crashing the process or, given the high integrity/availability impact rating, potentially enabling code execution in the application's context. No public exploit is identified at time of analysis, and the local attack vector with required user interaction means delivery relies on convincing the victim to load the malicious model.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv5 – Jun 30, 2026

Memory-corruption in Google's SentencePiece tokenizer library (all versions before 0.2.1) lets a maliciously crafted model file trigger an invalid memory access (CWE-119) when the file is loaded, potentially leading to crashes or arbitrary code execution in the host process. Exploitation requires a victim to load an attacker-supplied model that was deliberately built outside the normal training pipeline, so it is not remotely triggerable on its own. No public exploit identified at time of analysis, and EPSS is 0.00%, but the flaw was reported by Google and is patched in v0.2.1.

Earlier versions of this analysis (4)
v4 Jun 30, 2026 - 05:57 cvss changed CVSS 8.5

Memory corruption in Google SentencePiece versions prior to 0.2.1 allows an attacker to trigger an out-of-bounds memory access by tricking a victim into loading a maliciously crafted model file that was not produced by the normal training procedure. SentencePiece is a widely embedded text tokenization library used across machine-learning and LLM pipelines, so successful exploitation could lead to crashes or potential code execution in any application that ingests untrusted model files. No public exploit identified at time of analysis, and EPSS exploitation probability is effectively 0%, but a vendor patch (v0.2.1) is available.

v3 Jun 30, 2026 - 05:56 cvss changed CVSS 8.5

Memory corruption in Google's SentencePiece tokenization library (all versions before 0.2.1) lets an attacker trigger an invalid memory access by supplying a maliciously crafted model file that was not produced through the normal training procedure. When such a file is loaded, the out-of-bounds access (CWE-119) can corrupt memory and potentially lead to arbitrary code execution within the host process. No public exploit identified at time of analysis; EPSS is 0.00% and the issue is not in CISA KEV, but a vendor patch (v0.2.1) and Red Hat errata are available.

v2 Jun 30, 2026 - 05:56 cvss changed CVSS 8.5

Memory-corruption (CWE-119, out-of-bounds access) in Google's SentencePiece tokenizer library before version 0.2.1 lets a maliciously crafted model file trigger invalid memory access when loaded by an application, with high impact to confidentiality, integrity, and availability (CVSS 4.0 8.5). The malicious model is not producible through normal training and must be supplied to the victim, so exploitation requires the application to load an attacker-controlled .model file (UI:P). There is no public exploit identified at time of analysis, EPSS is 0.00%, and the issue is not on CISA KEV, so risk is currently theoretical but the buffer-bounds flaw is patch-confirmed.

v1 Mar 12, 2026 - 21:54 CVSS 7.8

Invalid memory access in Sentencepiece versions less than 0.2.1 when using a vulnerable model file, which is not created in the normal training procedure. [CVSS 7.8 HIGH]

RemediationAI

Vendor-released patch: 0.2.1 - upgrade SentencePiece to v0.2.1 or later (https://github.com/google/sentencepiece/releases/tag/v0.2.1), and for Red Hat-based systems apply the packages from RHSA-2026:3782 and RHSA-2026:3713 rather than relying on pip alone, since the library is bundled in distro/product builds. Because exploitation depends on loading an attacker-controlled model file, the most effective compensating control where immediate patching is not possible is to treat tokenizer model files as untrusted input: only load .model files from trusted, integrity-verified sources (pin checksums/signatures of known-good models), and reject or sandbox any user-supplied or third-party-downloaded models. If your application accepts uploaded models, isolate the deserialization/tokenizer load in a low-privilege, resource-limited sandbox or separate process so a crash or memory-corruption cannot compromise the main service - the trade-off is added IPC/latency and operational complexity. Avoid loading models from model hubs or shared storage without provenance checks until upgraded.

Affected Packages

pypi sentencepiece fix: 0.2.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

SentencePiece is Google's open-source unsupervised text tokenizer/detokenizer (BPE and unigram models) embedded in many NLP and LLM pipelines to serialize and deserialize trained tokenizer models, typically via protobuf-backed .model files. The CPE cpe:2.3:a:google:sentencepiece:*:*:*:*:*:*:*:* confirms the affected component is the SentencePiece application/library itself. The root cause is CWE-119 (improper restriction of operations within the bounds of a memory buffer): when parsing a model file whose internal fields/offsets are malformed in a way the legitimate training procedure would never produce, the deserialization code performs an out-of-bounds or otherwise invalid memory access. This is a classic untrusted-deserialization buffer-handling bug rather than a flaw in tokenization logic for normal inputs.

Know when Sentencepiece gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (google) PRIMARY 8.5 HIGH
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
vuln.today AI 7.8 HIGH

Trigger is loading a local malicious model file (AV:L) requiring victim action (UI:R) with no prior auth (PR:N); memory corruption yields high C/I/A within the unchanged process scope.

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
4.0 AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Red Hat 7.8 HIGH

Primary rating from Vendor (google).

CVSS VectorVendor: google

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

7
Analysis Updated
Jun 30, 2026 - 06:00 vuln.today
v5 - CVSS changed
Analysis Updated
Jun 30, 2026 - 05:57 vuln.today
v4 - CVSS changed
Analysis Updated
Jun 30, 2026 - 05:56 vuln.today
v3 - CVSS changed
Analysis Updated
Jun 30, 2026 - 05:56 vuln.today
v2 - CVSS changed
CVSS changed
Jun 30, 2026 - 03:23 NVD
7.8 (HIGH) 8.5 (HIGH)
Patch released
Mar 31, 2026 - 21:13 nvd
Patch available
CVE Published
Jan 22, 2026 - 17:16 nvd
HIGH 7.8

DescriptionCVE.org

Invalid memory access in Sentencepiece versions less than 0.2.1 when using a vulnerable model file, which is not created in the normal training procedure.

Executive ViewAI

Why It Matters

Google's SentencePiece tokenizer library (versions before 0.2.1) contains a memory-corruption flaw that could crash production NLP systems or enable code execution if malicious model files are loaded into applications. Organizations using SentencePiece for chatbots, language models, or text-processing pipelines should prioritize patching to prevent potential service disruption and code execution in production environments.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.0%
Top 100% exploitable
Prevalence
Medium
widely-used NLP/LLM tokenizer library, but ML-specific rather than universal
Data Quality
6 sources
Confidence: High
NVD CVE.org EPSS Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact
High

Priority Score

42
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +42
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Affected Products (CPE)CVE.org

cpe:2.3:a:google:sentencepiece:*:*:*:*:*:*:*:*

Vendor StatusVendor

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy