Language: JavaScript
Label: vulnerable
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:
function(d){var g=e.apply(this,arguments);if(null==g)try{var n=d.indexOf("&lt;mxfile ");if(0<=n){var q=d.lastIndexOf("&lt;/mxfile&gt;");q>n&&(g=d.substring(n,q+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else{var t=mxUtils.parseXml(d),v=this.editor.extractGraphModel(t.documentElement,null!=this.pages||"hidden"==this.diagramContainer.style.visibility);g=null!=v?mxUtils.getXml(v):""}}catch(B){}return g};EditorUi.prototype.validateFileData=function(d){if(null!=