Advisory

GHSA-mc8h-8q98-g5hr

Also known as: RUSTSEC-2023-0018

Summary

Race Condition Enabling Link Following and Time-of-check Time-of-use (TOCTOU) Race Condition in remove_dir_all

Details

The remove_dir_all crate is a Rust library that offers additional features over the Rust standard library fs::remove_dir_all function. It suffers the same class of failure as the code it was layering over: TOCTOU race conditions, with the ability to cause arbitrary paths to be deleted by substituting a symlink for a path after the type of the path was checked.

Thanks to the Rust security team for identifying the problem and alerting us to it.

Severity

Low Basis: The source's own band: LOW

Dates

Published
2023-02-24 16:23 UTC
Modified
2026-09-10 03:49 UTC

Affected packages and fixes

remove_dir_all

crates.io · All systems

Affected

  • introduced 0, fixed 0.8.0 (semver)

Fixed versions

0.8.0

Fix

  • Fixed version 0.8.0
    cargo update -p remove_dir_all --precise 0.8.0

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: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences