LiveActive security incident?Get immediate response
CVE Record

CVE-2026-4021: Contest Gallery <= 28.1.5 - Unauthenticated Privilege Escalation Admin Account Takeover via Registration Confirmation Email-to-ID Type Confusion

The Contest Gallery plugin for WordPress is vulnerable to an authentication bypass leading to admin account takeover in all versions up to, and including, 28.1.5. This is due to the email confirmation handler in `users-registry-check-after-email-or-pin-confirmation.php` using the user's email string in a `WHERE ID = %s` clause instead of the numeric user ID, combined with an unauthenticated key-based login endpoint in `ajax-functions-frontend.php`. When the non-default `RegMailOptional=1` setting is enabled, an attacker can register with a crafted email starting with the target user ID (e.g., `1poc@example.test`), trigger the confirmation flow to overwrite the admin's `user_activation_key` via MySQL integer coercion, and then use the `post_cg1l_login_user_by_key` AJAX action to authenticate as the admin without any credentials. This makes it possible for unauthenticated attackers to take over any WordPress administrator account and gain full site control.

HighCVSS 8.1Not KEV-listedUpdated
Glexia's TakeAutomated analysishigh

Security readout for executives and security teams

Plain-English summary

CVE-2026-4021 affects the Contest Gallery WordPress plugin. On sites using vulnerable versions and a non-default registration setting, an unauthenticated attacker could take over an administrator account. That can mean full control of the WordPress site, including content, users, and installed plugins.

Executive priority

Treat as urgent for WordPress sites using Contest Gallery with public registration features. Prioritize internet-facing sites first. The business risk is full site takeover, but exposure depends on a specific non-default setting and vulnerable plugin version.

Technical view

The flaw combines an email-to-user-ID type confusion in the registration confirmation handler with an unauthenticated key-based login AJAX endpoint. Sources describe vulnerable Contest Gallery versions up to and including 28.1.5. The issue depends on RegMailOptional=1 being enabled, which is not the default.

Likely exposure

Exposure is limited to WordPress sites running Contest Gallery up to 28.1.5 with RegMailOptional=1 enabled. Sites not using the plugin, using a fixed later version, or not enabling that setting are less likely to be exposed to the described path.

Exploitation context

The CVE is not listed as KEV, and the provided sources do not state active exploitation. Exploitation is unauthenticated but condition-dependent, requiring the vulnerable registration flow and non-default configuration. Successful exploitation could result in administrator account takeover.

Researcher notes

Key code references are the registration confirmation file using an email value in an ID comparison and the frontend AJAX key-login function. The bundle cites WordPress Trac lines and a 28.1.5-to-28.1.6 changeset. Avoid assuming exploitation beyond the provided evidence.

Mitigation direction

  • Inventory WordPress sites for the Contest Gallery plugin and installed version.
  • Upgrade to a version newer than 28.1.5; sources reference changeset to 28.1.6.
  • If immediate upgrade is unavailable, disable the plugin until vendor guidance is applied.
  • Review and disable RegMailOptional=1 unless business-required.
  • Rotate administrator sessions and review admin accounts after remediation.

Validation and detection

  • Confirm whether Contest Gallery is installed and whether its version is 28.1.5 or older.
  • Check plugin settings for RegMailOptional=1.
  • Review WordPress logs for unusual registrations and confirmation activity.
  • Look for unexpected administrator sessions or account changes.
  • Verify the plugin is updated beyond the affected version after remediation.
Prepared
Confidence
high
Sources
8

Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.

Potential ATT&CK relevance

Conservative CVE-to-ATT&CK context

These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.

ATT&CK lookup starting points

Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.

cwe · medium confidence lookup

CWE-287: Credential and account abuse lookup

Authentication and credential weaknesses can make valid-account abuse and credential telemetry useful review starting points. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.

Open ATT&CK lookup
description · low confidence lookup

Credential and access behavior lookup

The CVE wording references authentication or credential exposure, so valid-account and credential-access review may help. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.

Open ATT&CK lookup
description · low confidence lookup

Privilege behavior lookup

The CVE wording references privilege impact, so privilege escalation and authorization behavior review may help. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.

Open ATT&CK lookup
cve · low confidence lookup

CVE-2026-4021 mapping review

Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.

Open ATT&CK lookup
Vulnerability profileCVE Program record
Severity
High
CVSS
8.1 (3.1)
Known Exploited
No
Published

Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Official CVE source material

CNA and ADP enrichment extracted from CVE v5

These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.

1CVSS vectors
0Timeline events
0ADP providers
7Source links

CVSS vector scores

1 official score

We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.

ScoreVersionSeverityVectorExploitImpactSource
8.1CVSS 3.1HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H2.25.9Primary CVE score

Vulnerability scoring details

Base CVSS 3.1 score

8.1High
CVSS 3.1 vector shape for CVE-2026-4021Attack VectorAttack ComplexityPrivileges RequiredUser InteractionScopeConfidentiality ImpactIntegrity ImpactAvailability Impact

Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Attack Vector
NetworkAdjacentLocalPhysical
Attack Complexity
LowHigh
Privileges Required
NoneLowHigh
User Interaction
NoneRequired
Scope
ChangedUnchanged
Confidentiality Impact
HighLowNone
Integrity Impact
HighLowNone
Availability Impact
HighLowNone
Affected products

Products and packages named in the record

VendorProductVersion / packageStatus
contest-galleryContest Gallery – Upload & Vote Photos, Media, Sell with PayPal & Stripe0unaffected
Weakness

CWE details

CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.

CWE-287 · source CWE mapping

Improper Authentication

Improper Authentication represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.