CMB2 <= 2.13.4 - Unauthenticated Stored Cross-Site Scripting via Grouped WYSIWYG Field via Front-End Form
Impact
The CMB2 plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'cmb43ex1_grp[0][txt] (wysiwyg field inside group — field id controlled by integrator config)' parameter in all versions up to, and including, 2.13.4 due to insufficient input sanitization and output escaping. This makes it possible for unauthenticated attackers to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page. This is only exploitable when a site integrator renders the plugin's documented front-end form helper with a wysiwyg field inside a repeatable group…
Source excerpt · WordfenceAffected packages
Affected products
Vendor version evidence. Product records are separate from automatic dependency matching.
jtsternberg · CMB2
Other versions: unaffected
| Version / range | Source status |
|---|---|
| 0 through 2.13.4 (inclusive) | affected |
Original source description
The CMB2 plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'cmb43ex1_grp[0][txt] (wysiwyg field inside group — field id controlled by integrator config)' parameter in all versions up to, and including, 2.13.4 due to insufficient input sanitization and output escaping. This makes it possible for unauthenticated attackers to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page. This is only exploitable when a site integrator renders the plugin's documented front-end form helper with a wysiwyg field inside a repeatable group on a publicly accessible page.
References
- Security advisory www.wordfence.com/threat-intel/vulnerabilities/id/97215367-08c0-46cc-a595-4475274a5a1c
- Source reference plugins.trac.wordpress.org/browser/cmb2/tags/2.13.4/includes/CMB2_Field.php
- Source reference plugins.trac.wordpress.org/browser/cmb2/tags/2.13.4/includes/types/CMB2_Type_Wysiwyg.php
- Source reference plugins.trac.wordpress.org/browser/cmb2/tags/2.13.4/includes/helper-functions.php
- Source reference plugins.trac.wordpress.org/browser/cmb2/tags/2.13.4/includes/CMB2_Sanitize.php
- Patch github.com/CMB2/CMB2/commit/fbeb7c4688dc5b8635a34978d837f1d458dcac44
- Patch plugins.trac.wordpress.org/changeset/3767609/cmb2/trunk/includes/CMB2_Field.php