Language: JavaScript
Label: vulnerable
CWE: CWE-400 \u2014 Uncontrolled Resource Consumption
The product does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources.

Code:
Graph.prototype.replaceDefaultColors=function(a,c){if(null!=c){a=mxUtils.hex2rgb(this.shapeBackgroundColor);var f=mxUtils.hex2rgb(this.shapeForegroundColor);this.replaceDefaultColor(c,mxConstants.STYLE_FONTCOLOR,f);this.replaceDefaultColor(c,mxConstants.STYLE_FILLCOLOR,a);this.replaceDefaultColor(c,mxConstants.STYLE_STROKECOLOR,f);this.replaceDefaultColor(c,mxConstants.STYLE_IMAGE_BORDER,f);this.replaceDefaultColor(c,mxConstants.STYLE_IMAGE_BACKGROUND,a);this.replaceDefaultColor(c,mxConstants.STYLE_LABEL_BORDERCOLOR,
f);this.replaceDefaultColor(c,mxConstants.STYLE_SWIMLANE_FILLCOLOR,a);this.replaceDefaultColor(c,mxConstants.STYLE_LABEL_BACKGROUNDCOLOR,a)}return c};Graph.prototype.replaceDefaultColor=function(a,c,f){null!=a&&"default"==a[c]&&null!=f&&(a[c]=f)};