CVE-2026-96400

Gitea migration SSRF to reserved addresses through ALLOWED_DOMAINS

Published Oct 6, 2026 CVSS 3.1 · 4.3 Medium EPSS < 1% KEV · Not listed
Description
With `[migrations] ALLOWED_DOMAINS` set to a matching entry such as `*` or a hostname wildcard, Gitea's migration URL validation could permit reserved and link-local addresses, such as `169.254.169.254`, even when `ALLOW_LOCALNETWORKS = false`. The local-network block list did not cover these ranges, and a hostname matching the allow list was accepted regardless of its resolved address. A user who can start migrations on such an instance could reach these addresses from the Gitea server; the default empty `ALLOWED_DOMAINS` configuration is not affected.

Analysis

AI-generated

Technical impact

An improper validation of migration URLs allowed Gitea to treat reserved and link‑local addresses as legitimate when the ALLOWED_DOMAINS setting contained a wildcard such as * or a hostname pattern. This flaw enabled a Server‑Side Request Forgery that bypasses the service’s local‑network filter, allowing an attacker to reach internal endpoints like 169.254.169.254. The weakness is an instance of CWE‑918, leading to potential unauthorized access to internal metadata services or other sensitive resources.

Affected Systems

Any running instance of Gitea with the ALLOWED_DOMAINS configuration set to * or a host wildcard, in versions before the 28.0.0 release, is affected. The vulnerability remains in the default configuration only when ALLOWED_DOMAINS is explicitly modified, so installations that leave the setting empty are not impacted. The issue applies to the Gitea server component.

Risk and Exploitability

Exploitability depends on user permissions; an attacker must be able to initiate a migration action on the server. Once that privilege is present, the flaw can force the server to connect to arbitrary internal addresses, exposing internal services. The EPSS score is not available, and the vulnerability is not listed in CISA’s KEV catalog, but the lack of network restrictions combined with the potential to reach sensitive internal endpoints remains a concern. The CVSS score of 4.3 classifies the severity as moderate, suggesting a medium risk scenario.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the Gitea installation to version 28.0.0 or later, which incorporates a fix to the migration URL validation logic.
  • Restrict the ALLOWED_DOMAINS setting to only the necessary domains, removing * or general hostname wildcards, and review any custom entries for compliance with security policy.
  • Keep ALLOW_LOCALNETWORKS set to false and validate that the local‑network block list remains effective; consider revisiting that configuration if future changes occur.

Generated by OpenCVE AI on October 7, 2026 at 13:45 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
CPEs cpe:2.3:a:gitea:gitea:*:*:*:*:*:*:*:*
Type Values Removed Values Added
Metrics cvssV3_1

{'score': 4.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N'}

ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Gitea
Gitea gitea
Vendors & Products Gitea
Gitea gitea
Type Values Removed Values Added
Description With `[migrations] ALLOWED_DOMAINS` set to a matching entry such as `*` or a hostname wildcard, Gitea's migration URL validation could permit reserved and link-local addresses, such as `169.254.169.254`, even when `ALLOW_LOCALNETWORKS = false`. The local-network block list did not cover these ranges, and a hostname matching the allow list was accepted regardless of its resolved address. A user who can start migrations on such an instance could reach these addresses from the Gitea server; the default empty `ALLOWED_DOMAINS` configuration is not affected.
Title Gitea migration SSRF to reserved addresses through ALLOWED_DOMAINS
Weaknesses CWE-918
References
Weaknesses
  • CWE-918

    Server-Side Request Forgery (SSRF)

Sources

Status
PUBLISHED
Assigner
Gitea
Published
Updated
Oct 7, 2026, 11:35 AM
Reserved
Oct 4, 2026, 9:59 PM
Status
Analyzed
Published
Oct 6, 2026, 8:17 PM
Modified
Oct 13, 2026, 3:36 PM