UNIX symbolic link following in Cargo - CVE-2022-36113

 

UNIX symbolic link following in Cargo - CVE-2022-36113

Published: September 28, 2022


Vulnerability identifier: #VU67717
CSH Severity: Low
CVSS v4: 5.1 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N]
CVE-ID: CVE-2022-36113
CWE-ID: CWE-61
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote attacker to corrupt arbitrary files on the system.

The vulnerability exists due to a symlink following issue. A remote attacker can add a malicious ".cargo-ok" symbolic link into the package, point the link to an arbitrary file on the system and corrupt it during package extraction.


Affected software

Cargo
Amazon Linux AMI
SUSE Manager Proxy
SUSE Manager Server
SUSE Manager Retail Branch Server
SUSE Linux Enterprise Storage
Oracle Solaris
SUSE Linux Enterprise Server
SUSE Linux Enterprise Server for SAP Applications
SUSE Linux Enterprise Desktop
SUSE Linux Enterprise Module for Development Tools
SUSE Linux Enterprise High Performance Computing
openSUSE Leap
openEuler
rust-src
rust-debugger-common
rustfmt
rust-std-static
rust-help
rust-debugsource
rust-debuginfo
rust-analysis
rls
clippy
cargo
rust
rust-lldb
rust-gdb
cargo1.62-debuginfo
rust1.62-debuginfo
rust1.62
cargo1.62

How to mitigate CVE-2022-36113

Install updates from vendor's website.

Cargo - update to 0.65.0
rust-src - addressed in versions 1.51.0-8, 1.60.0-4
rust-debugger-common - addressed in versions 1.51.0-8, 1.60.0-4
rustfmt - addressed in versions 1.51.0-8, 1.60.0-4
rust-std-static - addressed in versions 1.51.0-8, 1.60.0-4
rust-help - addressed in versions 1.51.0-8, 1.60.0-4
rust-debugsource - addressed in versions 1.51.0-8, 1.60.0-4
rust-debuginfo - addressed in versions 1.51.0-8, 1.60.0-4
rust-analysis - addressed in versions 1.51.0-8, 1.60.0-4
rls - addressed in versions 1.51.0-8, 1.60.0-4
clippy - addressed in versions 1.51.0-8, 1.60.0-4
cargo - addressed in versions 1.51.0-8, 1.60.0-4
rust - addressed in versions 1.51.0-8, 1.60.0-4
rust-lldb - addressed in versions 1.51.0-8, 1.60.0-4
rust-gdb - addressed in versions 1.51.0-8, 1.60.0-4
cargo1.62-debuginfo - update to 1.62.1-150300.7.7.1
rust1.62-debuginfo - update to 1.62.1-150300.7.7.1
rust1.62 - update to 1.62.1-150300.7.7.1
cargo1.62 - update to 1.62.1-150300.7.7.1
rust - update to 1.66.1-1

External References

Related Security Bulletins