PyTorch-Lightning versions 2.6.0 and earlier contain an insecure deserialization vulnerability (CWE-502) in the checkpoint loading mechanism. The LightningModule.load_from_checkpoint() method, which is commonly used to load saved model states, internally calls torch.load() without setting the security-restrictive weights_only=True parameter. This default behavior allows the deserialization of arbitrary Python objects via the Pickle module. A remote attacker can exploit this by providing a maliciously crafted checkpoint file, leading to arbitrary code execution on the victim's system when the file is loaded.
CVE-2026-31221
Score 7.8 from GitHub Security Advisory (severity: HIGH) published 2026-05-12. NVD baseline CVSS 7.8; sources differ by 0.0.
- High severity, but no confirmed exploitation yet
No vendor fix yet — apply a workaround or compensating control (WAF / firewall / segmentation) and watch for a patch.
- CVSS v3
- 7.8
- EG Score
- 7.8(medium)
- EG Risk
- 35(Track)EG Risk 35/100SSVC: Track
EG Risk is EchelonGraph's 0–100 priority score: it fuses intrinsic severity with real-world exploitation and automatability so you can rank equal-severity CVEs and fix the most dangerous first. Higher = act sooner. Distinct from the 0–10 EG Score (severity).
How it’s computedSeverity78% × 45%Exploitation0% × 40%Automatability0% × 15%Action: Routine — remediate on your standard cadence. - EPSS PROB
- 0%
- EPSS %ILE
- 31%
- KEV
- Not listed
Published
May 12, 2026
Last Modified
May 15, 2026
Advisory Details (2)
Auto-updated May 14, 2026GitHub - Lightning-AI/pytorch-lightning: Pretrain, finetune ANY AI model of ANY size on 1 or 10,000+ GPUs with zero code changes. · GitHub
https://github.com/Lightning-AI/pytorch-lightningVendor Advisories for CVE-2026-31221(1)
These vendors published their own advisory mentioning this CVE — often with vendor-specific remediation steps + affected product lists not in NVD.
Patch Availability(1)
| Vendor / Ecosystem | Fixed in / Patch | Released | Source |
|---|---|---|---|
| pip | pytorch-lightning | — | ghsa |
Patches are aggregated from vendor advisories (Red Hat, Microsoft, Cisco, GitHub) and package ecosystems (OSV, GHSA). Multiple rows for the same upstream release have been deduplicated.
Affected Packages
(1 across 1 ecosystem)
PyPI(1)
| Package | Vulnerable range | Fixed in | Dependents |
|---|---|---|---|
| pytorch-lightning | 0.0.2 ... 2.6.0.dev0 (219 versions) | — | — |
Weakness Classification(1)
MITRE Common Weakness Enumeration — the root-cause categories this CVE belongs to.
Data Freshness Timeline
(refreshed 9× in last 7d / 66× in last 30d)
Each row is a source pipeline that fetched or updated this CVE on that date, with what changed. For example, "NVD update" means NVD published or revised its analysis for this CVE; "MITRE cvelistV5" means we ingested or refreshed it from the CNA feed. Most recent first.
Showing the most recent 100 of 215 total refreshes for this CVE.
- 2026-08-26 14:46 UTCEPSS rescore
- 2026-08-25 13:49 UTCEPSS rescore
- 2026-08-24 14:17 UTCEPSS rescore
- 2026-08-23 18:25 UTCEG score recompute
- 2026-08-23 18:25 UTCGHSA enrichment
- 2026-08-23 00:19 UTCEPSS rescore
- 2026-08-21 23:49 UTCEPSS rescore
- 2026-08-20 22:55 UTCEPSS rescore
- 2026-08-20 22:55 UTCEPSS rescore
- 2026-08-19 17:03 UTCEPSS rescore
- 2026-08-18 13:48 UTCEPSS rescore
- 2026-08-17 13:47 UTCEPSS rescore
- 2026-08-17 10:55 UTCEG score recompute
- 2026-08-17 10:55 UTCGHSA enrichment
- 2026-08-16 14:56 UTCEPSS rescore
- 2026-08-16 04:17 UTCEG score recompute
- 2026-08-16 04:17 UTCGHSA enrichment
- 2026-08-16 02:14 UTCEPSS rescore
- 2026-08-15 01:30 UTCEPSS rescore
- 2026-08-14 14:46 UTCGHSA enrichment
- 2026-08-14 02:48 UTCEG score recompute
- 2026-08-14 02:48 UTCGHSA enrichment
- 2026-08-13 22:00 UTCEPSS rescore
- 2026-08-13 04:15 UTCGHSA enrichment
- 2026-08-12 16:17 UTCEG score recompute
Show 75 moreShow fewer
- 2026-08-12 16:17 UTCGHSA enrichment
- 2026-08-12 13:50 UTCEPSS rescore
- 2026-08-11 15:43 UTCEG score recompute
- 2026-08-11 15:43 UTCGHSA enrichment
- 2026-08-11 01:58 UTCEG score recompute
- 2026-08-11 01:58 UTCGHSA enrichment
- 2026-08-11 00:00 UTCEPSS rescore
- 2026-08-10 14:00 UTCGHSA enrichment
- 2026-08-10 02:02 UTCGHSA enrichment
- 2026-08-09 14:05 UTCEG score recompute
- 2026-08-09 14:05 UTCGHSA enrichment
- 2026-08-09 13:46 UTCEPSS rescore
- 2026-08-09 02:07 UTCEG score recompute
- 2026-08-09 02:07 UTCGHSA enrichment
- 2026-08-08 16:37 UTCEPSS rescore
- 2026-08-08 13:26 UTCGHSA enrichment
- 2026-08-08 01:27 UTCEG score recompute
- 2026-08-08 01:27 UTCGHSA enrichment
- 2026-08-07 13:29 UTCGHSA enrichment
- 2026-08-07 01:31 UTCEG score recompute
- 2026-08-07 01:31 UTCGHSA enrichment
- 2026-08-06 13:46 UTCEPSS rescore
- 2026-08-06 09:58 UTCGHSA enrichment
- 2026-08-05 21:51 UTCEG score recompute
- 2026-08-05 21:51 UTCGHSA enrichment
- 2026-08-05 19:17 UTCEPSS rescore
- 2026-08-04 15:10 UTCEPSS rescore
- 2026-08-04 10:38 UTCEPSS rescore
- 2026-08-03 19:17 UTCEG score recompute
- 2026-08-03 19:17 UTCGHSA enrichment
- 2026-08-03 10:36 UTCEPSS rescore
- 2026-08-02 23:29 UTCGHSA enrichment
- 2026-08-02 11:31 UTCEG score recompute
- 2026-08-02 11:30 UTCGHSA enrichment
- 2026-08-02 02:26 UTCEPSS rescore
- 2026-08-01 23:32 UTCEG score recompute
- 2026-08-01 23:32 UTCGHSA enrichment
- 2026-08-01 04:16 UTCEPSS rescore
- 2026-07-30 16:27 UTCEPSS rescore
- 2026-07-30 01:30 UTCEPSS rescore
- 2026-07-28 15:36 UTCEPSS rescore
- 2026-07-26 14:54 UTCEPSS rescore
- 2026-07-26 14:54 UTCEPSS rescore
- 2026-07-25 14:18 UTCEPSS rescore
- 2026-07-25 14:17 UTCEPSS rescore
- 2026-07-24 14:17 UTCEPSS rescore
- 2026-07-23 14:18 UTCEPSS rescore
- 2026-07-23 14:18 UTCEPSS rescore
- 2026-07-23 03:08 UTCEG score recompute
- 2026-07-22 14:08 UTCEPSS rescore
- 2026-07-22 14:08 UTCEPSS rescore
- 2026-07-21 15:24 UTCEPSS rescore
- 2026-07-21 15:24 UTCEPSS rescore
- 2026-07-20 17:08 UTCEPSS rescore
- 2026-07-20 17:08 UTCEPSS rescore
- 2026-07-19 14:31 UTCEPSS rescore
- 2026-07-19 14:31 UTCEPSS rescore
- 2026-07-19 02:29 UTCEPSS rescore
- 2026-07-18 10:04 UTCEPSS rescore
- 2026-07-18 10:04 UTCEPSS rescore
- 2026-07-16 17:03 UTCEPSS rescore
- 2026-07-16 17:03 UTCEPSS rescore
- 2026-07-16 02:19 UTCOSV refresh
- 2026-07-15 16:57 UTCEPSS rescore
- 2026-07-15 16:57 UTCEPSS rescore
- 2026-07-15 02:00 UTCEPSS rescore
- 2026-07-15 02:00 UTCEPSS rescore
- 2026-07-13 22:30 UTCEPSS rescore
- 2026-07-13 06:13 UTCEPSS rescore
- 2026-07-13 06:13 UTCEPSS rescore
- 2026-07-12 05:46 UTCEPSS rescore
- 2026-07-11 08:27 UTCEPSS rescore
- 2026-07-09 19:10 UTCEPSS rescore
- 2026-07-08 15:15 UTCEPSS rescore
- 2026-07-07 13:46 UTCEPSS rescore
Related CVEs(same product + same CWE)
Same CWE
10 shownCWE-502
- CVE-2017-10992EG 9.8EPSS p95CRITICAL
- CVE-2013-4521EG 9.8EPSS p90CRITICAL
- CVE-2014-1860EG 9.8CRITICAL
- CVE-2016-1000027EG 9.8EPSS p98CRITICAL
- CVE-2014-3699EG 9.8CRITICAL
- CVE-2017-10934EG 9.8CRITICAL
- CVE-2016-9498EG 9.8EPSS p97CRITICAL
- CVE-2016-9483EG 9.8CRITICAL
- CVE-2015-2020EG 9.8CRITICAL
- CVE-2017-15692EG 9.8EPSS p91CRITICAL
Frequently asked(5)
What is CVE-2026-31221?
When was CVE-2026-31221 disclosed?
Is CVE-2026-31221 actively exploited?
What is the CVSS score of CVE-2026-31221?
How do I remediate CVE-2026-31221?
Dependency Blast Radius
See which npm, PyPI, Go, and Maven packages are affected by CVE-2026-31221
Is Your Infrastructure Affected by CVE-2026-31221?
EchelonGraph automatically scans your cloud infrastructure and maps CVE exposure using blast radius analysis.