Tar path traversal in stereoscope when processing OCI tar archives
stereoscope is a go library for processing container images and simulating a squash filesystem. Prior to version 0.0.1, it is possible to craft an OCI tar archive that, when stereoscope attempts to unarchive the contents, will result in writing to paths outside of the unarchive temporary directory. Specifically, use of `github.com/anchore/stereoscope/pkg/file.UntarToDirectory()` function, the `github.com/anchore/stereoscope/pkg/image/oci.TarballImageProvider` struct, or the higher level `github.com/anchore/stereoscope/pkg/image.Image.Read()` function express this vulnerability. As a workaround, if you are using the OCI archive as input into stereoscope then you can switch to using an OCI layout by unarchiving the tar archive and provide the unarchived directory to stereoscope.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2024-24579
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 5 Nov 2026, 01:29 UTC · Revision 1
Source evidence
Tar path traversal in stereoscope when processing OCI tar archives
core-osv · Original sourcePublished 31 Jan 2024, 16:40 UTC
stereoscope is a go library for processing container images and simulating a squash filesystem. Prior to version 0.0.1, it is possible to craft an OCI tar archive that, when stereoscope attempts to unarchive the contents, will result in writing to paths outside of the unarchive temporary directory. Specifically, use of `github.com/anchore/stereoscope/pkg/file.UntarToDirectory()` function, the `github.com/anchore/stereoscope/pkg/image/oci.TarballImageProvider` struct, or the higher level `github.com/anchore/stereoscope/pkg/image.Image.Read()` function express this vulnerability. As a workaround, if you are using the OCI archive as input into stereoscope then you can switch to using an OCI layout by unarchiving the tar archive and provide the unarchived directory to stereoscope.
osv:CVE-2024-24579
Complete source record
{
"id": "7dc93297948914e74c4ef2b4104b4ac8249b2887256c8fd7a100196325f84c43",
"url": "https://osv.dev/vulnerability/CVE-2024-24579",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "Tar path traversal in stereoscope when processing OCI tar archives",
"summary": "stereoscope is a go library for processing container images and simulating a squash filesystem. Prior to version 0.0.1, it is possible to craft an OCI tar archive that, when stereoscope attempts to unarchive the contents, will result in writing to paths outside of the unarchive temporary directory. Specifically, use of `github.com/anchore/stereoscope/pkg/file.UntarToDirectory()` function, the `github.com/anchore/stereoscope/pkg/image/oci.TarballImageProvider` struct, or the higher level `github.com/anchore/stereoscope/pkg/image.Image.Read()` function express this vulnerability. As a workaround, if you are using the OCI archive as input into stereoscope then you can switch to using an OCI layout by unarchiving the tar archive and provide the unarchived directory to stereoscope.",
"evidence": "osv:CVE-2024-24579",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2024-24579",
"aliases": [
"CVE-2024-24579",
"GHSA-hpxr-w9w7-g4gv",
"GO-2024-2490"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/anchore/stereoscope",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "09dacab4d9ee65ee8bc7af8ebf4aa7b5aaa36204"
}
],
"database_specific": {
"extracted_events": [
{
"range": [
{
"introduced": "0"
},
{
"fixed": "0.0.1"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StringRangeExpression"
},
{
"range": [
{
"fixed": "09dacab4d9ee65ee8bc7af8ebf4aa7b5aaa36204"
}
],
"source": "REFERENCES_COMMIT"
},
{
"cpe": "cpe:2.3:a:anchore:stereoscope:*:*:*:*:*:go:*:*",
"range": [
{
"introduced": "0"
},
{
"fixed": "0.0.1"
}
],
"source": "CPE_RANGE"
}
]
}
}
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-24579.json"
}
}
],
"modified": "2026-10-28T02:30:41.346232056Z",
"provider": "osv",
"references": [
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/24xxx/CVE-2024-24579.json",
"https://github.com/anchore/stereoscope/security/advisories/GHSA-hpxr-w9w7-g4gv",
"https://nvd.nist.gov/vuln/detail/CVE-2024-24579",
"https://github.com/anchore/stereoscope/commit/09dacab4d9ee65ee8bc7af8ebf4aa7b5aaa36204"
],
"provider_metadata": {
"cwe_ids": [
"CWE-22"
],
"cna_assigner": "GitHub_M",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/24xxx/CVE-2024-24579.json"
}
},
"related_cves": [
{
"value": "CVE-2024-24579",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 508957,
"published_at": "2024-01-31T16:40:35.385+00:00"
}