Email JavaScript Cloak <= 1.03 - Unauthenticated Stored Cross-Site Scripting
Description
The Email JavaScript Cloak plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the plugin's 'email' shortcode in all versions up to, and including, 1.03 due to insufficient input sanitization and output escaping on user supplied attributes. 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.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Affected products
1- Range: <=1.03
Patches
Vulnerability mechanics
Root cause
"The plugin's shortcode callback returns user-supplied attribute values directly into HTML output without sanitization or escaping."
Attack vector
An authenticated attacker with contributor-level access or higher inserts a `[email ...]` shortcode into a post or page. The attribute value is captured by the regex `\[ *email +([^\]]*)\]` and passed directly into the callback, which returns it wrapped in a `<span>` tag without escaping [ref_id=1][ref_id=2]. Because the plugin filters `the_content`, `the_excerpt`, `widget_text`, `comment_text`, and `comment_excerpt`, the injected script executes whenever any user views the affected content.
Affected code
The vulnerable code is in `email-js-cloak.php` in the `email_js_cloak_regex_callback` function (lines 68–80). The function takes the user-supplied attribute from the `[email ...]` shortcode and directly embeds it into the HTML output without any sanitization or escaping, allowing arbitrary HTML and JavaScript injection.
What the fix does
The advisory states the vulnerability exists because of insufficient input sanitization and output escaping on user-supplied attributes. The patch is not shown in the bundle, but the fix would require escaping the `$email_cloak` value (e.g., with `esc_html()` or `wp_kses()`) before returning it in the `<span>` element, preventing arbitrary HTML and script injection.
Preconditions
- authAttacker must have at least contributor-level access to create or edit posts/pages
- configThe target content must be processed by one of the plugin's registered filters (the_content, the_excerpt, widget_text, comment_text, comment_excerpt)
Generated on Jun 24, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
3News mentions
0No linked articles in our index yet.