Pytorch use-after-free vulnerability
CVE-2024-31583 · GHSA-pg7h-5qx3-wjr3 · published 2024-04-17 · updated 2025-06-10
- Severity
- High
- CVSS score
- 7.8
- Chance of exploitation (EPSS)
- 0.27%
- Fixed in
- 2.2.0
- Exploitation No known exploitation
- Automatable No
- Technical impact Total
- CISA SSVC
Pytorch before version v2.2.0 was discovered to contain a use-after-free vulnerability in torch/csrc/jit/mobile/interpreter.cpp.
Upgrade torch to 2.2.0 or later.
| Package | Registry | Affected | Fixed in |
|---|---|---|---|
| torch | PyPI | < 2.2.0 | 2.2.0 |
- CriticalLiteLLM has SQL Injection in Proxy API key verificationlitellmExploited
- Criticaln8n Vulnerable to Remote Code Execution via Expression Injectionn8n, n8nExploited
- HighLiteLLM has a sandbox escape in custom-code guardraillitellmExploited
- HighLangflow affected by Remote Code Execution via validate_code() exec()langflowExploited
- CriticalJupyter MCP Server: Browser DNS rebinding can hijack the Jupyter backend through management routesjupyter-mcp-server
- Criticalmem0ai Databricks vector store vulnerable to SQL injectionmem0ai
- CriticalPyTorch: `torch.load` with `weights_only=True` leads to remote code executiontorch
- CriticalPyTorch vulnerable to arbitrary code executiontorch
- HighPyTorch Vulnerable to Remote Code Execution via Untrusted Checkpoint Filestorch
- HighPyTorch heap buffer overflow vulnerabilitytorch
- MediumPyTorch Improper Resource Shutdown or Release vulnerabilitytorch
- MediumPyTorch is Vulnerable to Memory Consumption through pad_packed_sequence Functiontorch
The impact, patch and workaround text comes from the advisory, shortened (GitHub Advisory Database, CC BY 4.0). Proof-of-concept and reproduction sections and code are left out; the original advisory has them.