Skip to content

Authorizer: Zero-click account takeover via OAuth identity linking to unverified email accounts

High severity GitHub Reviewed Published Aug 13, 2026 in authorizerdev/authorizer • Updated Aug 14, 2026

Package

gomod github.com/authorizerdev/authorizer (Go)

Affected versions

< 0.0.0-20260807033110-66fe488fd2a4

Patched versions

0.0.0-20260807033110-66fe488fd2a4

Description

The OAuth callback handler links incoming OAuth identities (Google, GitHub, etc.) to existing accounts matched by email address without verifying that the existing account's email was verified by its original owner. An attacker who pre-registers with a victim's email address (without verifying it) gains persistent password-based access to the victim's account after the victim completes a normal OAuth login. Verified against HEAD (commit 73679fa).

Root Cause

In internal/http_handlers/oauth_callback.go, when an OAuth login occurs for an email that already exists in the database:

Line 125: The existing user is looked up by email:

existingUser, err := h.StorageProvider.GetUserByEmail(ctx, refs.StringValue(user.Email))

Line 164: The OAuth user object is replaced with the existing user:

user = existingUser

Lines 173-176: The OAuth provider is appended to the existing user's signup methods:

signupMethod := existingUser.SignupMethods
if !strings.Contains(signupMethod, provider) {
    signupMethod = signupMethod + "," + provider
}
user.SignupMethods = signupMethod

Lines 179-181: If the existing account's email was NOT verified, it is automatically verified:

if user.EmailVerifiedAt == nil {
    now := time.Now().Unix()
    user.EmailVerifiedAt = &now
}

Line 219: The merged user is saved to the database:

user, err = h.StorageProvider.UpdateUser(ctx, user)

At no point is the existing account's password invalidated or the owner notified that a new OAuth identity was linked.

Attack Chain

  1. Attacker signs up with victim@company.com using email/password. Attacker sets a known password but does NOT click the email verification link. The account exists in the database with EmailVerifiedAt = nil.

  2. Some time later, the real owner of victim@company.com logs in via Google OAuth (a completely normal action).

  3. The OAuth callback at line 125 finds the attacker's existing account by email.

  4. At line 164, the Google OAuth identity is linked to the attacker's account.

  5. At line 179-181, the email is automatically verified (the attacker never verified it, but now it's marked as verified).

  6. At line 175, "google" is appended to the signup methods. The account now has both "basic_auth" and "google" as valid login methods.

  7. The attacker's original password is still valid in the database. It was never cleared, changed, or invalidated.

  8. The attacker logs in with victim@company.com and the password they originally set. They now have full access to the victim's account, including any data the victim added via their Google session.

Why This Is Zero-Click

The victim performs no unusual action. They simply log in via their Google account, which is the expected, secure behavior. The attacker staged the account beforehand and gains access without any further interaction.

This is a classic Account Linking vulnerability (cited in OWASP authentication guidelines). The core logic flaw is a trust boundary violation. Authorizer correctly trusts that Google has verified the email address, but it incorrectly extends that trust to validate the password that was set by the unverified attacker. The attacker maintains persistent, password-based backdoor access to the victim's account, even if the victim later revokes Authorizer's OAuth access from their Google account settings. The password was set before Google was ever involved and is never invalidated by the linking process.

Impact

  • Full account takeover for any user who logs in via OAuth
  • Attacker maintains persistent password-based access even after the victim changes OAuth providers
  • All data the victim creates after OAuth login is accessible to the attacker
  • The victim has no indication their account was pre-staged
  • Affects every OAuth provider configured in Authorizer (Google, GitHub, Facebook, Apple, LinkedIn, Twitter, Discord, Twitch, Roblox, Microsoft)

Suggested Fix

Before linking an OAuth identity to an existing account, verify that the existing account's email is already verified:

existingUser, err := h.StorageProvider.GetUserByEmail(ctx, refs.StringValue(user.Email))
if err == nil {
    // Account exists. Only link if email is already verified.
    if existingUser.EmailVerifiedAt == nil {
        // Email not verified by original owner. Do NOT link.
        // Either: reject the login, or create a new separate account,
        // or delete the unverified account and create a fresh one for the OAuth user.
    }
}

Additionally, when linking a new OAuth identity, invalidate any existing password on the account or require the user to re-authenticate via the original method.

Credit

Koda Reef

References

@lakhansamani lakhansamani published to authorizerdev/authorizer Aug 13, 2026
Published to the GitHub Advisory Database Aug 14, 2026
Reviewed Aug 14, 2026
Last updated Aug 14, 2026

Severity

High

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v4 base metrics

Exploitability Metrics
Attack Vector Network
Attack Complexity Low
Attack Requirements None
Privileges Required None
User interaction Passive
Vulnerable System Impact Metrics
Confidentiality High
Integrity High
Availability High
Subsequent System Impact Metrics
Confidentiality None
Integrity None
Availability None

CVSS v4 base metrics

Exploitability Metrics
Attack Vector: This metric reflects the context by which vulnerability exploitation is possible. This metric value (and consequently the resulting severity) will be larger the more remote (logically, and physically) an attacker can be in order to exploit the vulnerable system. The assumption is that the number of potential attackers for a vulnerability that could be exploited from across a network is larger than the number of potential attackers that could exploit a vulnerability requiring physical access to a device, and therefore warrants a greater severity.
Attack Complexity: This metric captures measurable actions that must be taken by the attacker to actively evade or circumvent existing built-in security-enhancing conditions in order to obtain a working exploit. These are conditions whose primary purpose is to increase security and/or increase exploit engineering complexity. A vulnerability exploitable without a target-specific variable has a lower complexity than a vulnerability that would require non-trivial customization. This metric is meant to capture security mechanisms utilized by the vulnerable system.
Attack Requirements: This metric captures the prerequisite deployment and execution conditions or variables of the vulnerable system that enable the attack. These differ from security-enhancing techniques/technologies (ref Attack Complexity) as the primary purpose of these conditions is not to explicitly mitigate attacks, but rather, emerge naturally as a consequence of the deployment and execution of the vulnerable system.
Privileges Required: This metric describes the level of privileges an attacker must possess prior to successfully exploiting the vulnerability. The method by which the attacker obtains privileged credentials prior to the attack (e.g., free trial accounts), is outside the scope of this metric. Generally, self-service provisioned accounts do not constitute a privilege requirement if the attacker can grant themselves privileges as part of the attack.
User interaction: This metric captures the requirement for a human user, other than the attacker, to participate in the successful compromise of the vulnerable system. This metric determines whether the vulnerability can be exploited solely at the will of the attacker, or whether a separate user (or user-initiated process) must participate in some manner.
Vulnerable System Impact Metrics
Confidentiality: This metric measures the impact to the confidentiality of the information managed by the VULNERABLE SYSTEM due to a successfully exploited vulnerability. Confidentiality refers to limiting information access and disclosure to only authorized users, as well as preventing access by, or disclosure to, unauthorized ones.
Integrity: This metric measures the impact to integrity of a successfully exploited vulnerability. Integrity refers to the trustworthiness and veracity of information. Integrity of the VULNERABLE SYSTEM is impacted when an attacker makes unauthorized modification of system data. Integrity is also impacted when a system user can repudiate critical actions taken in the context of the system (e.g. due to insufficient logging).
Availability: This metric measures the impact to the availability of the VULNERABLE SYSTEM resulting from a successfully exploited vulnerability. While the Confidentiality and Integrity impact metrics apply to the loss of confidentiality or integrity of data (e.g., information, files) used by the system, this metric refers to the loss of availability of the impacted system itself, such as a networked service (e.g., web, database, email). Since availability refers to the accessibility of information resources, attacks that consume network bandwidth, processor cycles, or disk space all impact the availability of a system.
Subsequent System Impact Metrics
Confidentiality: This metric measures the impact to the confidentiality of the information managed by the SUBSEQUENT SYSTEM due to a successfully exploited vulnerability. Confidentiality refers to limiting information access and disclosure to only authorized users, as well as preventing access by, or disclosure to, unauthorized ones.
Integrity: This metric measures the impact to integrity of a successfully exploited vulnerability. Integrity refers to the trustworthiness and veracity of information. Integrity of the SUBSEQUENT SYSTEM is impacted when an attacker makes unauthorized modification of system data. Integrity is also impacted when a system user can repudiate critical actions taken in the context of the system (e.g. due to insufficient logging).
Availability: This metric measures the impact to the availability of the SUBSEQUENT SYSTEM resulting from a successfully exploited vulnerability. While the Confidentiality and Integrity impact metrics apply to the loss of confidentiality or integrity of data (e.g., information, files) used by the system, this metric refers to the loss of availability of the impacted system itself, such as a networked service (e.g., web, database, email). Since availability refers to the accessibility of information resources, attacks that consume network bandwidth, processor cycles, or disk space all impact the availability of a system.
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

EPSS score

Weaknesses

Improper Authentication

When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct. Learn more on MITRE.

CVE ID

CVE-2026-35511

GHSA ID

GHSA-29rf-f4vv-pvq6

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.