Magic Login Mail or QR Code <= 2.07 - Unauthenticated Privilege Escalation via Account Takeover to Host Header Injection in curpageurl() Magic-Login URL
Strategic Overview
- Status
- Patched in 2.08
- Affected Plugin
- Magic Login Mail or QR Code
- Affected Version
<= 2.07- CVSS
- 7.5High
- Weakness type
- CWE-269 · Improper Privilege Management
- CVE
CVE-2026-126721
At a glance
CVE-2026-126721 is a high-severity Improper Privilege Management vulnerability in the Magic Login Mail or QR Code WordPress plugin, affecting versions <= 2.07. It carries a CVSS score of 7.5 (reachable over the network; high confidentiality, integrity, availability impact). Exploitation requires no authentication. The issue is fixed in version 2.08; sites on affected versions should update now. Disclosed November 2026, reported by se1ynn22.
Vulnerability Overview
The Magic Login Mail or QR Code plugin for WordPress is vulnerable to Privilege Escalation via Administrator Account Takeover in versions up to, and including, 2.07. This is due to the `curpageurl()` function falling back to the raw `$_SERVER['HTTP_HOST']` value — with no validation against the site's configured origin via `home_url()` or `site_url()` — when `get_the_permalink()` returns empty or false, allowing an attacker-controlled Host header to become the URL origin of the magic-login link generated by `generate_url()` and delivered to the target via `wp_mail()`. This makes it possible for unauthenticated attackers to intercept the one-time uid and token pair sent to a targeted Administrator's email and replay them against the real site, causing `autologin_via_url()` to call `wp_set_auth_cookie()` and establish a full Administrator session on the targeted account. Exploitation requires the `[magic_login]` shortcode to render on a path where `get_the_permalink()` returns empty or false (such as a 404 page or a block-theme header template part), the web server to forward non-canonical Host headers, the attacker to know the target administrator's email address, and the administrator to click the attacker-originated magic-login link. Successful exploitation gives the attacker control of a distinct, already-privileged Administrator account; it does not promote the attacker's original account. Successful exploitation additionally requires an action by an administrator — the attacker cannot trigger the vulnerability on their own.
Technical Analysis
The vector marks this flaw as remotely reachable over the network, and no privileges on the target site. A successful exploit has high impact on confidentiality, integrity, availability — full site compromise territory.
CWE-269: Improper Privilege Management
Magic Login Mail or QR Code <= 2.07 carries this weakness at HTTP_HOST, and reaching it takes no account at all. Improper privilege management means the code lets an account end up with capabilities its role should not have.
It converts a low-privileged account into an administrative one, which makes every other restriction on the site irrelevant. For Magic Login Mail or QR Code the fix is 2.08: builds <= 2.07 are affected, anything from 2.08 onward is not.
Remediation
Update to version 2.08, or a newer patched version
How does WordSec protect against this?
This one needs no account at all, which puts it outside what login hardening can reach; WordSec's login security narrows the account-level paths around it, and the firewall is what inspects the request itself. None of that substitutes for the fix: Magic Login Mail or QR Code 2.08 closes this, and updating the plugin is the step that ends it.
- Login Security
- Alerts
External References
Related records
Vulnerability data © Defiant, Inc., provided under the Wordfence Intelligence T&C