HighVulnerability
CVE-2026-58659: PyTorch Lightning remote code execution via checkpoint _instantiator
- Source
- NVD(opens in a new tab)
- Identifier
- CVE-2026-58659
- Published
- Record updated
- Affected
- lightning < 2.6.6
- Fixed in
- 2.6.6
- Known exploitation
- Not listed in the CISA Known Exploited Vulnerabilities catalog at the last check.
- EPSS
- 0.6%
Summary
CVE-2026-58659 affects PyTorch Lightning through 2.6.5, fixed in commit d710d68. The _load_state function imports and executes attacker-controlled module names taken from checkpoint _instantiator hyperparameters. A crafted checkpoint that bypasses weights_only=True can run arbitrary code when LightningModule.load_from_checkpoint is called.
Mitigation
Fixed in commit d710d68.
Affected packages in the Exposure Registry
Matched by package name and ecosystem. Each entry shows whether the package delegates to a language model and how many tracked packages depend on it.
- lightningPyPILLM dependency since 2025-10-26 · 3 tracked dependents
Related items
- MediumOver 1,500 npm packages exposed by Trusted Publishing validation flawSimilar attack · CSO Online
- MediumCVE-2026-108958: TensorLayer HDF5 model loading deserialization via model_config argumentSimilar attack · NVD/CVE Database
- InfoHow to Secure AI Models in Production Environments | Endor LabsSimilar attack · Endor Labs Blog
- InfoWhat Does It Mean to Sandbox an AI Coding Agent? | Endor LabsSimilar attack · Endor Labs Blog
- InfoIntroducing Security for AI Coding Agents and Workstations | Endor LabsSimilar attack · Endor Labs Blog