Skip to main content

Suse CVE-2026-20706

| EUVDEUVD-2026-41612 CRITICAL
Incorrect Authorization (CWE-863)
2026-06-16 https://github.com/go-gitea/gitea GHSA-cr4g-f395-h25h
9.1
CVSS 3.1 · Vendor: https://github.com/go-gitea/gitea
Share

Severity by source

Vendor (https://github.com/go-gitea/gitea) PRIMARY
9.1 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
vuln.today AI
6.5 MEDIUM

Requires a valid low-scope personal access token, so PR:L not PR:N; endpoint only serves read-only archives, so C:H but I:N and A:N.

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

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

CVSS VectorVendor: https://github.com/go-gitea/gitea

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

Lifecycle Timeline

7
Analysis Updated
Jul 06, 2026 - 19:36 vuln.today
v3 (cvss_changed)
Analysis Updated
Jul 06, 2026 - 19:36 vuln.today
v2 (cvss_changed)
Re-analysis Queued
Jul 06, 2026 - 19:22 vuln.today
cvss_changed
CVSS changed
Jul 06, 2026 - 19:22 NVD
9.1 (CRITICAL)
Source Code Evidence Fetched
Jun 17, 2026 - 00:37 vuln.today
Analysis Generated
Jun 17, 2026 - 00:37 vuln.today
CVE Published
Jun 16, 2026 - 23:42 cve.org
CRITICAL 9.1

DescriptionCVE.org

Summary

PR #37698 added checkDownloadTokenScope to /raw/*, /media/*, and attachment download web endpoints. The /archive/* endpoint (repo.Download in routers/web/repo/repo.go:372) was not included in the fix. This endpoint accepts OAuth2 tokens via webAuth.AllowOAuth2 (registered at routers/web/web.go:1649-1652) but does not call checkDownloadTokenScope or CheckRepoScopedToken.

A personal access token with any non-repository scope (e.g., read:issue or read:misc) can download full repository archives (zip/tar.gz) of private repositories the token owner has access to.

Impact

Scope escalation: tokens scoped to non-repository categories can access full repository content through the archive download endpoint. Higher impact than endpoints fixed in #37698 because /archive/* serves the entire repository.

Steps to Reproduce

  1. Create a personal access token with ONLY read:misc scope
  2. Access: GET /{owner}/{private-repo}/archive/main.tar.gz
  3. Archive is served (200 OK) instead of being rejected (403 Forbidden)

Compare with fixed endpoints:

  • GET /{owner}/{private-repo}/raw/branch/main/README.md correctly returns 403

Root Cause

Download function in routers/web/repo/repo.go:372 does not call checkDownloadTokenScope. The outer group middleware reqUnitCodeReader checks repository permission but not token scope.

The API equivalent (/api/v1/repos/{owner}/{repo}/archive/*) IS properly scoped via tokenRequiresScopes(AccessTokenScopeCategoryRepository). The git HTTP endpoints are scoped via CheckRepoScopedToken in httpBase.

Suggested Fix

Add checkDownloadTokenScope(ctx) to Download and InitiateDownload in routers/web/repo/repo.go. The function already exists in routers/web/repo/download.go (same package).

Discovery Method

Variant analysis of PR #37698 - reviewed all web routes with webAuth.AllowOAuth2 middleware.

AnalysisAI

Authorization bypass in Gitea 1.26.1 and earlier allows attackers with personal access tokens scoped to non-repository categories (e.g., read:issue or read:misc) to download full repository archives of private repositories they have access to. This bypass stems from a missing token scope check in the /archive/* web endpoint, while other download endpoints (/raw/*, /media/*) were properly secured. Exploitation probability is low based on EPSS, and no active exploitation or KEV listing exists at this time; however, trivial exploit steps are publicly documented.

Vendor StatusVendor

SUSE

Severity: Critical
Product Status
SUSE Linux Enterprise Server 16.1 Affected
SUSE Linux Enterprise Server for SAP applications 16.1 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP5 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP6 Affected
openSUSE Leap 15.5 Affected

Share

CVE-2026-20706 vulnerability details – vuln.today

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