CVE-2024-5452
CRITICAL 9.8CVSS 3.1Remote code execution in pytorch lightning
A remote code execution (RCE) vulnerability exists in the lightning-ai/pytorch-lightning library version 2.2.1 due to improper handling of deserialized user input and mismanagement of dunder attributes by the deepdiff library. The library uses deepdiff.Delta objects to modify application state based on frontend actions. However, it is possible to bypass the intended restrictions on modifying dunder attributes, allowing an attacker to construct a serialized delta that passes the deserializer whitelist and contains dunder attributes. When processed, this can be exploited to access other modules, classes, and instances, leading to arbitrary attribute write and total RCE on any self-hosted pytorch-lightning application in its default configuration, as the delta endpoint is enabled by default.
- Published
- 6 Jun 2024
- Last modified
- 16 Nov 2026
- Assigned by
- security@huntr.dev
- NVD status
- Modified
- Weakness
- CWE-913CWE-915
- Also known as
- GHSA-cgwc-qvrx-rf7fPYSEC-2026-385PYSEC-2026-3974
- Sources
- NVDJSONOSV GHSA-cgwc-qvrx-rf7fJSONOSV PYSEC-2026-385JSONOSV PYSEC-2026-3974JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | CRITICAL 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVD | security@huntr.dev (Secondary) | CVSS 3.0 | CRITICAL 9.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| OSV | GitHub | CVSS 3.0 | CRITICAL 9.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| OSV | PyPA | CVSS 3.0 | CRITICAL 9.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | lightningai | pytorch_lightningcpe:2.3:a:lightningai:pytorch_lightning:*:*:*:*:*:python:*:* |
< 2.3.3 | 2.3.3 |
| OSV | PyPI | lightning | < 2.3.3 | 2.3.3 |
| OSV | PyPI | pytorch-lightning | < 2.3.3 | 2.3.3 |
References
- https://github.com/lightning-ai/pytorch-lightning/commit/330af381de88cff17515418a341cbc1f9f127f9a · WEB
- https://huntr.com/bounties/486add92-275e-4a7b-92f9-42d84bc759da · Exploit, Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2024-5452 · ADVISORY
- https://github.com/Lightning-AI/pytorch-lightning/issues/20038 · WEB
- https://github.com/Lightning-AI/pytorch-lightning/releases/tag/2.3.3 · WEB
- https://github.com/advisories/GHSA-cgwc-qvrx-rf7f · ADVISORY
- https://github.com/lightning-ai/pytorch-lightning · PACKAGE
- https://github.com/pypa/advisory-database/tree/main/vulns/lightning/PYSEC-2026-385.yaml · WEB
- https://github.com/pypa/advisory-database/tree/main/vulns/pytorch-lightning/PYSEC-2026-3974.yaml · WEB
- https://pypi.org/project/lightning · WEB, PACKAGE
History
- 25 Nov 2026 20:55 UTC · NVD: first stored (published 6 Jun 2024)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 29 Jun 2026)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 10 Sep 2026)
- 25 Nov 2026 20:11 UTC · OSV: first stored (published 6 Jun 2024)