Language: JavaScript
Label: safe
CWE: CWE-78 \u2014 Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.

Code:
GraphViewer.prototype.createToolbarButton=function(b,e,g,n){var y=document.createElement("div");y.style.borderRight="1px solid #d0d0d0";y.style.padding="3px 6px 3px 6px";mxEvent.addListener(y,"click",b);null!=g&&y.setAttribute("title",g);y.style.display="inline-block";b=document.createElement("img");b.setAttribute("border","0");b.setAttribute("src",e);b.style.width="18px";null==n||n?(mxEvent.addListener(y,"mouseenter",function(){y.style.backgroundColor="#ddd"}),mxEvent.addListener(y,"mouseleave",
function(){y.style.backgroundColor="#eee"}),mxUtils.setOpacity(b,60),y.style.cursor="pointer"):mxUtils.setOpacity(y,30);y.appendChild(b);return y};GraphViewer.prototype.disableButton=function(b){var e=this.graphConfig["toolbar-buttons"]?this.graphConfig["toolbar-buttons"][b]:null;null!=e&&(mxUtils.setOpacity(e.elem,30),mxEvent.removeListener(e.elem,"click",e.handler),mxEvent.addListener(e.elem,"mouseenter",function(){e.elem.style.backgroundColor="#eee"}))};