Advisory

UBUNTU-CVE-2026-31221

Also known as: CVE-2026-31221

Summary

The record has no summary.

Details

PyTorch-Lightning versions 2.6.0 and earlier contain an insecure deserialization vulnerability (CWE-502) in the checkpoint loading mechanism. The LightningModule.load_from_checkpoint() method, which is commonly used to load saved model states, internally calls torch.load() without setting the security-restrictive weights_only=True parameter. This default behavior allows the deserialization of arbitrary Python objects via the Pickle module. A remote attacker can exploit this by providing a maliciously crafted checkpoint file, leading to arbitrary code execution on the victim's system when the file is loaded.

Severity

High Basis: CVSS v3 score 7.8, vector CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Dates

Published
2026-05-12 16:16 UTC
Modified
2026-10-17 12:58 UTC

Affected packages and fixes

pytorch

Debian packages (deb) · Ubuntu 22.04

Affected

  • introduced 0 (ecosystem)

Fixed versions

None listed

Fix

No fixed version is listed.

pytorch

Debian packages (deb) · Ubuntu 25.10

Affected

  • introduced 0 (ecosystem)

Fixed versions

None listed

Fix

No fixed version is listed.

pytorch

Debian packages (deb) · Ubuntu 26.10

Affected

  • introduced 0 (ecosystem)

Fixed versions

None listed

Fix

No fixed version is listed.

pytorch

Debian packages (deb) · Ubuntu 26.04

Affected

  • introduced 0 (ecosystem)

Fixed versions

None listed

Fix

No fixed version is listed.

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: Ubuntu Security Notices · CC BY-SA 4.0

Sources & licences