Rust is a multi-paradigm, general-purpose programming language designed for performance and safety, especially safe concurrency. The Rust Security Response WG was notified that the `std::fs::remove_dir_all` standard library function is vulnerable a race condition enabling symlink following (CWE-363). An attacker could use this security issue to trick a privileged program into deleting files and directories the attacker couldn't otherwise access or delete. Rust 1.0.0 through Rust 1.58.0 is affected by this vulnerability with 1.58.1 containing a patch. Note that the following build targets don't have usable APIs to properly mitigate the attack, and are thus still vulnerable even with a patched toolchain: macOS before version 10.10 (Yosemite) and REDOX. We recommend everyone to update to Rust 1.58.1 as soon as possible, especially people developing programs expected to run in privileged contexts (including system daemons and setuid binaries), as those have the highest risk of being affected by this. Note that adding checks in your codebase before calling remove_dir_all will not mitigate the vulnerability, as they would also be vulnerable to race conditions like remove_dir_all itself. The existing mitigation is working as intended outside of race conditions.
| Product | Vendor Advisory | Solution File | Added | Published |
|---|---|---|---|---|
| Alma_linux | — | Upgrade clippyUpgrade cargo-docUpgrade rust-srcUpgrade rust-analysisUpgrade rust-std-static-wasm32-unknown-unknownUpgrade cargoUpgrade rust-gdbUpgrade rlsUpgrade rust-docUpgrade rust-toolsetUpgrade rust-std-static-wasm32-wasiUpgrade rust-debugger-commonUpgrade rustfmtUpgrade rust-std-staticUpgrade rustUpgrade rust-lldb | May 13, 2022 | Jan 20, 2022 |
| Amazon Linux Ami 2 | — | Upgrade rust-srcUpgrade rust-debugger-commonUpgrade rustfmtUpgrade rust-docUpgrade rust-debuginfoUpgrade rust-std-staticUpgrade rustUpgrade rust-gdbUpgrade cargo-docUpgrade cargoUpgrade rlsUpgrade clippyUpgrade rust-analysis | Sep 30, 2022 | Jan 20, 2022 |
| Apple Osx Llvm | — | Upgrade macOS to the latest version | May 26, 2022 | Jan 20, 2022 |
| Centos_linux | — | Upgrade cargo-docUpgrade rust-toolsetUpgrade rlsUpgrade rust-analysisUpgrade rust-gdbUpgrade clippyUpgrade cargoUpgrade rust-srcUpgrade cargo-debuginfoUpgrade rustUpgrade rust-lldbUpgrade clippy-debuginfoUpgrade rust-std-staticUpgrade rust-std-static-wasm32-unknown-unknownUpgrade rust-debugsourceUpgrade rust-debuginfoUpgrade rust-debugger-commonUpgrade rls-debuginfoUpgrade rustfmtUpgrade rust-docUpgrade rust-std-static-wasm32-wasiUpgrade rustfmt-debuginfo | May 13, 2022 | Jan 20, 2022 |
| Debian | — | Upgrade rustc | Jul 30, 2024 | Jan 20, 2022 |
| Freebsd | — | Upgrade rustUpgrade rust-nightly | Nov 4, 2022 | Jan 31, 2022 |
| Gentoo Linux | — | Upgrade dev-lang/rust-bin.Upgrade dev-lang/rust. | Oct 17, 2022 | Jan 20, 2022 |
| Oracle_linux | — | Upgrade rust-std-staticUpgrade rust-gdbUpgrade rust-debugger-commonUpgrade rust-docUpgrade rust-toolsetUpgrade clippyUpgrade rlsUpgrade rustUpgrade rust-std-static-wasm32-wasiUpgrade cargoUpgrade rust-std-static-wasm32-unknown-unknownUpgrade rust-lldbUpgrade rust-srcUpgrade rustfmtUpgrade rust-analysisUpgrade cargo-doc | May 18, 2022 | Jan 20, 2022 |
| Redhat_linux | — | Upgrade rust-debuginfoUpgrade rust-analysisUpgrade clippyUpgrade rls-debuginfoUpgrade cargoUpgrade rust-docUpgrade rust-std-staticUpgrade rust-debugger-commonUpgrade rust-srcUpgrade cargo-docUpgrade rustfmtUpgrade rustUpgrade rustfmt-debuginfoUpgrade rust-std-static-wasm32-wasiUpgrade rust-toolsetUpgrade rlsUpgrade rust-lldbUpgrade rust-debugsourceUpgrade clippy-debuginfoUpgrade cargo-debuginfoUpgrade rust-gdbUpgrade rust-std-static-wasm32-unknown-unknownNo solution exists | May 13, 2022 | Jan 20, 2022 |
| Rocky_linux | — | Upgrade clippyUpgrade rust-debuginfoUpgrade rlsUpgrade clippy-debuginfoUpgrade rustfmt-debuginfoUpgrade rust-docUpgrade cargo-debuginfoUpgrade cargoUpgrade rust-std-static-wasm32-unknown-unknownUpgrade rustUpgrade rust-debugsourceUpgrade rust-toolsetUpgrade rust-std-static-wasm32-wasiUpgrade rustfmtUpgrade rust-analysisUpgrade rust-std-staticUpgrade rls-debuginfo | Mar 5, 2024 | Jan 20, 2022 |
| Suse | — | Upgrade cargo1.57Upgrade cargo-docUpgrade cargo1.58Upgrade cargo1.59Upgrade rust-analysisUpgrade rust-srcUpgrade rustUpgrade cargo1.55Upgrade rust1.56Upgrade rust1.58Upgrade rust-gdbUpgrade rust1.57Upgrade rust-docUpgrade rlsUpgrade rust1.55Upgrade cargoUpgrade rust1.59Upgrade cargo1.56 | Jan 22, 2022 | Jan 20, 2022 |
| Ubuntu | — | Upgrade rustc | Nov 19, 2024 | Jan 20, 2022 |
| Vmware Photon_os | — | Use 'tdnf update' to upgrade all packages to the latest version. | Jan 20, 2025 | Jan 20, 2022 |
With curated Threat Intelligence, you can see which vulnerabilities truly put you at risk, prioritize what matters most, and act before attackers do.
Explore Intelligence Hub