CVE-2022-45907: Code Injection

Published Nov 26, 2022
·
Updated

In PyTorch before trunk/89695, torch.jit.annotations.parsetypeline can cause arbitrary code execution because eval is used unsafely.

Affected Software

2 affected componentsFixes available
pip/torch<=1.13.0
1.13.1
linuxfoundation Pytorch Python<1.13.1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/torch to a version that resolves this vulnerability.

    Fixed in 1.13.1
  2. Upgrade

    Upgrade pytorch/torch.jit.annotations.parse_type_line to a version that resolves this vulnerability.

    Fixed in 1.13.1

Event History

Nov 26, 2022
CVE Published
via MITRE·12:00 AM
Data Sourced
via MITRE·12:00 AM
Description
Data Sourced
via NVD·02:15 AM
RemedyDescriptionSeverityWeaknessAffected Software
Advisory Published
via GitHub·03:30 AM

Frequently Asked Questions

1

What is the vulnerability ID?

The vulnerability ID is CVE-2022-45907.

2

What is the severity of CVE-2022-45907?

The severity of CVE-2022-45907 is critical (9.8).

3

What software versions are affected by CVE-2022-45907?

Versions up to exclusive 1.13.1 of PyTorch are affected by CVE-2022-45907.

4

How does CVE-2022-45907 occur?

CVE-2022-45907 occurs due to the unsafe use of eval in torch.jit.annotations.parse_type_line.

5

How can I fix CVE-2022-45907?

To fix CVE-2022-45907, update PyTorch to a version beyond trunk/89695 or apply the necessary patches provided by the PyTorch team.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203