/

CVE-2026-55987

Severity:

HIGH RISK

(8.1)

OAuth2 Authorization Bypass (CWE-863) in Auth Sources

CVE-2026-55987

Deferred

Vulnerability type

Category:

Authorization Bypass

CWE:

CWE-863

Impact:

Unauthorized account reactivation and access-control bypass

Severity:

HIGH RISK

(8.1)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

An OAuth2 sign-in flaw can reactivate an account that an administrator previously deactivated when the authentication source does not use refresh tokens. This may allow a person with valid OAuth2 credentials to regain access despite an administrative account-disable action.

Affected context

The issue occurs in authentication flows that support OAuth2 sign-in for external authentication sources without refresh tokens. It becomes risky when an account has been intentionally deactivated by an administrator but the sign-in path treats successful OAuth2 authentication as sufficient to restore or reactivate that account.

Exploit preconditions

  • Attack surface: OAuth2-based sign-in and account synchronization
  • Required access: Valid credentials or an active identity at the connected OAuth2 provider
  • Trigger point: Authentication through an OAuth2 source without refresh-token support
  • Relevant state: The corresponding application account has been deactivated by an administrator
  • Why exploitation is possible: The sign-in flow does not consistently preserve the administrative deactivation state when processing a successful OAuth2 authentication

Why this happens

The underlying bug is an incomplete authorization-state check in the OAuth2 account lifecycle. A successful external authentication is incorrectly allowed to override or bypass a locally enforced account-deactivation decision when refresh-token handling is unavailable. This maps to CWE-863, Incorrect Authorization, because the application fails to enforce an administrator-imposed access restriction consistently across authentication paths.

Potential impact

  • A deactivated user may regain application access
  • Administrative account-disable controls may be bypassed
  • Unauthorized access to the user's previously available data or functions may occur
  • Audit records and account lifecycle policies could become inconsistent
  • Accounts with elevated permissions could create greater organizational risk

General mitigation guidance

Mitigation generally focuses on making local account-state enforcement

authoritative across every authentication mechanism.

Common defensive patterns include:

  • Treating administrator-deactivated accounts as non-signable-in regardless of external provider status
  • Checking local authorization and lifecycle state after OAuth2 authentication succeeds
  • Separating identity authentication from account activation or reactivation decisions
  • Requiring an explicit, authorized administrative workflow for account reactivation
  • Applying the same deactivation policy to OAuth2 flows with and without refresh tokens
  • Limiting privileges and session capabilities for accounts whose lifecycle state is uncertain
  • Recording and monitoring account-state changes and authentication outcomes

How teams detect issues like this

Detection approaches may include:

  • Static analysis and code review for authentication handlers that update account status automatically
  • Tests covering deactivated accounts across every OAuth2 provider and token capability
  • Review of branches that handle missing refresh tokens or first-time sign-in
  • Policy checks requiring local account-state validation after external authentication
  • Monitoring for successful sign-ins or session creation immediately following account deactivation
  • Automated security review tools that identify inconsistent authorization checks across login paths

Sources

SourceLink
blog.gitea.comblog.gitea.com/gitea-1.27.0-is-released/
github.comgithub.com/go-gitea/gitea/releases/tag/v1.27.0
github.comgithub.com/go-gitea/gitea/security/advisories/GHSA-vrhc-jjfc-m3m3

Frequently asked

questions

No. The issue is most relevant to OAuth2 authentication sources that do not

use refresh tokens and that permit a successful sign-in to influence the

local account's activation state.

Exploitation generally requires a valid identity at the connected OAuth2

provider that corresponds to the deactivated application account.

Preserve administrator-deactivated status as an authoritative local control

and require an explicit authorized action before reactivation.

Test account deactivation and reactivation across all authentication paths,

including token edge cases, and enforce identical local authorization checks

after external authentication succeeds.

Find out what's already
exploitable in your codebase.