Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-31221: n/a

0
Unknown
VulnerabilityCVE-2026-31221cvecve-2026-31221
Published: Tue May 12 2026 (05/12/2026, 00:00:00 UTC)
Source: CVE Database V5

Description

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.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 05/12/2026, 16:07:50 UTC

Technical Analysis

The vulnerability in PyTorch-Lightning (≤ 2.6.0) arises from the load_from_checkpoint() method calling torch.load() without the security-restrictive parameter weights_only=True. This omission allows deserialization of arbitrary Python objects via Pickle, leading to potential arbitrary code execution if a malicious checkpoint file is loaded. The issue is a classic insecure deserialization flaw (CWE-502) in the model checkpoint loading process. No CVSS score or official remediation is currently published.

Potential Impact

An attacker able to provide a malicious checkpoint file to a victim loading it with load_from_checkpoint() can execute arbitrary code on the victim's system. This could lead to full system compromise depending on the environment and privileges of the process loading the checkpoint. The vulnerability is local to the environment loading the checkpoint and requires attacker control or influence over the checkpoint file source.

Mitigation Recommendations

Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is available, users should avoid loading checkpoint files from untrusted or unauthenticated sources. Consider manually inspecting checkpoint files or using alternative safe loading mechanisms if possible.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
mitre
Date Reserved
2026-03-09T00:00:00.000Z
Cvss Version
null
State
PUBLISHED
Remediation Level
null

Threat ID: 6a034c84cbff5d8610fe99e6

Added to database: 5/12/2026, 3:51:32 PM

Last enriched: 5/12/2026, 4:07:50 PM

Last updated: 5/13/2026, 4:48:18 AM

Views: 6

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses