CVE-2026-26231: Gitea Permission Bypass Allows Unauthorized Code Commits
Gitea, a self-hosted Git service, contains a permission logic flaw that allows authenticated users to bypass write restrictions on repositories. Specifically, the "Allow edits from maintainers" permission setting can be misused to authorize commits to repositories the attacker can only read. This means a user with read-only access could potentially modify code they should not be allowed to change, undermining code integrity and access control.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 8.5 HIGH · CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:H/A:N
- Weaknesses (CWE)
- CWE-863
- Affected products
- 0 configuration(s)
- Published / Modified
- 2026-07-03 / 2026-07-07
NVD description (verbatim)
Gitea versions up to and including 1.26.1 allow the Allow edits from maintainers permission path to authorize commits to repositories that the user can read but should not be able to write.
6 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
CVE-2026-26231 is an authorization bypass vulnerability in Gitea up to version 1.26.1. The flaw resides in how the application evaluates the "Allow edits from maintainers" permission. An authenticated attacker with read access to a repository can manipulate or exploit this permission model to gain unintended write capabilities. The vulnerability is classified under CWE-863 (Incorrect Authorization), indicating a gap between intended and actual access control enforcement. The CVSS 3.1 score of 8.5 reflects the combination of network-based exploitation (AV:N), low complexity (AC:L), low privilege requirements (PR:L), and high integrity impact (I:H), though availability is unaffected.
Business impact
This vulnerability directly threatens code integrity in development workflows. An attacker could inject malicious code, alter commits, or compromise software supply chains without detection if the read-only permission model is trusted as an enforcement boundary. For organizations using Gitea as a central repository, this creates a critical trust gap—developers and auditors may believe certain repositories are protected from modification when they are not. The risk is amplified in CI/CD pipelines that trust repository integrity as a gate for deployment or release decisions.
Affected systems
Gitea versions 1.26.1 and earlier are affected. The vulnerability requires that a user be authenticated and have at least read access to a target repository; repositories with public read access or those shared with read-only team members are at elevated risk. Self-hosted Gitea instances are the primary exposure surface, though the scope of impact depends on repository sharing policies and the sensitivity of repositories involved.
Exploitability
The vulnerability is readily exploitable by any authenticated Gitea user. No special privileges, complex interactions, or user interaction is required beyond standard Git operations. An attacker with read access can perform the malicious action directly, making this a low-friction attack with a low barrier to entry. However, exploitation requires network access to a Gitea instance and valid credentials, preventing completely unauthenticated abuse.
Remediation
Update Gitea to a patched version released after 1.26.1. Verify against the official Gitea security advisory for the exact fixed version number and upgrade timeline. Until patching is possible, review repository permission configurations, especially the use of "Allow edits from maintainers" on sensitive repositories. Consider restricting read access to trusted users or enforcing stricter code review and approval workflows to detect unauthorized commits.
Patch guidance
Apply the latest Gitea release that addresses CVE-2026-26231. Consult the official Gitea project repository or security advisory for the specific version number and installation instructions. Test the patch in a non-production environment first to ensure compatibility with custom configurations or extensions. After upgrade, validate that permission controls function as intended by testing read-only access scenarios.
Detection guidance
Monitor Gitea commit logs and audit trails for commits authored by users with only read-level repository access. Flag any write operations (commits, pushes) originating from accounts lacking explicit write permissions. Implement alerts on Git hook logs for unexpected authorization paths. Review permission audit logs for changes to "Allow edits from maintainers" settings on sensitive repositories. Search for commits made shortly after repository access was granted at the read-only level.
Why prioritize this
This vulnerability rates HIGH due to the combination of high integrity impact, low exploitation complexity, and the foundational role repository integrity plays in software development. The bypass of permission controls is a critical failure in access control design. Organizations should prioritize patching within weeks rather than months, especially if Gitea instances host proprietary code or are integrated into release pipelines.
Risk score, explained
The CVSS 3.1 score of 8.5 reflects a network-accessible vulnerability (AV:N) that requires only low-level authentication (PR:L) with no special conditions or user interaction (AC:L, UI:N). The high integrity impact (I:H)—the ability to modify code without authorization—is the primary driver of severity. The scope change (S:C) indicates that impact extends beyond the vulnerable component to the integrity of dependent systems. Confidentiality impact is low (C:L) and availability is unaffected (A:N), as the attack focuses on unauthorized modification rather than disclosure or denial of service.
Frequently asked questions
Can an unauthenticated user exploit this vulnerability?
No. The vulnerability requires valid authentication credentials and at least read-level access to the target repository. Unauthenticated users cannot trigger the permission bypass.
Does this affect only public repositories?
No. Any repository configured with read-only access for a user or team is at risk. This includes private repositories shared with read-only permissions, making the scope broader than public instances alone.
Will upgrading Gitea affect my existing repositories or custom settings?
Upgrading should not modify your existing repositories or data. However, you should always test upgrades in a staging environment first, especially if you rely on custom hooks, extensions, or unusual permission configurations. Refer to Gitea's upgrade documentation for version-specific migration notes.
How can I determine if someone has exploited this vulnerability in my Gitea instance?
Review your Git commit logs and Gitea audit logs for commits from users who should have had only read access. Look for commits made to sensitive repositories during the period after the user was granted read-only access. Enable and monitor Gitea's event audit log if available, and consider running a full permission audit to validate that current access levels match intended policies.
This analysis is based on publicly available information as of the modification date (July 7, 2026). CVSS scores, affected versions, and patch availability are current as of that time; verify against official Gitea security advisories and vendor releases for the most up-to-date status. This information is provided for educational and defensive purposes only. Organizations should conduct their own risk assessment in the context of their specific Gitea deployments, repository configurations, and threat models. Source: NVD (public-domain), retrieved 2026-08-12. Analysis generated by SEC.co (claude-haiku-4-5).
Weaknesses (CWE)
Related vulnerabilities
- CVE-2016-20075HIGHWordPress Ultimate Product Catalog 3.8.6 Arbitrary File Upload (CVSS 8.8)
- CVE-2025-14774HIGHABB T-MAC Plus Denial-of-Service Vulnerability (CVSS 7.4)
- CVE-2025-32348HIGHAndroid Local Privilege Escalation via Missing Permission Check
- CVE-2026-0272HIGHPalo Alto PAN-OS Privilege Escalation Vulnerability (PA-Series, VM-Series, Panorama)
- CVE-2026-14536HIGHDevolutions Server MFA Bypass – High Severity Authentication Flaw
- CVE-2026-15125HIGHChrome Forms Code Execution Vulnerability
- CVE-2026-21031HIGHAppBlock Authorization Flaw in Samsung Android—Risk & Patch Guidance
- CVE-2026-22659HIGHFlaskBB Authorization Bypass in Batch Topic Operations