Description
torchvision before 0.29.2 contains a path traversal vulnerability in _extract_tar() that allows attackers to write files outside the extraction directory by supplying crafted tar archives. Attackers controlling archives passed to extract_archive() or download_and_extract_archive() can use .. paths, absolute paths, or symlinks to overwrite Python modules and achieve code execution.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| pytorch | vision | < 0.29.2 | 0.29.2 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | pytorch-vision | No fix yet | — |
| Debian 13 | pytorch-vision | No fix yet | — |
| Debian 12 | pytorch-vision | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | pytorch-vision | No fix yet | — |
| Ubuntu 22.04 LTS | pytorch-vision | No fix yet | — |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | python-torchvision | 0.29.2-1.1 | openSUSE-SU-2026:12751-1 |
Advisories 1
- openSUSE-SU-2026:12751-1 python313-torchvision-0.29.2-1.1 on GA media SUSE / openSUSE Security Updates · Dec 2, 2026
References
- https://github.com/pytorch/vision/issues/9517 issue-tracking
- https://github.com/pytorch/vision/commit/7a7520f83957fe6a0f934fe7035f07b5ef32e8f9 patch
- https://github.com/pytorch/vision/commit/b22811118b30f18ef02006fc6215a52140fd689f patch
- vision v0.29.2 Release Notes release-notes
- https://github.com/pytorch/vision/blob/v0.29.1/torchvision/datasets/utils.py#L209-L213 technical-description
- VulnCheck Advisory: torchvision before 0.29.2 Path Traversal via Tar Archive Extraction third-party-advisory