CVE-2025-32434Critical▾ AbyssalPoC availablePyTorch: `torch.load` with `weights_only=True` leads to remote code execution
▾ Abyssal zone — Critical with a public exploit or in-the-wild use
impact 52.3 · likelihood 0.4 · exploitation 12
A public proof-of-concept already exists for this vulnerability — see Exploit availability below.
Public exploit / PoC code seen in 1 source. Availability, not in-the-wild use.
Exploit-prediction probability, daily snapshots since Aug 7.
Disclosure to exploitation, from the record and what we observed since indexing it.
Disclosed via OSV
Last analysed / modified upstream
1.9%
4 GitHub repos
1.9% → 2.1%
I found a Remote Command Execution (RCE) vulnerability in PyTorch. When loading model using torch.load with weights_only=True, it can still achieve RCE.
https://github.com/pytorch/pytorch/security
As you can see, the PyTorch official documentation considers using torch.load() with weights_only=True to be safe.
Since everyone knows that weights_only=False is unsafe, so they will use the weights_only=True to mitigate the seucirty issue.
But now, I just proved that even if you use weights_only=True, it can still achieve RCE.
This vulnerability was found by Ji'an Zhou.
torch < 2.6.0Upgrade to a patched release:
torch 2.6.0Field changes observed since this record was first indexed.
Connected by shared product, vendor, weakness, or advisory.
CVE-2025-2953Low· 3.3PyTorch susceptible to local Denial of Service
CVE-2024-31580High· 7.5PyTorch heap buffer overflow vulnerability
CVE-2025-3000Medium· 5.3PyTorch is vulnerable to memory corruption through its torch.jit.script function
CVE-2025-3730Low· 3.3PyTorch Improper Resource Shutdown or Release vulnerability
CVE-2025-3001NoneA vulnerability classified as critical was found in PyTorch 2.6.0. This vulnerability affects the function torch.lstm_cell. The manipulat…
CVE-2025-2999NoneA vulnerability was found in PyTorch 2.6.0. It has been rated as critical. Affected by this issue is the function torch.nn.utils.rnn.unpa…