Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. torch
  4. ›
  5. CVE-2022-45907

CVE-2022-45907: PyTorch vulnerable to arbitrary code execution

November 26, 2022 (updated November 13, 2024)

In PyTorch before trunk/89695, torch.jit.annotations.parse_type_line can cause arbitrary code execution because eval is used unsafely. The fix for this issue is available in version 1.13.1. There is a release checker in issue #89855.

References

  • github.com/advisories/GHSA-47fc-vmwq-366v
  • github.com/pypa/advisory-database/tree/main/vulns/torch/PYSEC-2022-43015.yaml
  • github.com/pytorch/pytorch
  • github.com/pytorch/pytorch/commit/767f6aa49fe20a2766b9843d01e3b7f7793df6a3
  • github.com/pytorch/pytorch/issues/88868
  • github.com/pytorch/pytorch/issues/89855
  • github.com/pytorch/pytorch/pull/89189
  • github.com/pytorch/pytorch/releases/tag/v1.13.1
  • nvd.nist.gov/vuln/detail/CVE-2022-45907

Code Behaviors & Features

Detect and mitigate CVE-2022-45907 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 1.13.1

Fixed versions

  • 1.13.1

Solution

Upgrade to version 1.13.1 or above.

Impact 9.8 CRITICAL

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-77: Improper Neutralization of Special Elements used in a Command ('Command Injection')

Source file

pypi/torch/CVE-2022-45907.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:14:43 +0000.