CVE-2024-8019CWE-434

Arbitrary File Write/Overwrite in lightning-ai/pytorch-lightning

Critical · published March 20, 2025

CVSS v3.0
9.1
EPSS
1%
Percentile
65.9
In the wild
Unconfirmed
What it is

🚨 The upload endpoint in lightning-ai's PyTorch Lightning is a ticking time bomb! An attacker can craft a filename to overwrite any file they want, and that could lead to full remote code execution. 🔥 Think of it like a restaurant where the chef has left the back door wide open for anyone to walk in and swap the ingredient list. A rogue could easily replace critical items, or worse, slip in something hazardous without anyone noticing! If an attacker exploits this vulnerability, they could overwrite essential files or introduce malicious code, leading to absolute chaos on your servers. This means they could gain control of the application, access sensitive data, or even bring down your entire service!

Put simply

Think of it like a restaurant where the chef has left the back door wide open for anyone to walk in and swap the ingredient list. A rogue could easily replace critical items, or worse, slip in something hazardous without anyone noticing! This vulnerability allows an attacker to manipulate the filename when uploading files to the `/api/v1/upload_file/` endpoint in PyTorch Lightning version 2.3.2 on Windows, leading to the potential for remote code execution.

What to do

If an attacker exploits this vulnerability, they could overwrite essential files or introduce malicious code, leading to absolute chaos on your servers. This means they could gain control of the application, access sensitive data, or even bring down your entire service! Immediate action is critical! Upgrade to version 2.3.3 or later to patch this vulnerability. Additionally, review your file handling practices to ensure proper validation and sanitization of filenames to prevent similar issues in the future. You've got this! By acting swiftly, you'll lock down your systems and keep those pesky attackers at bay. 🛡️

The record
Technical detail
CVSS v3.0
9.1 · CRITICAL
Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
CVSS v4.0
Not supplied
EPSS
0.01122 · 65.9th percentile
Weakness
CWE-434 · Unrestricted Upload of File with Dangerous Type
Published
2025-03-20T10:08Z
EPSS history
Timeline
  • 20 MAR 10:08Z
    Arbitrary File Write/Overwrite in lightning-ai/pytorch-lightning
    cvelistv5