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:
EditorUi.prototype.isLucidChartData=function(d){return null!=d&&('{"state":"{\\"Properties\\":'==d.substring(0,26)||'{"Properties":'==d.substring(0,14))};EditorUi.prototype.importLocalFile=function(d,g){if(d&&Graph.fileSupport){if(null==this.importFileInputElt){var n=document.createElement("input");n.setAttribute("type","file");mxEvent.addListener(n,"change",mxUtils.bind(this,function(){null!=n.files&&(this.importFiles(n.files,null,null,this.maxImageSize),n.type="",n.type="file",n.value="")}));n.style.display=
"none";document.body.appendChild(n);this.importFileInputElt=n}this.importFileInputElt.click()}else{window.openNew=!1;window.openKey="import";window.listBrowserFiles=mxUtils.bind(this,function(B,F){StorageFile.listFiles(this,"F",B,F)});window.openBrowserFile=mxUtils.bind(this,function(B,F,I){StorageFile.getFileContent(this,B,F,I)});window.deleteBrowserFile=mxUtils.bind(this,function(B,F,I){StorageFile.deleteFile(this,B,F,I)});if(!g){var q=Editor.useLocalStorage;Editor.useLocalStorage=!d}window.openFile=
new OpenFile(mxUtils.bind(this,function(B){this.hideDialog(B)}));window.openFile.setConsumer(mxUtils.bind(this,function(B,F){null!=F&&Graph.fileSupport&&/(\.v(dx|sdx?))($|\?)/i.test(F)?(B=new Blob([B],{type:"application/octet-stream"}),this.importVisio(B,mxUtils.bind(this,function(I){this.importXml(I,0,0,!0)}),null,F)):this.editor.graph.setSelectionCells(this.importXml(B,0,0,!0))}));this.showDialog((new OpenDialog(this)).container,Editor.useLocalStorage?640:360,Editor.useLocalStorage?480:220,!0,!0,
function(){window.openFile=null});if(!g){var t=this.dialog,v=t.close;this.dialog.close=mxUtils.bind(this,function(B){Editor.useLocalStorage=q;v.apply(t,arguments);B&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()})}}};EditorUi.prototype.importZipFile=function(d,g,n){var q=this,t=mxUtils.bind(this,function(){this.loadingExtensions=!1;"undefined"!==typeof JSZip?JSZip.loadAsync(d).then(function(v){if(mxUtils.isEmptyObject(v.files))n();else{var B=0,F,I=!1;v.forEach(function(G,S){G=