code
stringlengths 14
2.05k
| label
int64 0
1
| programming_language
stringclasses 7
values | cwe_id
stringlengths 6
14
| cwe_name
stringlengths 5
98
⌀ | description
stringlengths 36
379
⌀ | url
stringlengths 36
48
⌀ | label_name
stringclasses 2
values |
---|---|---|---|---|---|---|---|
EditorUi.prototype.convertImages=function(c,e,k,q){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImages");return this.editor.convertImages(c,e,k,q)};EditorUi.prototype.convertImageToDataUri=function(c,e){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImageToDataUri");return this.editor.convertImageToDataUri(c,e)};EditorUi.prototype.base64Encode=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: base64Encode");return Editor.base64Encode(c)};EditorUi.prototype.updateCRC=function(c,e,k,q){EditorUi.logEvent("SHOULD NOT BE CALLED: updateCRC"); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
if(null!=y&&(null!=y&&"<"!=y.charAt(0)&&"%"!=y.charAt(0)&&(y=unescape(window.atob?atob(y):Base64.decode(cont,y))),null!=y&&"%"==y.charAt(0)&&(y=decodeURIComponent(y)),null!=y&&0<y.length)){var H=mxUtils.parseXml(y).documentElement;return"mxfile"==H.nodeName||"mxGraphModel"==H.nodeName}}catch(O){}return!1};Editor.prototype.extractGraphModel=function(g,y,H){return Editor.extractGraphModel.apply(this,arguments)};var m=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
"0"!=urlParams.pv;Graph.prototype.shadowId="dropShadow";Graph.prototype.svgShadowColor="#3D4574";Graph.prototype.svgShadowOpacity="0.4";Graph.prototype.svgShadowBlur="1.7";Graph.prototype.svgShadowSize="3";Graph.prototype.hiddenTags=[];Graph.prototype.defaultMathEnabled=!1;var e=Graph.prototype.init;Graph.prototype.init=function(){function g(P){y=P}e.apply(this,arguments);this.hiddenTags=[];window.mxFreehand&&(this.freehand=new mxFreehand(this));var y=null;mxEvent.addListener(this.container,"mouseenter", | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
c?c:"",extras:JSON.stringify(p),scale:x,border:C,w:l&&isFinite(l)?l:null,h:n&&isFinite(n)?n:null}};EditorUi.prototype.setMode=function(c,e){this.mode=c};EditorUi.prototype.getDiagramId=function(){var c=window.location.hash;null!=c&&0<c.length&&(c=c.substring(1));if(null!=c&&1<c.length){var e=c.indexOf("#");0<=e&&(c=c.substring(0,e))}return c};EditorUi.prototype.getHashObject=function(){var c=window.location.hash,e={};if(null!=c&&0<c.length){var k=c.lastIndexOf("#");if(0<k){c=decodeURIComponent(c.substring(k+ | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
(null==this.scratchpad?StorageFile.getFileContent(this,".scratchpad",mxUtils.bind(this,function(c){null==c&&(c=this.emptyLibraryXml);this.loadLibrary(new StorageLibrary(this,c,".scratchpad"))})):this.closeLibrary(this.scratchpad))};EditorUi.prototype.createLibraryDataFromImages=function(c){if(!Editor.defaultCompressed)for(var e=0;e<c.length;e++)null!=c[e].xml&&"<"!=c[e].xml.charAt(0)&&(c[e].xml=mxUtils.trim(Graph.decompress(c[e].xml)));e=mxUtils.createXmlDocument();var k=e.createElement("mxlibrary");
mxUtils.setTextContent(k,JSON.stringify(c,null,2));e.appendChild(k);return mxUtils.getXml(e,"\n")};EditorUi.prototype.closeLibrary=function(c){null!=c&&(this.removeLibrarySidebar(c.getHash()),c.constructor!=LocalLibrary&&mxSettings.removeCustomLibrary(c.getHash()),".scratchpad"==c.title&&(this.scratchpad=null))};EditorUi.prototype.removeLibrarySidebar=function(c){var e=this.sidebar.palettes[c];if(null!=e){for(var k=0;k<e.length;k++)e[k].parentNode.removeChild(e[k]);delete this.sidebar.palettes[c]}}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
App.prototype.exportFile=function(b,f,m,d,u,v){u==App.MODE_DROPBOX?null!=this.dropbox&&this.spinner.spin(document.body,mxResources.get("saving"))&&this.dropbox.insertFile(f,d?this.base64ToBlob(b,m):b,mxUtils.bind(this,function(){this.spinner.stop()}),mxUtils.bind(this,function(D){this.spinner.stop();this.handleError(D)})):u==App.MODE_GOOGLE?null!=this.drive&&this.spinner.spin(document.body,mxResources.get("saving"))&&this.drive.insertFile(f,b,v,mxUtils.bind(this,function(D){this.spinner.stop()}),
mxUtils.bind(this,function(D){this.spinner.stop();this.handleError(D)}),m,d):u==App.MODE_ONEDRIVE?null!=this.oneDrive&&this.spinner.spin(document.body,mxResources.get("saving"))&&this.oneDrive.insertFile(f,d?this.base64ToBlob(b,m):b,mxUtils.bind(this,function(){this.spinner.stop()}),mxUtils.bind(this,function(D){this.spinner.stop();this.handleError(D)}),!1,v):u==App.MODE_GITHUB?null!=this.gitHub&&this.spinner.spin(document.body,mxResources.get("saving"))&&this.gitHub.insertFile(f,b,mxUtils.bind(this,
function(){this.spinner.stop()}),mxUtils.bind(this,function(D){this.spinner.stop();this.handleError(D)}),!0,v,d):u==App.MODE_GITLAB?null!=this.gitHub&&this.spinner.spin(document.body,mxResources.get("saving"))&&this.gitLab.insertFile(f,b,mxUtils.bind(this,function(){this.spinner.stop()}),mxUtils.bind(this,function(D){this.spinner.stop();this.handleError(D)}),!0,v,d):u==App.MODE_TRELLO?null!=this.trello&&this.spinner.spin(document.body,mxResources.get("saving"))&&this.trello.insertFile(f,d?this.base64ToBlob(b,
m):b,mxUtils.bind(this,function(){this.spinner.stop()}),mxUtils.bind(this,function(D){this.spinner.stop();this.handleError(D)}),!1,v):u==App.MODE_BROWSER&&(m=mxUtils.bind(this,function(){localStorage.setItem(f,b)}),null==localStorage.getItem(f)?m():this.confirm(mxResources.get("replaceIt",[f]),m))}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
n.init()}else{var z=function(E){return{id:E.id,isExt:!0,url:E.downloadUrl,title:E.title,imgUrl:E.thumbnailLink,changedBy:E.lastModifyingUserName,lastModifiedOn:E.modifiedDate}};l=new TemplatesDialog(d,function(E,A,N){var Q=N.libs,L=N.clibs;d.pickFolder(d.mode,function(U){d.createFile(A,E,null!=Q&&0<Q.length?Q:null,null,function(){d.hideDialog()},null,U,null,null!=L&&0<L.length?L:null)},null==d.stateArg||null==d.stateArg.folderId)},null,null,null,"user",function(E,A,N){var Q=new Date;Q.setDate(Q.getDate()- | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
var GoogleSitesDialog=function(b,f){function m(){var T=null!=B&&null!=B.getTitle()?B.getTitle():this.defaultFilename;if(C.checked&&""!=J.value){var l="https://www.draw.io/gadget.xml?type=4&diagram="+encodeURIComponent(mxUtils.htmlEntities(J.value));null!=T&&(l+="&title="+encodeURIComponent(T));0<I.length&&(l+="&s="+I);""!=c.value&&"0"!=c.value&&(l+="&border="+c.value);""!=S.value&&(l+="&height="+S.value);l+="&pan="+(e.checked?"1":"0");l+="&zoom="+(k.checked?"1":"0");l+="&fit="+(x.checked?"1":"0");
l+="&resize="+(t.checked?"1":"0");l+="&x0="+Number(G.value);l+="&y0="+K;u.mathEnabled&&(l+="&math=1");p.checked?l+="&edit=_blank":q.checked&&(l+="&edit="+encodeURIComponent(mxUtils.htmlEntities(window.location.href)));M.value=l}else B.constructor==DriveFile||B.constructor==DropboxFile?(l="https://www.draw.io/gadget.xml?embed=0&diagram=",""!=J.value?l+=encodeURIComponent(mxUtils.htmlEntities(J.value))+"&type=3":(l+=B.getHash().substring(1),l=B.constructor==DropboxFile?l+"&type=2":l+"&type=1"),null!=
T&&(l+="&title="+encodeURIComponent(T)),""!=S.value&&(T=parseInt(S.value)+parseInt(G.value),l+="&height="+T),M.value=l):M.value=""}var d=document.createElement("div"),u=b.editor.graph,v=u.getGraphBounds(),D=u.view.scale,F=Math.floor(v.x/D-u.view.translate.x),K=Math.floor(v.y/D-u.view.translate.y);mxUtils.write(d,mxResources.get("googleGadget")+":");mxUtils.br(d);var M=document.createElement("input");M.setAttribute("type","text");M.style.marginBottom="8px";M.style.marginTop="2px";M.style.width="410px"; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
g);mxEvent.addListener(this.container,"mousemove",g);mxEvent.addListener(this.container,"mouseleave",function(P){y=null});this.isMouseInsertPoint=function(){return null!=y};var H=this.getInsertPoint;this.getInsertPoint=function(){return null!=y?this.getPointForEvent(y):H.apply(this,arguments)};var O=this.layoutManager.getLayout;this.layoutManager.getLayout=function(P){var V=this.graph.getCellStyle(P);if(null!=V&&"rack"==V.childLayout){var R=new mxStackLayout(this.graph,!1);R.gridSize=null!=V.rackUnitSize? | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
c,e,k,q,p);this.showDialog(c.container,640,440,!0,!1,mxUtils.bind(this,function(t){t&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()}));c.init()};var m=EditorUi.prototype.createFormat;EditorUi.prototype.createFormat=function(c){var e=m.apply(this,arguments);this.editor.graph.addListener("viewStateChanged",mxUtils.bind(this,function(k){this.editor.graph.isSelectionEmpty()&&e.refresh()}));return e};EditorUi.prototype.handleError=function(c,e,k,q,p,t,x){var C=null!=this.spinner&& | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
v&&(this.lastAutosaveRevision=(new Date).getTime());this.save(v,mxUtils.bind(this,function(D){this.autosaveCompleted();null!=m&&m(D)}),mxUtils.bind(this,function(D){null!=d&&d(D)}))}else this.isModified()||this.ui.editor.setStatus(""),null!=m&&m(null)}catch(D){null!=d&&d(D)}}),b);EditorUi.debug("DrawioFile.autosave",[this],"thread",u,"delay",b,"saving",this.savingFile);this.autosaveThread=u};DrawioFile.prototype.isAutosaveNow=function(){return!0};DrawioFile.prototype.autosaveCompleted=function(){}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function(R){"undefined"!==typeof MathJax&&"function"===typeof MathJax.typeset?Editor.doMathJaxRender(R):Editor.mathJaxQueue.push(R)};Editor.onMathJaxDone=function(){};var P=Editor.prototype.init;Editor.prototype.init=function(){P.apply(this,arguments);var R=mxUtils.bind(this,function(W,X){null!=this.graph.container&&this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)});this.graph.model.addListener(mxEvent.CHANGE,R);this.graph.addListener(mxEvent.REFRESH,R)};y=document.getElementsByTagName("script"); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
Graph.recentCustomFonts[O]=P,y=document.getElementsByTagName("head")[0],null!=H&&("link"==P.elt.nodeName.toLowerCase()?(P.elt.onload=H,P.elt.onerror=H):H()),null!=y&&y.appendChild(P.elt)):null!=H&&H()}else null!=H&&H()}else null!=H&&H();return g};Graph.getFontUrl=function(g,y){g=Graph.customFontElements[g.toLowerCase()];null!=g&&(y=g.url);return y};Graph.processFontAttributes=function(g){g=g.getElementsByTagName("*");for(var y=0;y<g.length;y++){var H=g[y].getAttribute("data-font-src");if(null!=H){var O= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
t=[];p.onsuccess=function(x){null==x.target.result?c(t):(t.push(x.target.result.value),x.target.result.continue())};p.onerror=e}catch(x){null!=e&&e(x)}}),e)};EditorUi.prototype.getDatabaseItemKeys=function(c,e,k){this.openDatabase(mxUtils.bind(this,function(q){try{k=k||"objects";var p=q.transaction([k],"readonly").objectStore(k).getAllKeys();p.onsuccess=function(){c(p.result)};p.onerror=e}catch(t){null!=e&&e(t)}}),e)};EditorUi.prototype.commentsSupported=function(){var c=this.getCurrentFile();return null!=
c?c.commentsSupported():!1};EditorUi.prototype.commentsRefreshNeeded=function(){var c=this.getCurrentFile();return null!=c?c.commentsRefreshNeeded():!0};EditorUi.prototype.commentsSaveNeeded=function(){var c=this.getCurrentFile();return null!=c?c.commentsSaveNeeded():!1};EditorUi.prototype.getComments=function(c,e){var k=this.getCurrentFile();null!=k?k.getComments(c,e):c([])};EditorUi.prototype.addComment=function(c,e,k){var q=this.getCurrentFile();null!=q?q.addComment(c,e,k):e(Date.now())};EditorUi.prototype.canReplyToReplies= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.useCanvasForExport||".png"!=q||(q=".drawio"),".svg"===q||".xml"===q||".html"===q||".png"===q||".drawio"===q)&&(e=k+q)}c=new LocalFile(this,c,null!=urlParams.title?decodeURIComponent(urlParams.title):e,!0);c.getHash=function(){return b};this.fileLoaded(c,!0)?null!=d&&d():S()||this.handleError({message:mxResources.get("fileNotFound")},mxResources.get("errorLoadingFile"))}else S()||this.handleError({message:mxResources.get("fileNotFound")},mxResources.get("errorLoadingFile"))}),mxUtils.bind(this, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.defaultFonts[A];"string"===typeof N?z(N):null!=N.fontFamily&&null!=N.fontUrl&&(E[encodeURIComponent(N.fontFamily)+"@"+encodeURIComponent(N.fontUrl)]=!0,z(N.fontFamily,N.fontUrl))}l.addSeparator(n);if("1"!=urlParams["ext-fonts"]){N=function(H){var O=encodeURIComponent(H.name)+(null==H.url?"":"@"+encodeURIComponent(H.url));if(!E[O]){for(var P=H.name,V=0;null!=L[P.toLowerCase()];)P=H.name+" ("+ ++V+")";null==Q[O]&&(U.push({name:H.name,url:H.url,label:P,title:H.url}),L[P.toLowerCase()]=H,Q[O]=H)}}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
EditorUi.prototype.selectPage=function(b,f,m){try{if(b!=this.currentPage){var d=this.editor.graph;d.isEditing()&&d.stopEditing(!1);f=null!=f?f:!1;d.isMouseDown=!1;d.reset();var u=d.model.createUndoableEdit();u.ignoreEdit=!0;var v=new SelectPage(this,b,m);v.execute();u.add(v);u.notify();d.tooltipHandler.hide();null!=b.viewState&&null==b.viewState.scrollTop&&(d.selectUnlockedLayer(),this.resetScrollbars(),d.isLightboxView()&&this.lightboxFit(),null!=this.chromelessResize&&(d.container.scrollleft=0,
d.container.scrollTop=0,this.chromelessResize()));f||d.model.fireEvent(new mxEventObject(mxEvent.UNDO,"edit",u))}}catch(D){this.handleError(D)}};EditorUi.prototype.selectNextPage=function(b){var f=this.currentPage;null!=f&&null!=this.pages&&(f=mxUtils.indexOf(this.pages,f),b?this.selectPage(this.pages[mxUtils.mod(f+1,this.pages.length)]):b||this.selectPage(this.pages[mxUtils.mod(f-1,this.pages.length)]))}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
preview:aa.getAttribute("preview"),clibs:ha,tags:aa.getAttribute("tags")};ja.push(ha);null!=ma&&(ja=va[oa],null==ja&&(ja={},va[oa]=ja),oa=ja[ma],null==oa&&(oa=[],ja[ma]=oa),oa.push(ha))}aa=aa.nextSibling}L.stop();l()}})};z.appendChild(qa);z.appendChild(wa);z.appendChild(ca);var Ua=!1,ia=G;/^https?:\/\//.test(ia)&&!b.editor.isCorsEnabledForUrl(ia)&&(ia=PROXY_URL+"?url="+encodeURIComponent(ia));L.spin(ca);null!=q?q(function(aa,la){Ea=aa;W=Da=la;Va()},Va):Va();R=ua}mxEvent.addListener(N,"keypress",function(aa){b.dialog.container.firstChild== | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
EditorUi.debug=function(){try{if(null!=window.console&&"1"==urlParams.test){for(var c=[(new Date).toISOString()],e=0;e<arguments.length;e++)c.push(arguments[e]);console.log.apply(console,c)}}catch(k){}};EditorUi.removeChildNodes=function(c){for(;null!=c.firstChild;)c.removeChild(c.firstChild)};EditorUi.prototype.emptyDiagramXml='<mxGraphModel><root><mxCell id="0"/><mxCell id="1" parent="0"/></root></mxGraphModel>';EditorUi.prototype.emptyLibraryXml="<mxlibrary>[]</mxlibrary>";EditorUi.prototype.mode= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
c?c:"",extras:JSON.stringify(p),scale:x,border:C,w:l&&isFinite(l)?l:null,h:n&&isFinite(n)?n:null}};EditorUi.prototype.setMode=function(c,e){this.mode=c};EditorUi.prototype.getDiagramId=function(){var c=window.location.hash;null!=c&&0<c.length&&(c=c.substring(1));if(null!=c&&1<c.length){var e=c.indexOf("#");0<=e&&(c=c.substring(0,e))}return c};EditorUi.prototype.getHashObject=function(){var c=window.location.hash,e={};if(null!=c&&0<c.length){var k=c.lastIndexOf("#");if(0<k){c=decodeURIComponent(c.substring(k+ | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
m.setCellStyles(mxConstants.STYLE_ROTATION,Number(p.value),[f[x]])}}finally{m.getModel().endUpdate()}});t.className="geBtn gePrimaryBtn";mxEvent.addListener(u,"keypress",function(x){13==x.keyCode&&t.click()});v=document.createElement("div");v.style.marginTop="20px";v.style.textAlign="right";b.editor.cancelFirst?(v.appendChild(d),v.appendChild(t)):(v.appendChild(t),v.appendChild(d));u.appendChild(v);this.container=u},LibraryDialog=function(b,f,m,d,u,v){function D(T){for(T=document.elementFromPoint(T.clientX, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
f.getCell(e),null!=c&&c!=J&&(J=null));null!=J&&(f.getChildAt(m,F)!=J&&f.add(m,J,F),this.patchCellRecursive(b,f,J,d,u),F++);return e});for(M=[null];0<M.length;)if(G=M.shift(),G=K(null!=G?G.child:null,null!=G?G.insert:!1),S=v[G],null!=S&&(delete v[G],M.push({child:f.getCell(S)})),S=D[G],null!=S&&(delete D[G],M.push({child:this.getCellForJson(S),insert:!0})),0==M.length){for(G in v)M.push({child:f.getCell(v[G])}),delete v[G];for(G in D)M.push({child:this.getCellForJson(D[G]),insert:!0}),delete D[G]}}}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
StorageFile.listFiles=function(b,f,m,d){b.getDatabaseItems(function(u){var v=[];if(null!=u)for(var D=0;D<u.length;D++)"."==u[D].title.charAt(0)||null!=f&&u[D].type!=f||v.push(u[D]);m(v)},function(){null==b.database?m(StorageFile.listLocalStorageFiles(f)):null!=d&&d()},"filesInfo")};StorageFile.deleteFile=function(b,f,m,d){b.removeDatabaseItem([f,f],m,function(){null==b.database?(localStorage.removeItem(f),m()):null!=d&&d()},["files","filesInfo"])};StorageLibrary=function(b,f,m){StorageFile.call(this,b,f,m)};mxUtils.extend(StorageLibrary,StorageFile);StorageLibrary.prototype.type="L";StorageLibrary.prototype.isAutosave=function(){return!0};StorageLibrary.prototype.saveAs=function(b,f,m){this.saveFile(b,!1,f,m)};StorageLibrary.prototype.getHash=function(){return"L"+encodeURIComponent(this.title)};StorageLibrary.prototype.getTitle=function(){return".scratchpad"==this.title?mxResources.get("scratchpad"):this.title}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
E.translate(Math.floor((1-n.x)/z),Math.floor((1-n.y)/z));E.scale(1/z);var N=0,Q=E.save;E.save=function(){N++;Q.apply(this,arguments)};var L=E.restore;E.restore=function(){N--;L.apply(this,arguments)};var U=l.drawShape;l.drawShape=function(g){mxLog.debug("entering shape",g,N);U.apply(this,arguments);mxLog.debug("leaving shape",g,N)};l.drawState(u.getView().getState(u.model.root),E);mxLog.show();mxLog.debug(mxUtils.getXml(A));mxLog.debug("stateCounter",N)}));d.actions.addAction("testShowConsole",function(){mxLog.isVisible()? | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
mxStencilRegistry.getStencil(Y)}return A.apply(this,arguments)};var N=mxStencil.prototype.drawShape;mxStencil.prototype.drawShape=function(g,y,H,O,P,V){"1"==mxUtils.getValue(y.style,"lineShape",null)&&g.setFillColor(mxUtils.getValue(y.style,mxConstants.STYLE_STROKECOLOR,this.stroke));return N.apply(this,arguments)};PrintDialog.prototype.create=function(g,y){function H(){fa.value=Math.max(1,Math.min(W,Math.max(parseInt(fa.value),parseInt(ea.value))));ea.value=Math.max(1,Math.min(W,Math.min(parseInt(fa.value), | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function(M){return this.isTreeEdge(M)}))};Graph.prototype.getIncomingTreeEdges=function(d,u){return this.getTreeEdges(d,u,!0,!1,!1)};Graph.prototype.getOutgoingTreeEdges=function(d,u){return this.getTreeEdges(d,u,!1,!0,!1)};var f=EditorUi.prototype.init;EditorUi.prototype.init=function(){f.apply(this,arguments);this.editor.isChromelessView()&&!this.editor.editable||this.addTrees()};EditorUi.prototype.addTrees=function(){function d(A){return k.isVertex(A)&&v(A)}function u(A){var N=!1;null!=A&&(N="1"== | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
StorageFile.listFiles=function(b,f,m,d){b.getDatabaseItems(function(u){var v=[];if(null!=u)for(var D=0;D<u.length;D++)"."==u[D].title.charAt(0)||null!=f&&u[D].type!=f||v.push(u[D]);m(v)},function(){null==b.database?m(StorageFile.listLocalStorageFiles(f)):null!=d&&d()},"filesInfo")};StorageFile.deleteFile=function(b,f,m,d){b.removeDatabaseItem([f,f],m,function(){null==b.database?(localStorage.removeItem(f),m()):null!=d&&d()},["files","filesInfo"])};StorageLibrary=function(b,f,m){StorageFile.call(this,b,f,m)};mxUtils.extend(StorageLibrary,StorageFile);StorageLibrary.prototype.type="L";StorageLibrary.prototype.isAutosave=function(){return!0};StorageLibrary.prototype.saveAs=function(b,f,m){this.saveFile(b,!1,f,m)};StorageLibrary.prototype.getHash=function(){return"L"+encodeURIComponent(this.title)};StorageLibrary.prototype.getTitle=function(){return".scratchpad"==this.title?mxResources.get("scratchpad"):this.title}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
va,Ha=Ia+(Ta.x-Ia)/va-fa,Va=Sa+(Ta.y-Sa)/va-fa,Ua=new Image;Ua.onload=function(){try{for(var ia=-Math.round(Da-mxUtils.mod((Ia-Ha)*W,Da)),aa=-Math.round(Da-mxUtils.mod((Sa-Va)*W,Da));ia<wa;ia+=Da)for(var la=aa;la<Qa;la+=Da)pa.drawImage(Ua,ia/W,la/W);Aa()}catch(ma){null!=P&&P(ma)}};Ua.onerror=function(ia){null!=P&&P(ia)};Ua.src=Ea}else Aa()}catch(ia){null!=P&&P(ia)}});qa.onerror=function(Aa){null!=P&&P(Aa)};Z&&this.graph.addSvgShadow(ca);this.graph.mathEnabled&&this.addMathCss(ca);var ka=mxUtils.bind(this, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
if(null!=y&&0<y.length){var V=document.createElement("script");V.setAttribute("type","text/javascript");V.setAttribute("src",g);y[0].parentNode.appendChild(V)}}};Editor.prototype.csvToArray=function(g){if(0<g.length){var y="",H=[""],O=0,P=!0,V;g=$jscomp.makeIterator(g);for(V=g.next();!V.done;V=g.next())V=V.value,'"'===V?(P&&V===y&&(H[O]+=V),P=!P):","===V&&P?V=H[++O]="":H[O]+=V,y=V;return H}return[]};Editor.prototype.getProxiedUrl=function(g){if((/test\.draw\.io$/.test(window.location.hostname)||/app\.diagrams\.net$/.test(window.location.hostname))&& | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
if(null!=t.hoverIcons){var z=t.hoverIcons.update;t.hoverIcons.update=function(){x.freehand.isDrawing()||z.apply(this,arguments)}}if(null!=x.freehand){var E=x.freehand.createStyle;x.freehand.createStyle=function(W){return E.apply(this,arguments)+"sketch=0;"}}t.editor.addListener("statusChanged",mxUtils.bind(this,function(){t.setStatusText(t.editor.getStatus())}));t.setStatusText(t.editor.getStatus());var A=t.menus.get("viewZoom");if(null!=A){var N=function(W){if(mxEvent.isAltDown(W))t.hideCurrentMenu(), | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
return y};Graph.prototype.getDefaultStylesheet=function(){if(null==this.defaultStylesheet){var g=this.themes["default-style2"];this.defaultStylesheet=(new mxCodec(g.ownerDocument)).decode(g)}return this.defaultStylesheet};Graph.prototype.isViewer=function(){return urlParams.viewer};var C=Graph.prototype.getSvg;Graph.prototype.getSvg=function(g,y,H,O,P,V,R,W,X,Z,Y,ea,fa,na){var da=null,za=null,Ca=null;ea||null==this.themes||"darkTheme"!=this.defaultThemeName||(da=this.stylesheet,za=this.shapeForegroundColor, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.loadImage(Z.target.result,mxUtils.bind(this,function(ca){this.resizeImage(ca,Z.target.result,mxUtils.bind(this,function(qa,ka,Aa){P(R,mxUtils.bind(this,function(){if(null!=qa&&qa.length<B){var xa=E&&this.isResampleImageSize(W.size,T)?Math.min(1,Math.min(q/ka,q/Aa)):1;return p(qa,W.type,e+R*g,k+R*g,Math.round(ka*xa),Math.round(Aa*xa),W.name)}this.handleError({message:mxResources.get("imageTooBig")});return null}))}),E,q,T,W.size)}),mxUtils.bind(this,function(){this.handleError({message:mxResources.get("invalidOrMissingFile")})})))}else Y= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
var da=this.graphHandler.shouldRemoveCellsFromParent;this.graphHandler.shouldRemoveCellsFromParent=function(K,U,L){return this.graph.isCellSelected(K)?!1:da.apply(this,arguments)};var ja=this.updateMouseEvent;this.updateMouseEvent=function(K){K=ja.apply(this,arguments);null!=K.state&&this.isCellLocked(this.getLayerForCell(K.getCell()))&&(K.state=null);return K};var ia=this.isCellSelectable;this.isCellSelectable=function(K){return ia.apply(this,arguments)&&!this.isCellLocked(this.getLayerForCell(K))}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
x){var C=x.lastIndexOf(".");0<C&&(x=x.substring(C+1,x.length));null==e[x]&&(e[x]=!0)}}var q=this.editor.graph,p=q.getCellStyle(c);k(mxStencilRegistry.getBasenameForStencil(p[mxConstants.STYLE_SHAPE]));q.model.isEdge(c)&&(k(mxMarker.getPackageForType(p[mxConstants.STYLE_STARTARROW])),k(mxMarker.getPackageForType(p[mxConstants.STYLE_ENDARROW])));p=q.model.getChildCount(c);for(var t=0;t<p;t++)this.addBasenamesForCell(q.model.getChildAt(c,t),e)};EditorUi.prototype.setGraphEnabled=function(c){this.diagramContainer.style.visibility=
c?"":"hidden";this.formatContainer.style.visibility=c?"":"hidden";this.sidebarContainer.style.display=c?"":"none";this.hsplit.style.display=c&&"sketch"!=Editor.currentTheme&&"min"!=Editor.currentTheme?"":"none";this.editor.graph.setEnabled(c);null!=this.tabContainer&&(this.tabContainer.style.visibility=c?"":"hidden");null!=this.ruler&&(this.ruler.hRuler.container.style.visibility=c?"":"hidden",this.ruler.vRuler.container.style.visibility=c?"":"hidden");c||this.hideWindows()};EditorUi.prototype.initializeEmbedMode= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
va,Ha=Ia+(Ta.x-Ia)/va-fa,Va=Sa+(Ta.y-Sa)/va-fa,Ua=new Image;Ua.onload=function(){try{for(var ia=-Math.round(Da-mxUtils.mod((Ia-Ha)*W,Da)),aa=-Math.round(Da-mxUtils.mod((Sa-Va)*W,Da));ia<wa;ia+=Da)for(var la=aa;la<Qa;la+=Da)pa.drawImage(Ua,ia/W,la/W);Aa()}catch(ma){null!=P&&P(ma)}};Ua.onerror=function(ia){null!=P&&P(ia)};Ua.src=Ea}else Aa()}catch(ia){null!=P&&P(ia)}});qa.onerror=function(Aa){null!=P&&P(Aa)};Z&&this.graph.addSvgShadow(ca);this.graph.mathEnabled&&this.addMathCss(ca);var ka=mxUtils.bind(this, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function(g){"data:action/json,"==g.substring(0,17)&&(g=JSON.parse(g.substring(17)),null!=g.actions&&this.executeCustomActions(g.actions))};Graph.prototype.executeCustomActions=function(g,y){if(this.executingCustomActions)this.stoppingCustomActions=!0,null!=this.pendingWaitThread&&window.clearTimeout(this.pendingWaitThread),null!=this.pendingExecuteNextAction&&this.pendingExecuteNextAction(),this.fireEvent(new mxEventObject("stopExecutingCustomActions"));else{this.executingCustomActions=!0;var H=!1, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.styleInput.value)})),A.appendChild(this.styleInput),this.editor.graph.getSelectionModel().addListener(mxEvent.CHANGE,mxUtils.bind(this,function(L,U){0<this.editor.graph.getSelectionCount()?(L=this.editor.graph.getSelectionCell(),L=this.editor.graph.getModel().getStyle(L),this.styleInput.value=L||"",this.styleInput.style.visibility="visible"):this.styleInput.style.visibility="hidden"})));var N=this.isSelectionAllowed;this.isSelectionAllowed=function(L){return mxEvent.getSource(L)==this.styleInput?
!0:N.apply(this,arguments)}}A=document.getElementById("geInfo");null!=A&&A.parentNode.removeChild(A);if(Graph.fileSupport&&(!this.editor.chromeless||this.editor.editable)){var Q=null;mxEvent.addListener(e.container,"dragleave",function(L){e.isEnabled()&&(null!=Q&&(Q.parentNode.removeChild(Q),Q=null),L.stopPropagation(),L.preventDefault())});mxEvent.addListener(e.container,"dragover",mxUtils.bind(this,function(L){null==Q&&(!mxClient.IS_IE||10<document.documentMode)&&(Q=this.highlightElement(e.container)); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function(g,y){for(var H=0;H<y.length;H++){var O=y[H],P;for(P in O)this.updateCustomLinkAction(g,O[P],"cells"),this.updateCustomLinkAction(g,O[P],"excludeCells")}};Graph.prototype.updateCustomLinkAction=function(g,y,H){if(null!=y&&null!=y[H]){for(var O=[],P=0;P<y[H].length;P++)if("*"==y[H][P])O.push(y[H][P]);else{var V=g[y[H][P]];null!=V?""!=V&&O.push(V):O.push(y[H][P])}y[H]=O}};Graph.prototype.getCellsForAction=function(g,y){y=this.getCellsById(g.cells).concat(this.getCellsForTags(g.tags,null,y)); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
EditorUi.prototype.patchPage=function(b,f,m,d){var u=b==this.currentPage?this.editor.graph.model:new mxGraphModel(b.root),v=this.createParentLookup(u,f);u.beginUpdate();try{var D=u.updateEdgeParent,F=new mxDictionary,K=[];u.updateEdgeParent=function(q,p){!F.get(q)&&d&&(F.put(q,!0),K.push(q))};var M=v[""],G=null!=M&&null!=M.inserted?M.inserted[""]:null,S=null;null!=G&&(S=this.getCellForJson(G));if(null==S){var J=null!=M&&null!=M.moved?M.moved[""]:null;null!=J&&(S=u.getCell(J))}null!=S&&(u.setRoot(S), | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
v)for(D=0;D<v.length;D++)v[D].node.style.visibility=d?"visible":"hidden"};var m=mxGuide.prototype.destroy;mxGuide.prototype.destroy=function(){m.call(this);var d=this.guidesArrVer,u=this.guidesArrHor;if(null!=d){for(var v=0;v<d.length;v++)d[v].destroy();this.guidesArrVer=null}if(null!=u){for(v=0;v<u.length;v++)u[v].destroy();this.guidesArrHor=null}}})();function mxRuler(b,f,m,d){function u(){var x=b.diagramContainer;S.style.top=x.offsetTop-K+"px";S.style.left=x.offsetLeft-K+"px";S.style.width=(m?0:x.offsetWidth)+K+"px";S.style.height=(m?x.offsetHeight:0)+K+"px"}function v(x,C,I){if(null!=D)return x;var B;return function(){var T=this,l=arguments,n=I&&!B;clearTimeout(B);B=setTimeout(function(){B=null;I||x.apply(T,l)},C);n&&x.apply(T,l)}}var D=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.div.style.left=Math.max(0,parseInt(this.div.style.left)-c+140)+"px");this.fit()};mxEvent.addListener(this.formatWindow.window.title,"dblclick",mxUtils.bind(this,function(e){mxEvent.getSource(e)==this.formatWindow.window.title&&this.formatWindow.window.toggleMinimized()}))}};var S=EditorUi.prototype.init;EditorUi.prototype.init=function(){function J(W,X,Z){var Y=t.menus.get(W),ea=B.addMenu(mxResources.get(W),mxUtils.bind(this,function(){Y.funct.apply(this,arguments)}),I);ea.className="geMenuItem";
ea.style.display="inline-block";ea.style.boxSizing="border-box";ea.style.top="6px";ea.style.marginRight="6px";ea.style.height="30px";ea.style.paddingTop="6px";ea.style.paddingBottom="6px";ea.style.cursor="pointer";ea.setAttribute("title",mxResources.get(W));t.menus.menuCreated(Y,ea,"geMenuItem");null!=Z?(ea.style.backgroundImage="url("+Z+")",ea.style.backgroundPosition="center center",ea.style.backgroundRepeat="no-repeat",ea.style.backgroundSize="24px 24px",ea.style.width="34px",ea.innerText=""):
X||(ea.style.backgroundImage="url("+mxWindow.prototype.normalizeImage+")",ea.style.backgroundPosition="right 6px center",ea.style.backgroundRepeat="no-repeat",ea.style.paddingRight="22px");return ea}function c(W,X,Z,Y,ea,fa){var na=document.createElement("a");na.className="geMenuItem";na.style.display="inline-block";na.style.boxSizing="border-box";na.style.height="30px";na.style.padding="6px";na.style.position="relative";na.style.verticalAlign="top";na.style.top="0px";null!=t.statusContainer?C.insertBefore(na, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
new Image;T.onload=function(){try{var l=T.width,n=T.height;if(0==l&&0==n){var z=I.result,E=z.indexOf(","),A=decodeURIComponent(escape(atob(z.substring(E+1)))),N=mxUtils.parseXml(A).getElementsByTagName("svg");0<N.length&&(l=parseFloat(N[0].getAttribute("width")),n=parseFloat(N[0].getAttribute("height")))}k(I.result,l,n)}catch(Q){q(Q)}};T.src=I.result};I.onerror=function(B){q(B)}}else q(C)};x.onerror=function(C){q(C)};x.send()};EditorUi.prototype.insertAsPreText=function(c,e,k){var q=this.editor.graph, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
(new mxXmlRequest(SAVE_URL,"format="+S+"&xml="+encodeURIComponent(M)+"&filename="+encodeURIComponent(b)+(v?"&binary=1":""))).simulate(document,"_blank")}else this.ui.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(M)}));F()}});v?(f=this.ui.getPngFileProperties(this.ui.fileNode),this.ui.getEmbeddedPng(mxUtils.bind(this,function(M){K(M)}),d,this.ui.getCurrentFile()!=this?D:null,f.scale,f.border)):K(D)}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
mxGraphView.prototype.stateValidated=function(g){null!=g.shape&&this.redrawEnumerationState(g);return T.apply(this,arguments)};mxGraphView.prototype.createEnumerationValue=function(g){g=decodeURIComponent(mxUtils.getValue(g.style,"enumerateValue",""));""==g&&(g=++this.enumerationState);return'<div style="padding:2px;border:1px solid gray;background:yellow;border-radius:2px;">'+mxUtils.htmlEntities(g)+"</div>"};mxGraphView.prototype.redrawEnumerationState=function(g){var y="1"==mxUtils.getValue(g.style, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
DrawioFile.prototype.handleConflictError=function(b,f){var m=mxUtils.bind(this,function(){this.handleFileSuccess(!0)}),d=mxUtils.bind(this,function(D){this.handleFileError(D,!0)}),u=mxUtils.bind(this,function(){this.ui.spinner.spin(document.body,mxResources.get(this.savingSpinnerKey))&&(this.ui.editor.setStatus(""),this.save(!0,m,d,null,!0,this.constructor!=GitHubFile&&this.constructor!=GitLabFile||null==b?null:b.commitMessage))}),v=mxUtils.bind(this,function(){this.ui.spinner.spin(document.body,mxResources.get("updatingDocument"))&&
this.synchronizeFile(mxUtils.bind(this,function(){this.ui.spinner.stop();this.ui.spinner.spin(document.body,mxResources.get(this.savingSpinnerKey))&&this.save(!0,m,d,null,null,this.constructor!=GitHubFile&&this.constructor!=GitLabFile||null==b?null:b.commitMessage)}),d)});"none"==DrawioFile.SYNC?this.showCopyDialog(m,d,u):this.invalidChecksum?this.showRefreshDialog(m,d,this.getErrorMessage(b)):f?this.showConflictDialog(u,v):this.addConflictStatus(this.getErrorMessage(b),mxUtils.bind(this,function(){this.ui.editor.setStatus(mxUtils.htmlEntities(mxResources.get("updatingDocument")));
this.synchronizeFile(m,d)}))};DrawioFile.prototype.getErrorMessage=function(b){var f=null!=b?null!=b.error?b.error.message:b.message:null;null==f&&null!=b&&b.code==App.ERROR_TIMEOUT?f=mxResources.get("timeout"):"0"==f&&(f=mxResources.get("noResponse"));return f};DrawioFile.prototype.isOverdue=function(){return null!=this.ageStart&&Date.now()-this.ageStart.getTime()>=this.ui.warnInterval}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
f.prev.getId():"";null!=f.page.getName()&&b[K].getName()!=f.page.getName()&&(S.name=f.page.getName());mxUtils.isEmptyObject(S)||(D[M]=S)}delete v[b[K].getId()];F=b[K]}for(M in v)f=v[M],m.push({data:mxUtils.getXml(f.page.node),previous:null!=f.prev?f.prev.getId():""});mxUtils.isEmptyObject(D)||(u[EditorUi.DIFF_UPDATE]=D);0<d.length&&(u[EditorUi.DIFF_REMOVE]=d);0<m.length&&(u[EditorUi.DIFF_INSERT]=m)}return u}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
StorageFile.prototype.saveFile=function(b,f,m,d){if(this.isEditable()){var u=mxUtils.bind(this,function(){this.isRenamable()&&(this.title=b);try{var v=mxUtils.bind(this,function(){this.setModified(this.getShadowModified());this.contentChanged();null!=m&&m()});this.setShadowModified(!1);var D=this.getData();this.ui.setDatabaseItem(null,[{title:this.title,size:D.length,lastModified:Date.now(),type:this.type},{title:this.title,data:D}],v,mxUtils.bind(this,function(){if(null==this.ui.database)try{this.ui.setLocalData(this.title,
D,v)}catch(F){null!=d&&d(F)}else null!=d&&d()}),["filesInfo","files"])}catch(F){null!=d&&d(F)}});this.isRenamable()&&"."==b.charAt(0)&&null!=d?d({message:mxResources.get("invalidName")}):StorageFile.getFileInfo(this.ui,b,mxUtils.bind(this,function(v){this.isRenamable()&&this.getTitle()!=b&&null!=v?this.ui.confirm(mxResources.get("replaceIt",[b]),u,d):u()}),d)}else null!=m&&m()}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
b.editor.graph.rendering=!1;G.getModel().beginUpdate();try{for(var y=0,H={};K(!1,!0,!0)&&100>y;){var O=J.cell,P=G.getLabel(O),V=H[O.id];if(V&&V.replAllMrk==p&&V.replAllPos>=q)break;H[O.id]={replAllMrk:p,replAllPos:q};G.isCellEditable(O)&&(G.model.setValue(O,A(P,k,I.value,q-k.length,G.getCurrentCellStyle(O))),y++)}U!=b.currentPage&&b.editor.graph.model.execute(new SelectPage(b,U));mxUtils.write(E,mxResources.get("matchesRepl",[y]))}catch(R){b.handleError(R)}finally{G.getModel().endUpdate(),b.editor.graph.setSelectionCells(g),
b.editor.graph.rendering=!0}p++});L.setAttribute("title",mxResources.get("replaceAll"));L.style.float="none";L.style.width="120px";L.style.marginTop="6px";L.style.marginLeft="8px";L.style.overflow="hidden";L.style.textOverflow="ellipsis";L.className="geBtn gePrimaryBtn";L.setAttribute("disabled","disabled");x.appendChild(L);mxUtils.br(x);x.appendChild(n);n=mxUtils.button(mxResources.get("close"),mxUtils.bind(this,function(){this.window.setVisible(!1)}));n.setAttribute("title",mxResources.get("close")); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
e)};EditorUi.prototype.embedExtFonts=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: embedExtFonts");return this.editor.embedExtFonts(c)};EditorUi.prototype.exportToCanvas=function(c,e,k,q,p,t,x,C,I,B,T,l,n,z,E,A){EditorUi.logEvent("SHOULD NOT BE CALLED: exportToCanvas");return this.editor.exportToCanvas(c,e,k,q,p,t,x,C,I,B,T,l,n,z,E,A)};EditorUi.prototype.createImageUrlConverter=function(){EditorUi.logEvent("SHOULD NOT BE CALLED: createImageUrlConverter");return this.editor.createImageUrlConverter()}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
AspectDialog.prototype.createPageItem=function(b,f,m){var d=document.createElement("div");d.className="geAspectDlgListItem";d.setAttribute("data-page-id",b);d.innerHTML='<div style="max-width: 100%; max-height: 100%;"></div><div class="geAspectDlgListItemText">'+mxUtils.htmlEntities(f)+"</div>";this.pagesContainer.appendChild(d);var u=this.createViewer(d.childNodes[0],m);f=mxUtils.bind(this,function(){null!=this.selectedItem&&(this.selectedItem.className="geAspectDlgListItem");this.selectedItem=d;
this.selectedPage=b;d.className+=" geAspectDlgListItemSelected";this.layersContainer.innerText="";this.selectedLayers={};this.okBtn.setAttribute("disabled","disabled");var v=u.model;v=v.getChildCells(v.getRoot());for(var D=0;D<v.length;D++)this.createLayerItem(v[D],b,u,m)});mxEvent.addListener(d,"click",f);this.aspect.pageId==b&&f()}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
mxResources.get("mermaid")+"...","mermaid");J.showDialog(k.container,620,420,!0,!1);k.init()}));var c="horizontalFlow verticalFlow - horizontalTree verticalTree radialTree - organic circle".split(" "),e=function(k,q,p,t){k.addItem(p,null,mxUtils.bind(this,function(){var x=new CreateGraphDialog(J,p,t);J.showDialog(x.container,620,420,!0,!1);x.init()}),q)};this.put("insertLayout",new Menu(mxUtils.bind(this,function(k,q){for(var p=0;p<c.length;p++)"-"==c[p]?k.addSeparator(q):e(k,q,mxResources.get(c[p])+ | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.menubarContainer)),null!=this.buttonContainer&&(this.buttonContainer.style.display="",this.buttonContainer.style.padding="",this.menubar.container.appendChild(this.buttonContainer))};EditorUi.prototype.createMenu=function(c,e,k,q){k=null!=k?k:"geToolbarButton";var p=this.menus.get(c);q=this.menubar.addMenu(mxResources.get(c),p.funct,null,q);q.className=k;q.style.display="inline-block";q.style.cursor="pointer";q.style.height="24px";q.setAttribute("title",mxResources.get(c));this.menus.menuCreated(p,
q,k);null!=e&&(q.style.backgroundImage="url("+e+")",q.style.backgroundPosition="center center",q.style.backgroundRepeat="no-repeat",q.style.backgroundSize="100% 100%",q.style.width="24px",q.innerText="");return q};EditorUi.prototype.createToolbarButton=function(c,e,k,q){q=null!=q?q:24;var p=document.createElement("a");p.className="geToolbarButton geAdaptiveAsset";p.setAttribute("title",e);p.style.backgroundImage="url("+c+")";p.style.backgroundPosition="center center";p.style.backgroundRepeat="no-repeat"; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
!1,!1),d.pdfPageExport||mxEvent.addListener(O,"change",E);E=!mxClient.IS_CHROMEAPP&&!EditorUi.isElectronApp&&"draw.io"==d.getServiceName();var R=null,W=null;if(EditorUi.isElectronApp||E)W=d.addCheckbox(n,mxResources.get("includeCopyOfMyDiagram"),Editor.defaultIncludeDiagram),z+=30;E&&(R=d.addCheckbox(n,mxResources.get("transparentBackground"),!1),z+=30);n=new CustomDialog(d,n,mxUtils.bind(this,function(){var X=null;if(!l){X=parseInt(g.value);var Z=parseInt(H.value);X=L.checked||X==N&&Z==N?null:{from:Math.max(0,
Math.min(A-1,X-1)),to:Math.max(0,Math.min(A-1,Z-1))}}d.downloadFile("pdf",null,null,!O.checked,l?!0:!L.checked&&null==X,!P.checked,null!=R&&R.checked,null,null,V.checked,null!=W&&W.checked,X)}),null,mxResources.get("export"));d.showDialog(n.container,300,z,!0,!0)}else d.showDialog((new PrintDialog(d,mxResources.get("formatPdf"))).container,360,null!=d.pages&&1<d.pages.length&&(d.editor.editable||"1"!=urlParams["hide-pages"])?470:390,!0,!0)}));d.actions.addAction("open...",function(){d.pickFile()}); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
J.formatElt.style.width)}function f(J,c){function e(p,t){var x=J.menus.get(p);p=k.addMenu(t,mxUtils.bind(this,function(){x.funct.apply(this,arguments)}));p.style.cssText="position:absolute;border-width:1px;cusor:pointer;border-style:none;height:24px;bottom:0px;text-align:center;padding:8px 6px 0 6px;border-top-style:solid;width:50%;height:32px;box-sizing:border-box;font-size:11px;";p.className="geTitle";c.appendChild(p);return p}var k=new Menubar(J,c);if(Editor.enableCustomLibraries&&("1"!=urlParams.embed||
"1"==urlParams.libraries))if(null!=J.actions.get("newLibrary")){var q=document.createElement("div");q.style.cssText="position:absolute;border-width:1px;cusor:pointer;border-style:none;height:24px;bottom:0px;text-align:center;padding:8px 6px 0 6px;border-top-style:solid;width:50%;height:32px;box-sizing:border-box;font-size:11px;";q.className="geTitle";mxUtils.write(q,mxResources.get("newLibrary"));c.appendChild(q);mxEvent.addListener(q,"click",this.actions.get("newLibrary").funct);q=q.cloneNode(!1);
q.style.left="50%";q.style.borderLeftStyle="solid";mxUtils.write(q,mxResources.get("openLibrary"));c.appendChild(q);mxEvent.addListener(q,"click",this.actions.get("openLibrary").funct)}else q=e("newLibrary",mxResources.get("newLibrary")),q.style.fontSize="11px",q.style.left="0",q=e("openLibraryFrom",mxResources.get("openLibraryFrom")),q.style.borderLeftStyle="solid",q.style.fontSize="11px",q.style.left="50%";c.appendChild(J.sidebar.container);c.style.overflow="hidden"}function m(J,c){if(EditorUi.windowed){var e= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
EditorUi.prototype.loadOrgChartLayouts=function(c){this.createTimeout(null,mxUtils.bind(this,function(e){var k=mxUtils.bind(this,function(){this.loadingOrgChart=!1;e.clear()&&(Graph.layoutNames.push("mxOrgChartLayout"),this.spinner.stop(),c())}),q=mxUtils.bind(this,function(p){this.loadingOrgChart=!1;e.clear()&&this.handleError(p)});"undefined"!==typeof mxOrgChartLayout||this.loadingOrgChart||this.isOffline(!0)?k():this.spinner.spin(document.body,mxResources.get("loading"))&&(this.loadingOrgChart=
!0,"1"==urlParams.dev?mxscript("js/orgchart/bridge.min.js",function(){mxscript("js/orgchart/bridge.collections.min.js",function(){mxscript("js/orgchart/OrgChart.Layout.min.js",function(){mxscript("js/orgchart/mxOrgChartLayout.js",k,null,null,null,q)},null,null,null,q)},null,null,null,q)},null,null,null,q):mxscript(DRAWIO_BASE_URL+"/js/orgchart.min.js",k,null,null,null,q))}),onerror)};EditorUi.prototype.importCsv=function(c,e){this.loadOrgChartLayouts(mxUtils.bind(this,function(){this.doImportCsv(c, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
t.defaultLibraryName=mxResources.get("untitledLibrary");var C=document.createElement("div");C.className="geMenubarContainer";var I=null,B=new Menubar(t,C);t.statusContainer=t.createStatusContainer();t.statusContainer.style.position="relative";t.statusContainer.style.maxWidth="";t.statusContainer.style.color="gray";t.statusContainer.style.cursor="default";var T=t.hideCurrentMenu;t.hideCurrentMenu=function(){T.apply(this,arguments);this.editor.graph.popupMenuHandler.hideMenu()};var l=t.descriptorChanged; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
mxUtils.bind(this,function(V){window.clearTimeout(O);H&&y(Editor.createSvgDataUri(V.getText()))}),function(){window.clearTimeout(O);H&&y(Editor.svgBrokenImage.src)});else{var P=new Image;this.crossOriginImages&&(P.crossOrigin="anonymous");P.onload=function(){window.clearTimeout(O);if(H)try{var V=document.createElement("canvas"),R=V.getContext("2d");V.height=P.height;V.width=P.width;R.drawImage(P,0,0);y(V.toDataURL())}catch(W){y(Editor.svgBrokenImage.src)}};P.onerror=function(){window.clearTimeout(O);
H&&y(Editor.svgBrokenImage.src)};P.src=g}}catch(V){y(Editor.svgBrokenImage.src)}};Editor.prototype.convertImages=function(g,y,H,O){null==O&&(O=this.createImageUrlConverter());var P=0,V=H||{};H=mxUtils.bind(this,function(R,W){R=g.getElementsByTagName(R);for(var X=0;X<R.length;X++)mxUtils.bind(this,function(Z){try{if(null!=Z){var Y=O.convert(Z.getAttribute(W));if(null!=Y&&"data:"!=Y.substring(0,5)){var ea=V[Y];null==ea?(P++,this.convertImageToDataUri(Y,function(fa){null!=fa&&(V[Y]=fa,Z.setAttribute(W, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
EditorUi.prototype.diffCell=function(b,f){function m(D){return null!=D&&"object"===typeof D&&"number"===typeof D.nodeType&&"string"===typeof D.nodeName&&"function"===typeof D.getAttribute}var d={};b.vertex!=f.vertex&&(d.vertex=f.vertex?1:0);b.edge!=f.edge&&(d.edge=f.edge?1:0);b.connectable!=f.connectable&&(d.connectable=f.connectable?1:0);if((null!=b.parent?null==f.parent:null!=f.parent)||null!=b.parent&&null!=f.parent&&b.parent.getId()!=f.parent.getId())d.parent=null!=f.parent?f.parent.getId():""; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
p=null;q.getModel().beginUpdate();try{p=q.insertVertex(null,null,"<pre>"+c+"</pre>",e,k,1,1,"text;html=1;align=left;verticalAlign=top;"),q.updateCellSize(p,!0)}finally{q.getModel().endUpdate()}return p};EditorUi.prototype.insertTextAt=function(c,e,k,q,p,t,x,C){t=null!=t?t:!0;x=null!=x?x:!0;if(null!=c)if(Graph.fileSupport&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c))this.isOffline()?this.showError(mxResources.get("error"),mxResources.get("notInOffline")):this.parseFileData(c.replace(/\s+/g, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
1));try{e=JSON.parse(c)}catch(q){}}}return e};EditorUi.prototype.updateHashObject=function(){if(null!=this.currentFile&&""!=this.currentFile.getHash()&&null!=this.currentPage&&0<this.getSelectedPageIndex()){var c=this.getHashObject();c.pageId=this.currentPage.getId();this.setHashObject(c)}else this.setHashObject(null)};EditorUi.prototype.setHashObject=function(c){if(Editor.enableHashObjects){var e=window.location.hash;if(null==e||""==e)e="#";var k=e.lastIndexOf("#");0<k&&(e=e.substring(0,k));try{null==
c||mxUtils.isEmptyObject(c)||(e=e+"#"+encodeURIComponent(JSON.stringify(c)))}catch(q){}window.location.hash=e}};EditorUi.prototype.loadDescriptor=function(c,e,k){var q=window.location.hash,p=mxUtils.bind(this,function(x){var C=null!=c.data?c.data:"";null!=x&&0<x.length&&(0<C.length&&(C+="\n"),C+=x);x=new LocalFile(this,"csv"!=c.format&&0<C.length?C:this.emptyDiagramXml,null!=urlParams.title?decodeURIComponent(urlParams.title):this.defaultFilename,!0);x.getHash=function(){return q};this.fileLoaded(x); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function(M){return this.isTreeEdge(M)}))};Graph.prototype.getIncomingTreeEdges=function(d,u){return this.getTreeEdges(d,u,!0,!1,!1)};Graph.prototype.getOutgoingTreeEdges=function(d,u){return this.getTreeEdges(d,u,!1,!0,!1)};var f=EditorUi.prototype.init;EditorUi.prototype.init=function(){f.apply(this,arguments);this.editor.isChromelessView()&&!this.editor.editable||this.addTrees()};EditorUi.prototype.addTrees=function(){function d(A){return k.isVertex(A)&&v(A)}function u(A){var N=!1;null!=A&&(N="1"== | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.libraryLoaded(c,q,k.documentElement.getAttribute("title"),e)}else throw{message:mxResources.get("notALibraryFile")};};EditorUi.prototype.getLibraryStorageHint=function(c){return""};EditorUi.prototype.libraryLoaded=function(c,e,k,q){if(null!=this.sidebar){c.constructor!=LocalLibrary&&mxSettings.addCustomLibrary(c.getHash());".scratchpad"==c.title&&(this.scratchpad=c);var p=this.sidebar.palettes[c.getHash()];p=null!=p?p[p.length-1].nextSibling:null;this.removeLibrarySidebar(c.getHash());var t= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
N);var X=mxUtils.bind(this,function(Z,Y,ea){W.innerText="";mxUtils.write(W,Math.round(100*t.editor.graph.view.scale*(null!=ea?ea:1))+"%")});t.editor.graph.view.addListener(mxEvent.EVENT_SCALE,X);t.editor.addListener("resetGraphView",X);t.editor.addListener("pageSelected",X);t.editor.graph.addListener("zoomPreview",mxUtils.bind(this,function(Z,Y){X(Z,Y,Y.getProperty("factor"))}))})(V);var R=t.setGraphEnabled;t.setGraphEnabled=function(){R.apply(this,arguments);null!=this.tabContainer&&(V.style.visibility=
this.tabContainer.style.visibility,this.diagramContainer.style.bottom="0"!=urlParams.pages&&"hidden"!=this.tabContainer.style.visibility?this.tabContainerHeight+"px":"0px")}}p.appendChild(C);p.appendChild(t.diagramContainer);q.appendChild(p);t.updateTabContainer();!EditorUi.windowed&&1E3<=d&&b(this,!0);p.appendChild(t.tabContainer);k();mxEvent.addListener(window,"resize",function(){k();null!=t.sidebarWindow&&t.sidebarWindow.window.fit();null!=t.formatWindow&&t.formatWindow.window.fit();null!=t.actions.outlineWindow&& | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
V[R];V.stroke!=mxConstants.NONE&&null!=V.stroke||delete this.nextShape.options.stroke;V.filled||delete this.nextShape.options.fill;this.passThrough=!0;this.rc.draw(this.nextShape);this.passThrough=!1}};g.prototype.stroke=function(){this.passThrough?this.originalStroke.apply(this.canvas,arguments):this.drawPath(this.getStyle(!0,!1))};g.prototype.fill=function(){this.passThrough?this.originalFill.apply(this.canvas,arguments):this.drawPath(this.getStyle(!1,!0))};g.prototype.fillAndStroke=function(){this.passThrough? | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
(I?null!=Q.resp&&0<Q.resp.length&&null!=Q.resp[0]?(T=Q.resp[0],I=!1,E()):n():null!=Q.resp&&0<Q.resp.length&&null!=Q.resp[0]?A(Q.resp[0]):z())}}catch(L){console.log(L)}});window.addEventListener("message",x)}})));c(t);t.onversionchange=function(){t.close()}}catch(x){null!=e?e(x):null!=window.console&&console.warn(x)}});q.onerror=e;q.onblocked=function(){}}catch(p){null!=e?e(p):null!=window.console&&console.error(p)}else null!=e&&e(Error("IndexedDB not supported"))}else c(this.database)};EditorUi.prototype.setDatabaseItem= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
L.spin(ca);var la=function(ma,oa,ha){Q=0;L.stop();Ha=ma;ha=ha||{};var ja=0,sa;for(sa in ha)ja+=ha[sa].length;if(oa)ca.innerText=oa;else if(0==ma.length&&0==ja)ca.innerText=mxResources.get("noDiagrams",null,"No Diagrams Found");else if(ca.innerText="",0<ja){wa.style.display="";ca.style.left="160px";wa.innerText="";Da=0;ua={"draw.io":ma};for(sa in ha)ua[sa]=ha[sa];l()}else t(!0)};aa?J(Y.value,la):S(la)};S&&(n=mxUtils.button(mxResources.get("Recent",null,"Recent"),function(){Z()}),k.appendChild(n),P.push(n)); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
null,null,null,!0,null,null,p,k,q);this.showDialog(c.container,620,460,!0,!1);c.init()};EditorUi.prototype.showBackgroundImageDialog=function(c,e,k,q){c=null!=c?c:mxUtils.bind(this,function(p,t,x,C){t||(p=new ChangePageSetup(this,q?x:null,p),p.ignoreColor=!q,null!=C&&q&&(p.shadowVisible=C),this.editor.graph.model.execute(p))});c=new BackgroundImageDialog(this,c,e,k,q);this.showDialog(c.container,400,q?240:220,!0,!0);c.init()};EditorUi.prototype.showLibraryDialog=function(c,e,k,q,p){c=new LibraryDialog(this,
c,e,k,q,p);this.showDialog(c.container,640,440,!0,!1,mxUtils.bind(this,function(t){t&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()}));c.init()};var m=EditorUi.prototype.createFormat;EditorUi.prototype.createFormat=function(c){var e=m.apply(this,arguments);this.editor.graph.addListener("viewStateChanged",mxUtils.bind(this,function(k){this.editor.graph.isSelectionEmpty()&&e.refresh()}));return e};EditorUi.prototype.handleError=function(c,e,k,q,p,t,x){var C=null!=this.spinner&& | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
StorageFile.listFiles=function(b,f,m,d){b.getDatabaseItems(function(u){var v=[];if(null!=u)for(var D=0;D<u.length;D++)"."==u[D].title.charAt(0)||null!=f&&u[D].type!=f||v.push(u[D]);m(v)},function(){null==b.database?m(StorageFile.listLocalStorageFiles(f)):null!=d&&d()},"filesInfo")};StorageFile.deleteFile=function(b,f,m,d){b.removeDatabaseItem([f,f],m,function(){null==b.database?(localStorage.removeItem(f),m()):null!=d&&d()},["files","filesInfo"])};StorageLibrary=function(b,f,m){StorageFile.call(this,b,f,m)};mxUtils.extend(StorageLibrary,StorageFile);StorageLibrary.prototype.type="L";StorageLibrary.prototype.isAutosave=function(){return!0};StorageLibrary.prototype.saveAs=function(b,f,m){this.saveFile(b,!1,f,m)};StorageLibrary.prototype.getHash=function(){return"L"+encodeURIComponent(this.title)};StorageLibrary.prototype.getTitle=function(){return".scratchpad"==this.title?mxResources.get("scratchpad"):this.title}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
null;x=mxUtils.button("",mxUtils.bind(this,function(C){this.pickColor(t||"none",function(I){t=I;k()});mxEvent.consume(C)}));k();x.style.padding=mxClient.IS_FF?"4px 2px 4px 2px":"4px";x.style.marginLeft="4px";x.style.height="22px";x.style.width="22px";x.style.position="relative";x.style.top=mxClient.IS_IE||mxClient.IS_IE11||mxClient.IS_EDGE?"6px":"1px";x.className="geColorBtn";c.appendChild(x);mxUtils.br(c);return{getColor:function(){return t},getTarget:function(){return q.value},focus:function(){q.focus()}}}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
}finally{e.getModel().endUpdate()}t&&(e.setSelectionCell(k),e.scrollCellToVisible(k))}};m=mxUtils.button(mxResources.get("preview"),function(){c(G,S,!1)});m.className="geBtn";K.appendChild(m);m=mxUtils.button(mxResources.get("apply"),function(){c(b.editor.graph,f,!0)});m.className="geBtn gePrimaryBtn";K.appendChild(m);b.editor.cancelFirst||K.appendChild(u);F.appendChild(K);D.appendChild(F);v.appendChild(D);this.container=v},CustomDialog=function(b,f,m,d,u,v,D,F,K,M,G,S){var J=document.createElement("div"); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
return Editor.updateCRC(c,e,k,q)};EditorUi.prototype.crc32=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: crc32");return Editor.crc32(c)};EditorUi.prototype.writeGraphModelToPng=function(c,e,k,q,p){EditorUi.logEvent("SHOULD NOT BE CALLED: writeGraphModelToPng");return Editor.writeGraphModelToPng(c,e,k,q,p)};EditorUi.prototype.getLocalStorageFileNames=function(){if("1"==localStorage.getItem(".localStorageMigrated")&&"1"!=urlParams.forceMigration)return null;for(var c=[],e=0;e<localStorage.length;e++){var k= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
za,this.stylesheet=da,this.refresh());return Ba};var I=mxCellRenderer.prototype.destroy;mxCellRenderer.prototype.destroy=function(g){I.apply(this,arguments);null!=g.secondLabel&&(g.secondLabel.destroy(),g.secondLabel=null)};mxCellRenderer.prototype.getShapesForState=function(g){return[g.shape,g.text,g.secondLabel,g.control]};var B=mxGraphView.prototype.resetValidationState;mxGraphView.prototype.resetValidationState=function(){B.apply(this,arguments);this.enumerationState=0};var T=mxGraphView.prototype.stateValidated; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
(function(){var b=new mxObjectCodec(new ChangeGridColor,["ui"]);b.beforeDecode=function(f,m,d){d.ui=f.ui;return m};mxCodecRegistry.register(b)})();(function(){EditorUi.VERSION="21.2.8";EditorUi.compactUi="atlas"!=Editor.currentTheme;Editor.isDarkMode()&&(mxGraphView.prototype.gridColor=mxGraphView.prototype.defaultDarkGridColor);EditorUi.enableLogging="1"!=urlParams.stealth&&"1"!=urlParams.lockdown&&(/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname))&&"support.draw.io"!=window.location.hostname;EditorUi.drawHost=window.DRAWIO_BASE_URL;EditorUi.lightboxHost=window.DRAWIO_LIGHTBOX_URL; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
e[k].parentNode&&"root"!=e[k].parentNode.nodeName&&null!=e[k].parentNode.parentNode&&(e[k].setAttribute("id",e[k].parentNode.getAttribute("id")),e[k].parentNode.parentNode.replaceChild(e[k],e[k].parentNode));return c};EditorUi.prototype.synchronizeCurrentFile=function(c){var e=this.getCurrentFile();null!=e&&(e.savingFile?this.handleError({message:mxResources.get("busy")}):!c&&e.invalidChecksum?e.handleFileError(null,!0):this.spinner.spin(document.body,mxResources.get("updatingDocument"))&&(e.clearAutosave(),
this.editor.setStatus(""),c?e.reloadFile(mxUtils.bind(this,function(){e.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(k){e.handleFileError(k,!0)})):e.synchronizeFile(mxUtils.bind(this,function(){e.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(k){e.handleFileError(k,!0)}))))};EditorUi.prototype.getFileData=function(c,e,k,q,p,t,x,C,I,B,T){p=null!=p?p:!0;t=null!=t?t:!1;B=null!=B?B:!Editor.defaultCompressed;var l=this.editor.graph;if(e||!c&&null!= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
EditorUi.prototype.importZipFile=function(c,e,k){var q=this,p=mxUtils.bind(this,function(){this.loadingExtensions=!1;"undefined"!==typeof JSZip?JSZip.loadAsync(c).then(function(t){if(mxUtils.isEmptyObject(t.files))k();else{var x=0,C,I=!1;t.forEach(function(B,T){B=T.name.toLowerCase();"diagram/diagram.xml"==B?(I=!0,T.async("string").then(function(l){0==l.indexOf("<mxfile ")?e(l):k()})):0==B.indexOf("versions/")&&(B=parseInt(B.substr(9)),B>x&&(x=B,C=T))});0<x?C.async("string").then(function(B){(new XMLHttpRequest).upload&&
q.isRemoteFileFormat(B,c.name)?q.isOffline()?q.showError(mxResources.get("error"),mxResources.get("notInOffline"),null,k):q.parseFileData(B,mxUtils.bind(this,function(T){4==T.readyState&&(200<=T.status&&299>=T.status?e(T.responseText):k())}),c.name):k()}):I||k()}},function(t){k(t)}):k()});"undefined"!==typeof JSZip||this.loadingExtensions||this.isOffline(!0)?p():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",p,null,null,null,k))};EditorUi.prototype.importFile=function(c,e,k,q,p,t,x,C, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
var X=this.fill,Z=this.stroke;this.stroke=this.fill=null;var Y=this.configurePointerEvents,ea=V.setStrokeColor;V.setStrokeColor=function(){};var fa=V.setFillColor;V.setFillColor=function(){};W||null==X||(this.configurePointerEvents=function(){});V.handJiggle.passThrough=!0;O.apply(this,arguments);V.handJiggle.passThrough=!1;V.setFillColor=fa;V.setStrokeColor=ea;this.configurePointerEvents=Y;this.stroke=Z;this.fill=X;V.restore();W&&null!=X&&(V.addTolerance=function(){})}O.apply(this,arguments);V.addTolerance= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
mxDualRuler.prototype.setUnit=function(b){this.vRuler.setUnit(b);this.hRuler.setUnit(b)};mxDualRuler.prototype.setStyle=function(b){this.vRuler.setStyle(b);this.hRuler.setStyle(b)};mxDualRuler.prototype.destroy=function(){this.vRuler.destroy();this.hRuler.destroy();this.ui.refresh=this.editorUiRefresh;mxGuide.prototype.move=this.origGuideMove;mxGuide.prototype.destroy=this.origGuideDestroy;this.ui.getDiagramContainerOffset=this.editorUiGetDiagContOffset};function mxFreehand(b){var f=null!=b.view&&null!=b.view.canvas?b.view.canvas.ownerSVGElement:null;if(null!=b.container&&null!=f){b.addListener(mxEvent.ESCAPE,mxUtils.bind(this,function(){this.stopDrawing()}));var m=mxFreehand.prototype.NORMAL_SMOOTHING,d=null,u=[],v,D=[],F,K=!1,M=!0,G=!0,S=!0,J=!0,c=[],e=!1,k=!1,q=!1,p={size:5,thinning:.5,smoothing:.5,streamline:.5,start:{taper:0,cap:!0},end:{taper:0,cap:!0}},t=!0;this.setClosedPath=function(z){K=z};this.setAutoClose=function(z){M=z};this.setAutoInsert= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
c=A;this.confirmImageResize(function(U){E=U;L()},I)}else L()};EditorUi.prototype.isBlankFile=function(){return null!=this.pages&&1==this.pages.length&&this.isDiagramEmpty()&&this.currentPage.getName()==mxResources.get("pageWithNumber",[1])};EditorUi.prototype.confirmImageResize=function(c,e){e=null!=e?e:!1;var k=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},q=isLocalStorage||mxClient.IS_CHROMEAPP?mxSettings.getResizeImages():null,p=function(t,x){if(t||e)mxSettings.setResizeImages(t?
x:null),mxSettings.save();k();c(x)};null==q||e?this.showDialog((new ConfirmDialog(this,mxResources.get("resizeLargeImages"),function(t){p(t,!0)},function(t){p(t,!1)},mxResources.get("resize"),mxResources.get("actualSize"),'<img style="margin-top:8px;" src="'+Editor.loResImage+'"/>','<img style="margin-top:8px;" src="'+Editor.hiResImage+'"/>',isLocalStorage||mxClient.IS_CHROMEAPP)).container,340,isLocalStorage||mxClient.IS_CHROMEAPP?220:200,!0,!0):p(!1,q)};EditorUi.prototype.parseFile=function(c,e, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
"#000000")),wa=mxUtils.setStyle(wa,mxConstants.STYLE_GRADIENTCOLOR,mxUtils.getValue(pa,mxConstants.STYLE_GRADIENTCOLOR,null)),O.getModel().isVertex(Aa[xa])&&(wa=mxUtils.setStyle(wa,mxConstants.STYLE_FONTCOLOR,mxUtils.getValue(pa,mxConstants.STYLE_FONTCOLOR,null))));O.getModel().setStyle(Aa[xa],wa)}}finally{O.getModel().endUpdate()}}));ba.className="geStyleButton";ba.style.width="36px";ba.style.height=10>=this.defaultColorSchemes.length?"24px":"30px";ba.style.margin="0px 6px 6px 0px";if(null!=Ba){var ca= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
mxscript("https://apis.google.com/js/api.js?onload=DrawGapiClientCallback",null,null,null,mxClient.IS_SVG):"undefined"===typeof window.gapi&&(window.DriveClient=null)}"0"!=urlParams.math&&Editor.initMath();if("1"==urlParams.configure){var M=window.opener||window.parent,G=function(J){if(J.source==M)try{var c=JSON.parse(J.data);null!=c&&"configure"==c.action&&(mxEvent.removeListener(window,"message",G),Editor.configure(c.config),mxSettings.load(),c.colorSchemeMeta&&mxmeta("color-scheme","dark light"),
m())}catch(e){null!=window.console&&console.log("Error in configure message: "+e,J.data)}};mxEvent.addListener(window,"message",G);M.postMessage(JSON.stringify({event:"configure"}),"*")}else{if(null==Editor.config){if(null!=window.DRAWIO_CONFIG)try{EditorUi.debug("Using global configuration",window.DRAWIO_CONFIG),Editor.configure(window.DRAWIO_CONFIG),mxSettings.load()}catch(J){null==window.console||EditorUi.isElectronApp?(mxLog.show(),mxLog.debug(J.stack)):console.error(J)}if(isLocalStorage&&null!= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
x.parentNode.removeChild(x)}catch(I){}}else this.createEchoRequest(c,e,k,q,p).simulate(document,"_blank")}};EditorUi.prototype.createEchoRequest=function(c,e,k,q,p,t){c="xml="+encodeURIComponent(c);return new mxXmlRequest(SAVE_URL,c+(null!=k?"&mime="+k:"")+(null!=p?"&format="+p:"")+(null!=t?"&base64="+t:"")+(null!=e?"&filename="+encodeURIComponent(e):"")+(q?"&binary=1":""))};EditorUi.prototype.base64ToBlob=function(c,e){e=e||"";c=atob(c);for(var k=c.length,q=Math.ceil(k/1024),p=Array(q),t=0;t<q;++t){for(var x= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
k=document.createElement("div");k.style.whiteSpace="nowrap";k.style.height="30px";z.appendChild(k);n=mxUtils.button(mxResources.get("Templates",null,"Templates"),function(){wa.style.display="";qa.style.display="";ca.style.left="160px";X(0);ca.scrollTop=0;ca.innerText="";Q=0;V!=Ha&&(Ha=V,ua=R,Da=W,wa.innerText="",l(),V=null)});P.push(n);k.appendChild(n);var Z=function(aa){wa.style.display="none";qa.style.display="none";ca.style.left="30px";X(aa?-1:1);null==V&&(V=Ha);ca.scrollTop=0;ca.innerText="";
L.spin(ca);var la=function(ma,oa,ha){Q=0;L.stop();Ha=ma;ha=ha||{};var ja=0,sa;for(sa in ha)ja+=ha[sa].length;if(oa)ca.innerText=oa;else if(0==ma.length&&0==ja)ca.innerText=mxResources.get("noDiagrams",null,"No Diagrams Found");else if(ca.innerText="",0<ja){wa.style.display="";ca.style.left="160px";wa.innerText="";Da=0;ua={"draw.io":ma};for(sa in ha)ua[sa]=ha[sa];l()}else t(!0)};aa?J(Y.value,la):S(la)};S&&(n=mxUtils.button(mxResources.get("Recent",null,"Recent"),function(){Z()}),k.appendChild(n),P.push(n)); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
null}v(S)}));m=!0}}catch(l){m=!1,null!=D&&D!=this.editor.graph&&null!=D.container.parentNode&&D.container.parentNode.removeChild(D.container)}m||window.clearTimeout(u);return m};App.prototype.createBackground=function(){var b=this.createDiv("background");b.style.position="absolute";b.style.background="white";b.style.left="0px";b.style.top="0px";b.style.bottom="0px";b.style.right="0px";mxUtils.setOpacity(b,100);return b}; | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
!this.editor.editable&&(k.getHash=function(){return"G"+e},window.location.hash="#"+k.getHash());null!=d&&d()}));return!0}return!1});!c()&&this.spinner.spin(document.body,mxResources.get("loading"))&&this.addListener("clientLoaded",c);return!0});this.loadTemplate(G,mxUtils.bind(this,function(c){this.spinner.stop();if(null!=c&&0<c.length){var e=this.defaultFilename;if(null==urlParams.title&&"1"!=urlParams.notitle){var k=G,q=G.lastIndexOf("."),p=k.lastIndexOf("/");q>p&&0<p&&(k=k.substring(p+1,q),q=G.substring(q), | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
arguments);M.style.backgroundColor=""};G.dblClick=function(){};var O=G.getSelectionModel().changeSelection;G.getSelectionModel().changeSelection=function(){O.call(this,[c],[c])}};K.onerror=function(){K.onload=null;K.src=Editor.errorImage};K.setAttribute("src",f);K.style.maxWidth="300px";K.style.maxHeight="300px";F.appendChild(K);D.appendChild(F);var M=document.createElement("div");M.style.width="300px";M.style.height="300px";M.style.overflow="hidden";M.style.backgroundColor="#fff9";D.appendChild(M); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
c.nodeName&&(x=c.hasAttribute("max-scale")?parseFloat(c.getAttribute("max-scale")):1);c=c.nextSibling}}finally{t.endUpdate()}null!=x&&this.chromelessResize&&this.chromelessResize(!0,x)}return k};EditorUi.prototype.getCopyFilename=function(c,e){var k=null!=c&&null!=c.getTitle()?c.getTitle():this.defaultFilename;c="";var q=k.lastIndexOf(".");0<=q&&(c=k.substring(q),k=k.substring(0,q));if(e){e=k;var p=new Date;k=p.getFullYear();q=p.getMonth()+1;var t=p.getDate(),x=p.getHours(),C=p.getMinutes();p=p.getSeconds(); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function(K){return mxEvent.isMouseEvent(K.getEvent())};var V=this.click;this.click=function(K){var U=null==K.state&&null!=K.sourceState&&this.isCellLocked(this.getLayerForCell(K.sourceState.cell));if(this.isEnabled()&&!U||K.isConsumed())return V.apply(this,arguments);U=U?K.sourceState.cell:K.getCell();null!=U&&(U=this.getClickableLinkForCell(U),null!=U&&(this.isCustomLink(U)?this.customLinkClicked(U):this.openLink(U)))};this.tooltipHandler.getStateForEvent=function(K){return K.sourceState};var aa= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
W)&&(O=0<O.length?O+" "+W:W,V=!0)}V&&this.setAttributeForCell(g[H],"tags",O)}}finally{this.model.endUpdate()}}};Graph.prototype.removeTagsForCells=function(g,y){if(0<g.length&&0<y.length){this.model.beginUpdate();try{for(var H=0;H<g.length;H++){var O=this.getTagsForCell(g[H]);if(0<O.length){for(var P=O.split(" "),V=!1,R=0;R<y.length;R++){var W=mxUtils.indexOf(P,y[R]);0<=W&&(P.splice(W,1),V=!0)}V&&this.setAttributeForCell(g[H],"tags",P.join(" "))}}}finally{this.model.endUpdate()}}};Graph.prototype.toggleCells= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.tooltipHandler.show;this.tooltipHandler.show=function(){aa.apply(this,arguments);if(null!=this.div)for(var K=this.div.getElementsByTagName("a"),U=0;U<K.length;U++)null!=K[U].getAttribute("href")&&null==K[U].getAttribute("target")&&K[U].setAttribute("target","_blank")};this.tooltipHandler.getStateForEvent=function(K){return K.sourceState};this.getCursorForMouseEvent=function(K){var U=null==K.state&&null!=K.sourceState&&this.isCellLocked(K.sourceState.cell);return this.getCursorForCell(U?K.sourceState.cell: | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
document.body.clientHeight)-80,800),null!=ia.title?mxResources.get(ia.title,null,ia.title):null,!0,new mxPoint(La,Ga),!0,null,!0);var Ma=document.createElement("div");Ma.className="geTempDlgDialogMask";L.appendChild(Ma);var ra=b.sidebar.hideTooltip;b.sidebar.hideTooltip=function(){Ma&&(L.removeChild(Ma),Ma=null,ra.apply(this,arguments),b.sidebar.hideTooltip=ra)};mxEvent.addListener(Ma,"click",function(){b.sidebar.hideTooltip()})}}var ja=null;if(pa||b.sidebar.currentElt==aa)b.sidebar.hideTooltip(); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.editor.addFontCss(c,this.editor.resolvedFontCss),this.editor.embedExtFonts(mxUtils.bind(this,function(k){try{null!=k&&this.editor.addFontCss(c,k),e(c)}catch(q){e(c)}}))}catch(k){e(c)}}))};EditorUi.prototype.exportImage=function(c,e,k,q,p,t,x,C,I,B,T,l,n){I=null!=I?I:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var z=this.editor.graph.isSelectionEmpty();k=null!=k?k:z;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.editor.exportToCanvas(mxUtils.bind(this,
function(E){this.spinner.stop();try{this.saveCanvas(E,p?this.getFileData(!0,null,null,null,k,C):null,I,null==this.pages||0==this.pages.length,T)}catch(A){this.handleError(A)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(E){this.spinner.stop();this.handleError(E)}),null,k,c||1,e,q,null,null,t,x,B,l,n)}catch(E){this.spinner.stop(),this.handleError(E)}}};EditorUi.prototype.isCorsEnabledForUrl=function(c){return this.editor.isCorsEnabledForUrl(c)};EditorUi.prototype.importXml=function(c, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
function n(A){null!=A&&(A=l(Editor.parseDiagramNode(A)));return A}mxEvent.addListener(T,"change",function(A){C=parseInt(T.value);n(I[C]);mxEvent.consume(A)});if("mxfile"==x.nodeName){var z=x.getElementsByTagName("diagram");I=[];for(var E=0;E<z.length;E++)I.push(z[E]);0<I.length&&n(I[C]);T.innerText="";if(1<I.length)for(T.style.display="",E=0;E<I.length;E++)z=document.createElement("option"),mxUtils.write(z,I[E].getAttribute("name")||mxResources.get("pageWithNumber",[E+1])),z.setAttribute("value", | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
0>Z&&(Z=P.strokeWidth/2);g.setStrokeAlpha(g.state.fillAlpha);g.setStrokeColor(P.fill||"");g.setStrokeWidth(Z);g.setDashed(!1);this._drawToContext(H,O,P);g.setDashed(X);g.setStrokeWidth(R);g.setStrokeColor(V);g.setStrokeAlpha(W)};y._drawToContext=function(H,O,P){H.begin();for(var V=0;V<O.ops.length;V++){var R=O.ops[V],W=R.data;switch(R.op){case "move":H.moveTo(W[0],W[1]);break;case "bcurveTo":H.curveTo(W[0],W[1],W[2],W[3],W[4],W[5]);break;case "lineTo":H.lineTo(W[0],W[1])}}H.end();"fillPath"===O.type&&
P.filled?H.fill():H.stroke()};return y};(function(){function g(V,R,W){this.canvas=V;this.rc=R;this.shape=W;this.canvas.setLineJoin("round");this.canvas.setLineCap("round");this.originalBegin=this.canvas.begin;this.canvas.begin=mxUtils.bind(this,g.prototype.begin);this.originalEnd=this.canvas.end;this.canvas.end=mxUtils.bind(this,g.prototype.end);this.originalRect=this.canvas.rect;this.canvas.rect=mxUtils.bind(this,g.prototype.rect);this.originalRoundrect=this.canvas.roundrect;this.canvas.roundrect= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
!navigator.onLine||!c&&("1"==urlParams.stealth||"1"==urlParams.lockdown)};EditorUi.prototype.isExternalDataComms=function(){return"1"!=urlParams.offline&&!this.isOffline()&&!this.isOfflineApp()};EditorUi.prototype.createSpinner=function(c,e,k){var q=null==c||null==e;k=null!=k?k:24;var p=new Spinner({lines:12,length:k,width:Math.round(k/3),radius:Math.round(k/2),rotate:0,color:Editor.isDarkMode()?"#c0c0c0":"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),t=p.spin;p.spin=function(C,I){var B=
!1;this.active||(t.call(this,C),this.active=!0,null!=I&&(q&&(e=Math.max(document.body.clientHeight||0,document.documentElement.clientHeight||0)/2,c=document.body.clientWidth/2-2),B=document.createElement("div"),B.style.position="absolute",B.style.whiteSpace="nowrap",B.style.background="#4B4243",B.style.color="white",B.style.fontFamily=Editor.defaultHtmlFont,B.style.fontSize="9pt",B.style.padding="6px",B.style.paddingLeft="10px",B.style.paddingRight="10px",B.style.zIndex=2E9,B.style.left=Math.max(0,
c)+"px",B.style.top=Math.max(0,e+70)+"px",mxUtils.setPrefixedStyle(B.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(B.style,"transform","translate(-50%,-50%)"),Editor.isDarkMode()||mxUtils.setPrefixedStyle(B.style,"boxShadow","2px 2px 3px 0px #ddd"),"..."!=I.substring(I.length-3,I.length)&&"!"!=I.charAt(I.length-1)&&(I+="..."),B.innerHTML=I,C.appendChild(B),p.status=B),this.pause=mxUtils.bind(this,function(){var T=function(){};this.active&&(T=mxUtils.bind(this,function(){this.spin(C,I)}));this.stop();
return T}),B=!0);return B};var x=p.stop;p.stop=function(){x.call(this);this.active=!1;null!=p.status&&null!=p.status.parentNode&&p.status.parentNode.removeChild(p.status);p.status=null};p.pause=function(){return function(){}};return p};EditorUi.prototype.isCompatibleString=function(c){try{var e=mxUtils.parseXml(c),k=this.editor.extractGraphModel(e.documentElement,!0);return null!=k&&0==k.getElementsByTagName("parsererror").length}catch(q){}return!1};EditorUi.prototype.isVisioData=function(c){return 8< | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.toolbar.edgeShapeMenu&&this.toolbar.edgeShapeMenu.setEnabled(c),null!=this.toolbar.edgeStyleMenu&&this.toolbar.edgeStyleMenu.setEnabled(c));this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};EditorUi.prototype.scheduleSanityCheck=function(){};EditorUi.prototype.stopSanityCheck=function(){};EditorUi.prototype.isDiagramActive=function(){var c=this.getCurrentFile();return null!=c&&c.isEditable()||"1"==urlParams.embed&&
this.editor.graph.isEnabled()};var G=EditorUi.prototype.createSidebar;EditorUi.prototype.createSidebar=function(c){var e=G.apply(this,arguments);this.addListener("darkModeChanged",mxUtils.bind(this,function(){e.refresh()}));this.addListener("sketchModeChanged",mxUtils.bind(this,function(){e.refresh()}));return e};var S=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){S.apply(this,arguments);var c=this.editor.graph,e=this.getCurrentFile(),k=this.getSelectionState(), | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
this.editor.graph.setBackgroundImage;var G=this.pages[0];this.currentPage==G?D.setBackgroundImage(F):null!=G.viewState&&null!=G.viewState&&(F=G.viewState.backgroundImage,D.setBackgroundImage(F));D.getGlobalVariable=function(l){return"page"==l?G.getName():"pagenumber"==l?1:M.apply(this,arguments)};D.getGlobalVariable=M;document.body.appendChild(D.container);D.model.setRoot(G.root)}if(mxClient.IS_CHROMEAPP||this.useCanvasForExport)this.editor.exportToCanvas(mxUtils.bind(this,function(l){try{D!=this.editor.graph&& | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
ColorDialog.resetRecentColors=function(){K.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()}}"undefined"!==typeof window.EditDataDialog&&(EditDataDialog.getDisplayIdForCell=function(g,y){var H=null;null!=g.editor.graph.getModel().getParent(y)?H=y.getId():null!=g.currentPage&&(H=g.currentPage.getId());return H});if(null!=window.StyleFormatPanel){var M=Format.prototype.init;Format.prototype.init=function(){M.apply(this,arguments);this.editorUi.editor.addListener("fileLoaded",
this.update)};var G=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed||this.editorUi.editor.chromeless?G.apply(this,arguments):this.clear()};DiagramFormatPanel.prototype.isMathOptionVisible=function(g){return"simple"==Editor.currentTheme||"sketch"==Editor.currentTheme||"min"==Editor.currentTheme};var S=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(g){g=S.apply(this,arguments);var y=this.editorUi, | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
O));this.graph.isRelativeUrl(R)&&(R=null!=P?P+R:window.location.protocol+"//"+window.location.hostname+("/"==R.charAt(0)?"":g)+R);y.push('url("'+R+'"'+H[V].substring(O))}else y.push(H[V])}else y=[g]}return null!=y?y.join(""):null};Editor.prototype.mapFontUrl=function(g,y,H){/^https?:\/\//.test(y)&&!this.isCorsEnabledForUrl(y)&&(y=PROXY_URL+"?url="+encodeURIComponent(y));H(g,y)};Editor.prototype.embedCssFonts=function(g,y){var H=g.split("url("),O=0;null==this.cachedFonts&&(this.cachedFonts={});var P= | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
arguments))};var q=mxSvgCanvas2D.prototype.updateTextNodes;mxSvgCanvas2D.prototype.updateTextNodes=function(g,y,H,O,P,V,R,W,X,Z,Y){q.apply(this,arguments);Graph.processFontAttributes(Y)};var p=mxText.prototype.redraw;mxText.prototype.redraw=function(){p.apply(this,arguments);null!=this.node&&"DIV"==this.node.nodeName&&Graph.processFontAttributes(this.node)};Graph.prototype.createTagsDialog=function(g,y,H){function O(){for(var da=R.getSelectionCells(),za=[],Ca=0;Ca<da.length;Ca++)R.isCellVisible(da[Ca])&&
za.push(da[Ca]);R.setSelectionCells(za)}function P(da){R.setHiddenTags(da?[]:W.slice());O();R.refresh()}function V(da,za){Z.innerText="";if(0<da.length){var Ca=document.createElement("table");Ca.setAttribute("cellpadding","2");Ca.style.boxSizing="border-box";Ca.style.tableLayout="fixed";Ca.style.width="100%";var Ba=document.createElement("tbody");if(null!=da&&0<da.length)for(var ba=0;ba<da.length;ba++)(function(ca){function qa(){var pa=R.getCellsForTags([ca],null,null,!0);R.isEnabled()?R.setSelectionCells(pa): | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
x.appendChild(z);var E=document.createElement("div");E.style.marginTop="10px";if(v){var A=function(U,g,y,H,O){if(null==O||"1"!=O.html)return H=U.toLowerCase().indexOf(g,H),0>H?U:U.substr(0,H)+y+U.substr(H+g.length);var P=U;g=mxUtils.htmlEntities(g);O=[];var V=-1;for(U=U.replace(/<br>/ig,"\n");-1<(V=U.indexOf("<",V+1));)O.push(V);V=U.match(/<[^>]*>/g);U=U.replace(/<[^>]*>/g,"");H=U.toLowerCase().indexOf(g,H);if(0>H)return P;P=H+g.length;y=mxUtils.htmlEntities(y);U=U.substr(0,H)+y+U.substr(P);for(var R=
0,W=0;W<O.length;W++){if(O[W]-R<H)U=U.substr(0,O[W])+V[W]+U.substr(O[W]);else{var X=O[W]-R<P?H+R:O[W]+(y.length-g.length);U=U.substr(0,X)+V[W]+U.substr(X)}R+=V[W].length}return U.replace(/\n/g,"<br>")},N=mxUtils.button(mxResources.get("replFind"),function(){try{if(null!=k&&null!=J){var U=J.cell,g=G.getLabel(U);G.isCellEditable(U)&&G.model.setValue(U,A(g,k,I.value,q-k.length,G.getCurrentCellStyle(U)));C.style.backgroundColor=K(!1,!0)?"":Editor.isDarkMode()?"#ff0000":"#ffcfcf"}}catch(y){b.handleError(y)}}); | 1 | JavaScript | CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. | https://cwe.mitre.org/data/definitions/79.html | safe |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.