CVE-2021-38511
published 2021-08-10CVE-2021-38511: An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks are present in a TAR archive, extraction can create arbitrary directories via .…
PriorityP339high7.5CVSS 3.1
AVNACLPRNUINSUCNIHAN
EPSS
1.39%
69.3th percentile
An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks are present in a TAR archive, extraction can create arbitrary directories via .. traversal.
Affected
4 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| debian | rust-tar | < rust-tar 0.4.37-1 (bookworm) | rust-tar 0.4.37-1 (bookworm) |
| gnu | tar | >= 0 < 0.4.36 | 0.4.36 |
| gnu | tar | >= 0.0.0-0 < 0.4.36 | 0.4.36 |
| tar_project | tar | < 0.4.36 | 0.4.36 |
CVSS provenance
nvdv3.17.5HIGHCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
nvdv2.05.0MEDIUMAV:N/AC:L/Au:N/C:N/I:P/A:N
osv7.5HIGH
vendor_debian7.5HIGH
vendor_redhat7.5HIGH
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
GHSA
Links in archive can create arbitrary directories
ghsa·2021-08-25
CVE-2021-38511 [HIGH] CWE-22 Links in archive can create arbitrary directories
Links in archive can create arbitrary directories
When unpacking a tarball that contains a symlink the tar crate may create directories outside of the directory it's supposed to unpack into. The function errors when it's trying to create a file, but the folders are already created at this point.
OSV
Links in archive can create arbitrary directories
osv·2021-08-25
CVE-2021-38511 [HIGH] Links in archive can create arbitrary directories
Links in archive can create arbitrary directories
When unpacking a tarball that contains a symlink the tar crate may create directories outside of the directory it's supposed to unpack into. The function errors when it's trying to create a file, but the folders are already created at this point.
OSV
CVE-2021-38511: An issue was discovered in the tar crate before 0
osv·2021-08-10·CVSS 7.5
CVE-2021-38511 [HIGH] CVE-2021-38511: An issue was discovered in the tar crate before 0
An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks are present in a TAR archive, extraction can create arbitrary directories via .. traversal.
OSV
Links in archive can create arbitrary directories
osv·2021-07-19
CVE-2021-38511 Links in archive can create arbitrary directories
Links in archive can create arbitrary directories
When unpacking a tarball that contains a symlink the `tar` crate may create
directories outside of the directory it's supposed to unpack into.
The function errors when it's trying to create a file, but the folders are
already created at this point.
```rust
use std::{io, io::Result};
use tar::{Archive, Builder, EntryType, Header};
fn main() -> Result {
let mut buf = Vec::new();
{
let mut builder = Builder::new(&mut buf);
// symlink: parent -> ..
let mut header = Header::new_gnu();
header.set_path("symlink")?;
header.set_link_name("..")?;
header.set_entry_type(EntryType::Symlink);
header.set_size(0);
header.set_cksum();
builder.append(&header, io::empty())?;
// file: symlink/exploit/foo/bar
let mut header = Header::new_gnu();
header.se
Debian
CVE-2021-38511: rust-tar - An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks a...
vendor_debian·2021·CVSS 7.5
CVE-2021-38511 [HIGH] CVE-2021-38511: rust-tar - An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks a...
An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks are present in a TAR archive, extraction can create arbitrary directories via .. traversal.
Scope: local
bookworm: resolved (fixed in 0.4.37-1)
bullseye: open
forky: resolved (fixed in 0.4.37-1)
sid: resolved (fixed in 0.4.37-1)
trixie: resolved (fixed in 0.4.37-1)
Red Hat
tar-crate: links in archive can create arbitrary directories
vendor_redhat·2020-09-10·CVSS 7.5
CVE-2021-38511 [HIGH] CWE-22 tar-crate: links in archive can create arbitrary directories
tar-crate: links in archive can create arbitrary directories
An issue was discovered in the tar crate before 0.4.36 for Rust. When symlinks are present in a TAR archive, extraction can create arbitrary directories via .. traversal.
Package: cincinnati-container (Red Hat Advanced Cluster Management for Kubernetes 2) - Not affected
No detection rules found.
No public exploits indexed.
2021-08-10
Published