What the vulnerability does
01Description
The Code Embed plugin for WordPress is vulnerable to Stored Cross-Site Scripting via custom field meta values in all versions up to, and including, 2.5.1. This is due to the plugin's sanitization function `sec_check_post_fields()` only running on the `save_post` hook, while WordPress allows custom fields to be added via the `wp_ajax_add_meta` AJAX endpoint without triggering `save_post`. The `ce_filter()` function then outputs these unsanitized meta values directly into page content without escaping. This makes it possible for authenticated attackers, with Contributor-level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page.
Explanation of Vulnerability in Simple Terms
02Summary
Code Embed versions up to 2.5.1 contain a cross-site scripting (XSS) vulnerability that allows authenticated users to inject malicious scripts. The vulnerability has a changed scope, meaning the impact can extend beyond the vulnerable component to affect other users or site functionality. An attacker with low-level privileges can inject code that executes in other users' browsers without requiring user interaction.
What an attacker can do
03Attacker Capabilities
Inject malicious scripts that execute in other users' browsers and affect site functionality.
Potential impact on your site
04Site Impact
Authenticated users can inject scripts affecting other users' sessions, data, or site behavior.
Conditions required to exploit
05Prerequisites
Attacker must have a low-level user account on the site; no user interaction required.
Key dates
06Disclosure timeline
March 18, 2026
CVE published
April 8, 2026
Record updated