CVE-2026-25232 in Gogsinfo

Summary

by MITRE • 02/19/2026

Gogs is an open source self-hosted Git service. Versions 0.13.4 and below have an access control bypass vulnerability which allows any repository collaborator with Write permissions to delete protected branches (including the default branch) by sending a direct POST request, completely bypassing the branch protection mechanism. This vulnerability in the DeleteBranchPost function eenables privilege escalation from Write to Admin level, allowing low-privilege users to perform dangerous operations that should be restricted to administrators only. Although Git Hook layer correctly prevents protected branch deletion via SSH push, the web interface deletion operation does not trigger Git Hooks, resulting in complete bypass of protection mechanisms. In oder to exploit this vulnerability, attackers must have write permissions to the target repository, protected branches configured to the target repository and access to the Gogs web interface. This issue has been fixed in version 0.14.1.

Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Analysis

by VulDB Data Team • 02/21/2026

The vulnerability identified as CVE-2026-25232 affects Gogs, an open source self-hosted Git service that has gained significant adoption among organizations seeking to maintain control over their version control infrastructure. This security flaw represents a critical access control bypass that undermines the fundamental security model of repository protection mechanisms. The vulnerability specifically targets the DeleteBranchPost function within Gogs versions 0.13.4 and earlier, creating a dangerous pathway for privilege escalation that could compromise entire repository security postures.

The technical implementation of this vulnerability stems from a design flaw in how Gogs handles branch deletion operations through its web interface. While the system correctly implements Git Hooks to prevent protected branch deletion via SSH push operations, the web-based deletion functionality operates independently of these protective mechanisms. This creates a scenario where the same underlying system that enforces branch protection through Git Hooks fails to apply equivalent protections when users interact through the web interface. The DeleteBranchPost function lacks proper authorization checks that would normally validate whether the requesting user possesses sufficient privileges to perform destructive operations on protected branches.

The operational impact of this vulnerability extends far beyond simple privilege escalation, creating a pathway for attackers to achieve administrative-level control over repository configurations. A collaborator with write permissions can exploit this flaw to delete protected branches, including the default branch that typically serves as the primary reference point for repository operations. This capability represents a complete bypass of the intended access control model where only administrators should possess the authority to perform such destructive operations. The vulnerability enables what cybersecurity frameworks would classify as a privilege escalation attack, specifically mapping to CWE-284 which addresses improper access control in software systems. This type of vulnerability is particularly dangerous because it allows attackers to undermine repository integrity and potentially disrupt critical development workflows.

The exploitation requirements for this vulnerability are relatively straightforward yet significant in their implications. Attackers need only possess write permissions to a target repository, have access to the Gogs web interface, and be aware of protected branch configurations within that repository. This accessibility makes the vulnerability particularly concerning for organizations that grant write permissions broadly to development teams without proper segregation of duties. The fact that this issue has been resolved in version 0.14.1 demonstrates the importance of timely patch management for open source software, as organizations using vulnerable versions remain at risk of exploitation. Organizations implementing the ATT&CK framework would categorize this vulnerability under privilege escalation techniques, specifically targeting the T1078 credential access tactic, where attackers leverage existing legitimate credentials to gain elevated privileges.

The security implications of this vulnerability extend to broader organizational security practices, particularly around the principle of least privilege and proper access control implementation. This flaw demonstrates how seemingly isolated functionality can create cascading security risks when protection mechanisms are not consistently applied across all user interaction points. The vulnerability highlights the importance of comprehensive security testing that includes both API endpoints and web interface operations, as both pathways should enforce equivalent protection controls. Organizations utilizing Gogs or similar Git services should conduct immediate vulnerability assessments to identify affected systems and implement appropriate mitigation strategies, including immediate patching, access control reviews, and monitoring for suspicious deletion activities within repository management interfaces.

Responsible

GitHub M

Reservation

01/30/2026

Disclosure

02/19/2026

Moderation

accepted

CPE

ready

EPSS

0.00016

KEV

no

Activities

very low

Sources

Want to stay up to date on a daily basis?

Enable the mail alert feature now!