Skip to main content

oras-go CVE-2026-48978

| EUVDEUVD-2026-45295 LOW
Cleartext Transmission of Sensitive Information (CWE-319)
2026-07-01 https://github.com/oras-project/oras-go GHSA-xf85-363p-868w
2.1
CVSS 4.0 · Vendor: https://github.com/oras-project/oras-go

Severity by source

Vendor (https://github.com/oras-project/oras-go) PRIMARY
2.1 LOW
CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:A/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
vuln.today AI
4.3 MEDIUM

Network-reachable with no privileges needed, but active user interaction required; confidentiality impact is low - limited to IMDS probe responses or passive credential interception, not direct account takeover.

3.1 AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:N
4.0 AV:N/AC:L/AT:N/PR:N/UI:A/VC:L/VI:N/VA:N/SC:L/SI:N/SA:N

Primary rating from Vendor (https://github.com/oras-project/oras-go).

CVSS VectorVendor: https://github.com/oras-project/oras-go

Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
A
Scope
X

Lifecycle Timeline

2
CVSS changed
Jul 17, 2026 - 20:22 NVD
2.1 (LOW)
Analysis Generated
Jul 01, 2026 - 21:34 vuln.today

DescriptionCVE.org

Summary

oras-go's auth.Client follows the realm URL from a registry's WWW-Authenticate: Bearer challenge without validating its scheme or host. The realm field is server-controlled by design in the OCI/distribution spec - registries legitimately point token requests at a separate auth endpoint (e.g. Docker Hub's registry-1.docker.io -> auth.docker.io), so cross-host realms on public DNS names are not in themselves a vulnerability. Two specific patterns, however, are never legitimate under any registry trust model and can be abused by a malicious or compromised registry (or a man-in-the-middle on a plaintext connection):

  1. SSRF to internal networks. A realm of http://169.254.169.254/... (AWS/Azure IMDS), http://10.0.0.x/... (RFC 1918), or http://127.0.0.1/... causes oras-go running on a cloud VM or corporate workstation to issue outbound HTTP requests from inside the user's trust boundary to an endpoint the user did not choose. The user's stored credentials are attached to those requests, but the principal harm is the network primitive - probing internal endpoints from the client. On IMDSv1 the response body is recoverable from log channels; on IMDSv2 the probe itself can still be used for service discovery.
  2. TLS downgrade. A registry contacted over https:// can return a realm with an http:// scheme, causing oras-go to send the user's credentials over plaintext to the token endpoint. This defeats the transport security the user chose when typing https://.

What is NOT claimed

This advisory does not claim that credential forwarding to an arbitrary public attacker host through a server-controlled realm is, on its own, a vulnerability. The distribution spec defines realm as a server-controlled field; a strict same-host or same-eTLD+1 enforcement would deviate from the spec and break legitimate split-host deployments. Operators who want defense-in-depth against cross-host realm forwarding can use the opt-in Client.TrustedRealmHosts allowlist (added separately).

Affected versions

oras.land/oras-go/v2 <= v2.6.0

Severity

Medium. Network attack vector, low complexity, no privileges required, user interaction required (victim runs an oras command against the malicious or MITM'd registry), unchanged scope. Confidentiality impact is limited - IMDS probe responses can disclose information, and TLS downgrade exposes the realm request to passive observers - but the attacker does not obtain credentials beyond what the malicious endpoint already controls.

Affected code

  • registry/remote/auth/client.go - Client.Do() (bearer challenge handling)
  • registry/remote/auth/client.go - Client.fetchBearerToken() / fetchDistributionToken / fetchOAuth2Token

The realm parameter from parseChallenge is threaded through to http.NewRequestWithContext without scheme or host validation.

CWE

  • CWE-918: Server-Side Request Forgery (SSRF)
  • CWE-319: Cleartext Transmission of Sensitive Information

Patch

registry/remote/auth/client.go now rejects realm URLs that:

  • use a scheme other than http or https
  • use http when the registry was contacted over https (TLS downgrade)
  • use an IP literal in a loopback, link-local, private, or unspecified range, unless the registry itself was reached at the same hostname (so loopback / in-cluster deployments are unaffected)

Cross-host realms on public DNS names continue to be accepted.

Credit

Reported by bugbunny.ai.

AnalysisAI

Unvalidated bearer realm URL handling in oras-go v2 ≤ 2.6.0 enables two distinct attack primitives against users who run oras operations against a malicious, compromised, or man-in-the-middle'd registry: server-side request forgery (SSRF) to internal network endpoints including cloud instance metadata services, and TLS downgrade that exposes user credentials in plaintext. The OCI distribution spec legitimately allows cross-host realm references for split-auth deployments (e.g., Docker Hub's auth.docker.io pattern), but oras-go failed to block private IP literals, loopback addresses, and scheme downgrades from https to http - patterns that are never legitimate under any valid registry trust model. No active exploitation has been confirmed (not in CISA KEV), and a patch is available in v2.6.1.

Technical ContextAI

oras-go (OCI Registry As Storage Go library) implements the OCI distribution specification's bearer token authentication flow. When a registry returns a 401 Unauthorized response, it includes a WWW-Authenticate: Bearer header containing a 'realm' field pointing to the token endpoint. The spec intentionally allows this field to reference a separate host (split-auth architectures), and oras-go's auth.Client.Do() / fetchBearerToken() / fetchDistributionToken() / fetchOAuth2Token() in registry/remote/auth/client.go pass the realm URL from parseChallenge directly to http.NewRequestWithContext without any scheme or host validation. This violates CWE-918 (SSRF) because a server-controlled URL is used to initiate outbound requests from the client's trust boundary, and CWE-319 (Cleartext Transmission) because the https-to-http downgrade defeats the transport security the user configured. Affected packages are pkg:go/oras.land_oras-go_v2 and pkg:go/oras.land_oras-go. The fix in v2.6.1 (commit 7a9f4b0b9558821b0422152ebe21ae56930fe764) rejects realm URLs using non-http/https schemes, http realms when the registry was contacted over https, and IP literals in loopback, link-local, private, or unspecified ranges unless the registry itself was reached at that same host.

RemediationAI

Upgrade oras.land/oras-go/v2 to v2.6.1, which rejects unsafe realm URLs at the point of challenge parsing. The patch commit is 7a9f4b0b9558821b0422152ebe21ae56930fe764 and the release is tagged at https://github.com/oras-project/oras-go/releases/tag/v2.6.1. For teams that cannot immediately upgrade, the advisory mentions an opt-in Client.TrustedRealmHosts allowlist added as a defense-in-depth control - configuring this to only permit known legitimate auth hosts (e.g., auth.docker.io for Docker Hub) eliminates the cross-host realm risk, though it does not by itself fix the scheme-downgrade vector. As an additional compensating control, restrict outbound HTTP (port 80) from CI/CD runners or developer workstations to block SSRF to internal services, noting this may interfere with plain-HTTP registry access. If operating on AWS/Azure with IMDSv1, migrate to IMDSv2 (which requires a PUT preflight that oras-go would not issue) to reduce SSRF yield even when the probe reaches the metadata endpoint. Avoid connecting to untrusted or unverified registries over plaintext HTTP connections in sensitive environments.

More in Docker

View all
CVE-2024-55964 CRITICAL POC
9.8 Mar 26

An issue was discovered in Appsmith before 1.52. Rated critical severity (CVSS 9.8), this vulnerability is remotely expl

CVE-2019-5736 HIGH POC
8.6 Feb 11

runc through version 1.0-rc6 (used in Docker before 18.09.2) contains a container escape vulnerability that allows attac

CVE-2023-32077 HIGH POC
7.5 Aug 24

Netmaker makes networks with WireGuard. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitable, no a

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2023-5815 HIGH POC
8.1 Nov 22

The News & Blog Designer Pack - WordPress Blog Plugin - (Blog Post Grid, Blog Post Slider, Blog Post Carousel, Blog Post

CVE-2026-66384 MEDIUM POC
5.3 Aug 12

Path traversal in JFrog Artifactory (CWE-22) enables an authenticated low-privilege user to write data outside the inten

CVE-2014-9357 CRITICAL
10.0 Dec 16

Docker 1.3.2 allows remote attackers to execute arbitrary code with root privileges via a crafted (1) image or (2) build

CVE-2026-52806 CRITICAL POC
9.9 Jun 23

Remote code execution in Gogs through 0.14.2 allows authenticated users (and unauthenticated attackers on default-config

CVE-2026-56274 HIGH POC
8.7 Jun 23

Remote code execution in Flowise before 3.1.2 allows any authenticated user (or API caller with chatflow view/update per

CVE-2026-34156 CRITICAL POC
9.9 Mar 30

Remote code execution in NocoBase Workflow Script Node (npm @nocobase/plugin-workflow-javascript) allows authenticated l

CVE-2019-15752 HIGH POC
7.8 Aug 28

Docker Desktop Community Edition before 2.1.0.1 allows local users to gain privileges by placing a Trojan horse docker-c

CVE-2025-34221 CRITICAL POC
10.0 Sep 29

Vasion Print (formerly PrinterLogic) Virtual Appliance Host prior to version 25.2.169 and Application prior to version 2

Share

CVE-2026-48978 vulnerability details – vuln.today

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy