{"id":"RUSTSEC-2020-0100","summary":"Double free when calling `sys_info::disk_info` from multiple threads","details":"Affected versions of `sys-info` use a static, global, list to store temporary disk information while running. The function that cleans up this list,\n`DFCleanup`, assumes a single threaded environment and will try to free the same memory twice in a multithreaded environment.\n\nThis results in consistent double-frees and segfaults when calling `sys_info::disk_info` from multiple threads at once.\n\nThe issue was fixed by moving the global variable into a local scope.\n\n## Safer Alternatives:\n - [`sysinfo`](https://crates.io/crates/sysinfo)","aliases":["CVE-2020-36434","GHSA-2f5j-3mhq-xv58"],"modified":"2023-11-08T04:03:44.601087Z","published":"2020-05-31T12:00:00Z","database_specific":{"license":"CC0-1.0"},"references":[{"type":"PACKAGE","url":"https://crates.io/crates/sys-info"},{"type":"ADVISORY","url":"https://rustsec.org/advisories/RUSTSEC-2020-0100.html"},{"type":"REPORT","url":"https://github.com/FillZpp/sys-info-rs/issues/63"}],"affected":[{"package":{"name":"sys-info","ecosystem":"crates.io","purl":"pkg:cargo/sys-info"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0.0.0-0"},{"fixed":"0.8.0"}]}],"ecosystem_specific":{"affects":{"os":["linux"],"arch":[],"functions":["sys_info::disk_info"]},"affected_functions":null},"database_specific":{"informational":null,"source":"https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2020-0100.json","cvss":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","categories":["memory-corruption"]}}],"schema_version":"1.7.3","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"}]}