CVE-2026-123002

Gitea missing attempt limit for TOTP passcodes

Published Nov 15, 2026 CVSS n/a EPSS n/a KEV · Not listed
Description
Gitea accepted an unlimited number of wrong TOTP passcodes during sign-in, in the password reset flow and for Basic authentication with the `X-Gitea-OTP` header. An attacker who already knows an account's password could guess the six-digit passcode by trying codes at a high rate and sign in despite two-factor authentication. After five failed passcodes, further attempts for the account are now refused for 15 minutes.

Analysis

AI-generated

Technical impact

Gitea allows unlimited attempts to enter the six-digit TOTP during sign‑in, password reset, or Basic authentication with the X‑Gitea‑OTP header. An attacker who already knows the account’s password can brute‑force the code at a high rate, bypassing two‑factor authentication and gaining access. The vulnerability therefore undermines the confidentiality of user accounts and violates the intentional design of the authentication workflow.

Affected Systems

The flaw appears in all Gitea installations that have not applied the 28.4.0 release. Any version prior to 28.4.0 that consumes the default authentication flow is susceptible; the fix is included in v28.4.0, where five failed passcode attempts now lock the account for 15 minutes.

Risk and Exploitability

Although no CVSS or EPSS values are published for this issue, the vulnerability offers a straightforward and automated exploitation path for attackers who own the password. Because the system accepts an unbounded number of TOTP guesses, brute‑forcing is practical, especially for six‑digit numeric codes with a short time window. The attack requires only standard authentication tools and does not need any privileged access. There is no evidence of exploitation in the wild, and the vulnerability is not listed in CISA KEV, but the potential for credential compromise remains high.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the Gitea instance to version 28.4.0 or later to enforce a five‑attempt limit and account lockout.
  • If an upgrade is not immediately possible, temporarily enforce account lockout after five failed TOTP attempts through configuration or custom scripting.
  • Continuously monitor authentication logs for repeated failed TOTP entries and investigate any abnormal activity promptly.

Generated by OpenCVE AI on November 15, 2026 at 22:23 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Gitea
Gitea gitea
Vendors & Products Gitea
Gitea gitea
Type Values Removed Values Added
Description Gitea accepted an unlimited number of wrong TOTP passcodes during sign-in, in the password reset flow and for Basic authentication with the `X-Gitea-OTP` header. An attacker who already knows an account's password could guess the six-digit passcode by trying codes at a high rate and sign in despite two-factor authentication. After five failed passcodes, further attempts for the account are now refused for 15 minutes.
Title Gitea missing attempt limit for TOTP passcodes
Weaknesses CWE-307
References
Weaknesses
  • CWE-307

    Improper Restriction of Excessive Authentication Attempts

Sources

Status
PUBLISHED
Assigner
Gitea
Published
Updated
Nov 15, 2026, 9:13 PM
Reserved
Nov 15, 2026, 8:29 PM
Status
Deferred
Published
Nov 15, 2026, 10:17 PM
Modified
Nov 15, 2026, 10:17 PM