CVE-2026-7430: CWE-79 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in saadiqbal Post Snippets – Custom WordPress Code Snippets Customizer
The Post Snippets plugin for WordPress is vulnerable to Stored Cross-Site Scripting in all versions up to, and including, 4.0.19. This is due to insufficient output escaping of imported snippet content when rendering JavaScript variables in the post editor. Specifically, the `jqueryUiDialog()` method in `WPEditor.php` embeds snippet content directly into JavaScript string literals without escaping double quotes (the quote-escaping code on line 214 is commented out). When snippets are imported via the Import/Export feature, the content bypasses WordPress's `wp_magic_quotes()` (which would otherwise add protective backslashes), allowing double quotes in snippet content to break out of the JavaScript string context. This makes it possible for authenticated attackers, with Administrator-level access and above, to inject arbitrary web scripts via a malicious import file that execute whenever any administrator accesses a post editor page. Please note that this does not affect single-site installations as administrators already have the `unfiltered_html` capability.
AI Analysis
Technical Summary
CVE-2026-7430 is a stored cross-site scripting vulnerability in the Post Snippets – Custom WordPress Code Snippets Customizer plugin, affecting all versions up to 4.0.19. The issue is caused by insufficient output escaping of imported snippet content embedded directly into JavaScript string literals within the jqueryUiDialog() method in WPEditor.php. The commented-out quote-escaping code and bypass of WordPress's wp_magic_quotes() during import allow double quotes in snippet content to break out of the JavaScript context. This enables authenticated administrators to inject and execute arbitrary scripts via a crafted import file when accessing the post editor page. Single-site installations are not impacted due to the unfiltered_html capability already granted to administrators.
Potential Impact
An attacker with Administrator-level privileges can inject malicious JavaScript code via the import feature of the plugin. This code executes in the context of the post editor page for any administrator who opens it, potentially leading to session hijacking, privilege escalation, or other script-based attacks. The vulnerability does not affect confidentiality or availability directly but impacts integrity and user trust. Single-site WordPress installations are not affected due to existing capability restrictions.
Mitigation Recommendations
Patch status is not yet confirmed — no official fix or patch links are provided. Administrators should avoid importing snippet content from untrusted sources until a vendor fix is released. Since the vulnerability requires Administrator-level access, restricting administrative privileges and monitoring import activities can reduce risk. Check the vendor advisory regularly for updates on official remediation or patches.
CVE-2026-7430: CWE-79 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in saadiqbal Post Snippets – Custom WordPress Code Snippets Customizer
Description
The Post Snippets plugin for WordPress is vulnerable to Stored Cross-Site Scripting in all versions up to, and including, 4.0.19. This is due to insufficient output escaping of imported snippet content when rendering JavaScript variables in the post editor. Specifically, the `jqueryUiDialog()` method in `WPEditor.php` embeds snippet content directly into JavaScript string literals without escaping double quotes (the quote-escaping code on line 214 is commented out). When snippets are imported via the Import/Export feature, the content bypasses WordPress's `wp_magic_quotes()` (which would otherwise add protective backslashes), allowing double quotes in snippet content to break out of the JavaScript string context. This makes it possible for authenticated attackers, with Administrator-level access and above, to inject arbitrary web scripts via a malicious import file that execute whenever any administrator accesses a post editor page. Please note that this does not affect single-site installations as administrators already have the `unfiltered_html` capability.
CVSS v3.1
Score 4.4medium
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2026-7430 is a stored cross-site scripting vulnerability in the Post Snippets – Custom WordPress Code Snippets Customizer plugin, affecting all versions up to 4.0.19. The issue is caused by insufficient output escaping of imported snippet content embedded directly into JavaScript string literals within the jqueryUiDialog() method in WPEditor.php. The commented-out quote-escaping code and bypass of WordPress's wp_magic_quotes() during import allow double quotes in snippet content to break out of the JavaScript context. This enables authenticated administrators to inject and execute arbitrary scripts via a crafted import file when accessing the post editor page. Single-site installations are not impacted due to the unfiltered_html capability already granted to administrators.
Potential Impact
An attacker with Administrator-level privileges can inject malicious JavaScript code via the import feature of the plugin. This code executes in the context of the post editor page for any administrator who opens it, potentially leading to session hijacking, privilege escalation, or other script-based attacks. The vulnerability does not affect confidentiality or availability directly but impacts integrity and user trust. Single-site WordPress installations are not affected due to existing capability restrictions.
Mitigation Recommendations
Patch status is not yet confirmed — no official fix or patch links are provided. Administrators should avoid importing snippet content from untrusted sources until a vendor fix is released. Since the vulnerability requires Administrator-level access, restricting administrative privileges and monitoring import activities can reduce risk. Check the vendor advisory regularly for updates on official remediation or patches.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- Wordfence
- Date Reserved
- 2026-04-29T15:15:58.743Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a19090ce29bf47b507fb8ef
Added to database: 5/29/2026, 3:33:32 AM
Last enriched: 5/29/2026, 3:48:34 AM
Last updated: 5/29/2026, 5:38:15 PM
Views: 15
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.