Miggo Logo

CVE-2019-13127: mxGraph vulnerable to cross-site scripting in color field

6.1

CVSS Score
3.0

Basic Information

EPSS Score
0.55491%
Published
5/24/2022
Updated
10/19/2023
KEV Status
No
Technology
TechnologyJavaScript

Technical Details

CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
mxgraphnpm<= 4.0.04.0.1

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The commit diff shows the vulnerability was in Dialogs.js where color input validation was added. The pre-patch code (lines 204-215) directly used user-provided color values without proper sanitization, allowing injection of event handlers like onMouseOver. The PoC demonstrates this by injecting JavaScript through the color field. The fix added regex validation for hex color formats, confirming the vulnerability existed in the color processing logic of this dialog handler.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

mx*r*p* t*rou** *.*.*, r*l*t** to t** [*r*w.io *i**r*ms](*ttps://*it*u*.*om/j*r*p*/*r*wio) plu*in ***or* *.*.** *or *on*lu*n** *n* ot**r pro*u*ts, is vuln*r**l* to *ross-sit* s*riptin*. *r*w.io *i**r*ms *llows t** *r**tion *n* **itin* o* *r*w.io-**s*

Reasoning

T** *ommit *i** s*ows t** vuln*r**ility w*s in `*i*lo*s.js` w**r* *olor input v*li**tion w*s *****. T** pr*-p*t** *o** (lin*s ***-***) *ir**tly us** us*r-provi*** *olor v*lu*s wit*out prop*r s*nitiz*tion, *llowin* inj**tion o* *v*nt **n*l*rs lik* `on