Description
Stanza is a Stanford NLP Python library for tokenization, sentence segmentation, NER, and parsing of many human languages. Prior to 1.12.2, Stanza model loaders such as stanza.models.common.pretrain.Pretrain.load() attempt torch.load(..., weights_only=True) but fall back to torch.load(..., weights_only=False) on attacker-controllable pickle.UnpicklingError, allowing a malicious .pt pretrain or model file to execute arbitrary pickle code when a Stanza NLP pipeline loads it. This issue is fixed in version 1.12.2.
Published: 2026-07-08
Score: 7.5 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Stanza is a Stanford NLP Python library for tokenization, sentence segmentation, named‑entity recognition, and parsing across many languages. In versions before 1.12.2, the model loader stanza.models.common.pretrain.Pretrain.load() calls torch.load with weights_only=True, but if an attacker‑controlled pickle.UnpicklingError occurs, it falls back to torch.load with weights_only=False. This allows a malicious .pt pretrain or model file to execute arbitrary pickle code during pipeline loading. The vulnerability results in remote code execution by the user running the pipeline and is fixed in version 1.12.2, classified as CWE‑502 and CWE‑676.

Affected Systems

The flaw affects any Stanza release prior to 1.12.2 when loading pre‑trained models via stanza.models.common.pretrain.Pretrain.load(). Users who install older versions and load models from untrusted or malicious sources are at risk.

Risk and Exploitability

The CVSS score of 7.5 indicates a high severity for this flaw, and the EPSS score is < 1%. The vulnerability is not listed in the CISA KEV catalog. The attack vector is inferred to be the loading of a malicious model file, which can be supplied locally or remotely if the pipeline processes user‑provided files. Successful exploitation would allow the attacker to run arbitrary code with the privileges of the process that instantiates the Stanza pipeline.

Generated by OpenCVE AI on July 29, 2026 at 13:04 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Apply the official patch to Stanza 1.12.2 or later, which removes the insecure pickle deserialization fallback (CWE‑502).
  • Restrict model file usage to authenticated or signed sources and enforce directory access controls to prevent arbitrary code execution (CWE‑676).
  • If upgrading is not possible, perform runtime isolation of the Python process or use containerization to limit permissions.

Generated by OpenCVE AI on July 29, 2026 at 13:04 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-v5jw-96jm-7h2c Stanza: Remote Code Execution via Unsafe Pickle Deserialization in Model Loaders
History

Fri, 10 Jul 2026 10:15:00 +0000

Type Values Removed Values Added
First Time appeared Stanfordnlp
Stanfordnlp stanza
Vendors & Products Stanfordnlp
Stanfordnlp stanza

Thu, 09 Jul 2026 14:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Thu, 09 Jul 2026 12:15:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

threat_severity

Important


Wed, 08 Jul 2026 22:30:00 +0000

Type Values Removed Values Added
Description Stanza is a Stanford NLP Python library for tokenization, sentence segmentation, NER, and parsing of many human languages. Prior to 1.12.2, Stanza model loaders such as stanza.models.common.pretrain.Pretrain.load() attempt torch.load(..., weights_only=True) but fall back to torch.load(..., weights_only=False) on attacker-controllable pickle.UnpicklingError, allowing a malicious .pt pretrain or model file to execute arbitrary pickle code when a Stanza NLP pipeline loads it. This issue is fixed in version 1.12.2.
Title Stanza: Remote Code Execution via Unsafe Pickle Deserialization in Model Loaders
Weaknesses CWE-502
CWE-676
References
Metrics cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H'}


Subscriptions

Stanfordnlp Stanza
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-07-09T13:13:28.368Z

Reserved: 2026-06-15T18:01:15.511Z

Link: CVE-2026-54499

cve-icon Vulnrichment

Updated: 2026-07-09T13:13:04.169Z

cve-icon NVD

No data.

cve-icon Redhat

Severity : Important

Publid Date: 2026-07-08T22:23:02Z

Links: CVE-2026-54499 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-07-29T13:15:05Z

Weaknesses
  • CWE-502

    Deserialization of Untrusted Data

  • CWE-676

    Use of Potentially Dangerous Function