Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

redhat логотип

CVE-2026-50163

Опубликовано: 01 июл. 2026
Источник: redhat
CVSS3: 5.9
EPSS Низкий

Описание

oras-go is a Go library for managing OCI artifacts. Prior to 2.6.2, ensureLinkPath in content/file/utils.go:262-275 validates a hardlink target relative to the extract base but returns the unresolved target, causing os.Link("victim.secret", "<extract_base>/payload.tar.gz/evil_cwd_link") to resolve header.Linkname against the process current working directory for a Typeflag=TypeLink entry such as Name=payload.tar.gz/evil_cwd_link and Linkname="victim.secret" with io.deis.oras.content.unpack: "true", which can expose or tamper with files such as .env, .git/config, .aws/credentials, and ~/.ssh/config. This issue is fixed in version 2.6.2.

A flaw was found in oras-go, a Go library used for managing OCI (Open Container Initiative) artifacts. An attacker can exploit this vulnerability by providing a specially crafted tarball containing a malicious hardlink. When this tarball is extracted, the hardlink can be manipulated to point to files outside the intended extraction location, specifically within the victim's current working directory. This allows an attacker to read sensitive information from the system, and in some cases, could lead to unauthorized access to critical system files if the component is operating with elevated privileges.

Отчет

A flaw was found in oras-go. The ensureLinkPath tar extraction helper validates that a hardlink's target resolves inside the extract base directory, but returns the original unresolved target string instead of the validated path. When os.Link() is called with a relative Linkname, it resolves against the process's current working directory (CWD), not the extract directory. An attacker controlling an OCI registry can craft a tarball layer with a malicious hardlink entry whose relative Linkname escapes the extract directory, creating a hardlink to arbitrary files in the victim's CWD. Exploitation requires the victim to run oras pull (or code using the oras-go file store) against an attacker-controlled registry with auto-extract enabled (io.deis.oras.content.unpack annotation set to true). In typical Red Hat deployments, container registries are curated and trusted, reducing the likelihood of exploitation. The resulting hardlink shares an inode with the target file, allowing the attacker to read its contents through the extracted archive.

Меры по смягчению последствий

Upgrade to oras-go v2.6.1 or later.

Затронутые пакеты

ПлатформаПакетСостояниеРекомендацияРелиз
Gatekeeper 3gatekeeper/gatekeeper-rhel9Fix deferred
Multicluster Global Hubmulticluster-globalhub/multicluster-globalhub-grafana-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-rhel9-operatorFix deferred
Red Hat OpenShift Container Platform 4openshift4/cnf-tests-rhel8Fix deferred
Red Hat OpenShift Container Platform 4openshift4/metallb-rhel8-operatorFix deferred
Red Hat OpenShift Container Platform 4openshift4/metallb-rhel9-operatorFix deferred
Red Hat OpenShift Container Platform 4openshift4/oc-mirror-plugin-rhel8Fix deferred
Red Hat OpenShift Container Platform 4openshift4/oc-mirror-plugin-rhel9Fix deferred
Red Hat OpenShift Container Platform 4openshift4/ose-ansible-operatorFix deferred
Red Hat OpenShift Container Platform 4openshift4/ose-azure-cluster-api-controllers-rhel8Fix deferred

Показывать по

Дополнительная информация

Статус:

Moderate
Дефект:
CWE-22
https://bugzilla.redhat.com/show_bug.cgi?id=2499695oras-go: Oras-go: Information disclosure and arbitrary file access via crafted tarball hardlinks

EPSS

Процентиль: 27%
0.00345
Низкий

5.9 Medium

CVSS3

Связанные уязвимости

CVSS3: 7.1
ubuntu
20 дней назад

oras-go is a Go library for managing OCI artifacts. Prior to 2.6.2, ensureLinkPath in content/file/utils.go:262-275 validates a hardlink target relative to the extract base but returns the unresolved target, causing os.Link("victim.secret", "<extract_base>/payload.tar.gz/evil_cwd_link") to resolve header.Linkname against the process current working directory for a Typeflag=TypeLink entry such as Name=payload.tar.gz/evil_cwd_link and Linkname="victim.secret" with io.deis.oras.content.unpack: "true", which can expose or tamper with files such as .env, .git/config, .aws/credentials, and ~/.ssh/config. This issue is fixed in version 2.6.2.

CVSS3: 7.1
nvd
20 дней назад

oras-go is a Go library for managing OCI artifacts. Prior to 2.6.2, ensureLinkPath in content/file/utils.go:262-275 validates a hardlink target relative to the extract base but returns the unresolved target, causing os.Link("victim.secret", "<extract_base>/payload.tar.gz/evil_cwd_link") to resolve header.Linkname against the process current working directory for a Typeflag=TypeLink entry such as Name=payload.tar.gz/evil_cwd_link and Linkname="victim.secret" with io.deis.oras.content.unpack: "true", which can expose or tamper with files such as .env, .git/config, .aws/credentials, and ~/.ssh/config. This issue is fixed in version 2.6.2.

CVSS3: 7.1
debian
20 дней назад

oras-go is a Go library for managing OCI artifacts. Prior to 2.6.2, en ...

CVSS3: 7.1
github
около 1 месяца назад

`oras-go` tar extraction: Hardlink entry with relative Linkname escapes extract dir via process CWD resolution

EPSS

Процентиль: 27%
0.00345
Низкий

5.9 Medium

CVSS3