Atomic Edge analysis of CVE-2026-103886: The App Builder plugin (versions up to 5.7.1) contains an authentication bypass in its Google login flow. The REST endpoint `/app-builder/v1/login` accepts a Google ID token and issues a signed App Builder JWT without properly validating the token’s audience or binding it to the target site’s OAuth client. This allows an unauthenticated attacker to impersonate any existing WordPress user by supplying a Google ID token from an unrelated OAuth client that carries the victim’s email address. The vulnerability has a CVSS score of 8.1 (High) and CWE-287 (Improper Authentication).
Root Cause: The vulnerability stems from multiple flaws in `LoginGoogle::login()` within `app-builder/includes/Di/Service/Auth/Login/LoginGoogle.php`. First, the function decodes the Google ID token via the `/tokeninfo` endpoint but never validates the `aud` (audience) claim against the site’s own OAuth client IDs. Second, it fails to verify the `email_verified` claim, allowing unverified email addresses to be trusted. Third, it resolves WordPress accounts solely by the email claim (`get_user_by(’email’, $email)`) without binding the account to the Google `sub` (subject) identifier, meaning any Google token with a matching email grants access. Fourth, the REST endpoint `/app-builder/v1/login` is registered with a `permission_callback` that unconditionally returns `true`, making it reachable by unauthenticated attackers. The patch introduces `SocialLoginTrait` to enforce audience validation, subject binding, and email verification, and adds settings for allowed client IDs.
Exploitation: An attacker can exploit this by first obtaining a valid Google-signed ID token that contains the victim’s email address. The attacker can operate a separate Google OAuth client (e.g., a malicious app) and induce the victim to authenticate through it, thereby obtaining an ID token with the victim’s email. Alternatively, if the attacker knows the victim’s email, they can craft a token using any Google OAuth client that they control, as the plugin does not validate the audience. The attacker then sends a POST request to `/wp-json/app-builder/v1/login` with the `idToken` parameter set to the obtained token. The plugin’s `LoginGoogle::login()` will decode the token, extract the email, find the corresponding WordPress user (e.g., an administrator), and issue a signed App Builder JWT granting full privileges. The attack requires no authentication and can be executed remotely.
Patch Analysis: The patch (version 5.7.2) adds comprehensive validation in `LoginGoogle::login()`. It now checks the token issuer against `accounts.google.com` or `https://accounts.google.com`, validates the `aud` claim against a list of allowed client IDs retrieved from the `login_google` feature settings, verifies the `exp` (expiration) claim, ensures the `sub` claim exists, and checks that `email_verified` is true. The patch also introduces a `SocialLoginTrait` that provides methods for audience checking, subject lookup, and binding. The login flow now first searches for a user by the Google `sub` (stored in user meta) and only falls back to email linking if the email is verified and not already bound to a different subject. The REST endpoint’s `permission_callback` is not shown in the diff, but the addition of feature settings and validation implies that unauthenticated access is restricted. The patch effectively closes the bypass by requiring tokens to be issued for the site’s own OAuth clients and by binding accounts to the Google subject identifier.
Impact: Successful exploitation allows an unauthenticated attacker to authenticate as any existing WordPress user, including administrators. This leads to full privilege escalation, enabling the attacker to take over the site, install malicious plugins, modify content, exfiltrate sensitive data, and potentially achieve remote code execution. The vulnerability poses a critical risk to sites using the App Builder plugin with Google login enabled.

