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
function(T){"undefined"!==typeof MathJax&&"function"===typeof MathJax.typeset?Editor.doMathJaxRender(T):Editor.mathJaxQueue.push(T)};Editor.onMathJaxDone=function(){};var Q=Editor.prototype.init;Editor.prototype.init=function(){Q.apply(this,arguments);var T=mxUtils.bind(this,function(W,X){null!=this.graph.container&&this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)});this.graph.model.addListener(mxEvent.CHANGE,T);this.graph.addListener(mxEvent.REFRESH,T)};y=document.getElementsByTagName("script");
0
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
vulnerable
var PopupDialog=function(b,f,m,d,u){u=null!=u?u:!0;var v=document.createElement("div");v.style.textAlign="left";v.style.height="100%";mxUtils.write(v,mxResources.get("fileOpenLocation"));mxUtils.br(v);mxUtils.br(v);var E=mxUtils.button(mxResources.get("openInThisWindow"),function(){u&&b.hideDialog();null!=d&&d()});E.className="geBtn";E.style.marginBottom="8px";E.style.width="280px";v.appendChild(E);mxUtils.br(v);var F=mxUtils.button(mxResources.get("openInNewWindow"),function(){u&&b.hideDialog(); null!=m&&m();b.openLink(f,null,!0)});F.className="geBtn gePrimaryBtn";F.style.width=E.style.width;v.appendChild(F);mxUtils.br(v);mxUtils.br(v);mxUtils.write(v,mxResources.get("allowPopups"));this.container=v},ImageDialog=function(b,f,m,d,u,v,E,F){function L(){0<R.value.length?t.removeAttribute("disabled"):t.setAttribute("disabled","disabled")}v=null!=v?v:!0;var N=b.editor.graph,H=document.createElement("div");mxUtils.write(H,f);f=document.createElement("div");f.className="geTitle";f.style.backgroundColor=
0
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
vulnerable
fa[la]=ma),ma.push(oa))}ia=ia.nextSibling}l(Ea,Ta,Ha)}})}function z(ia){E&&(Ba.scrollTop=0,ea.innerText="",Qa.spin(ea),k=!1,V=!0,za.innerText=mxResources.get("recentDiag"),Z=null,E(Va,function(){g(mxResources.get("cannotLoad"));Va([])},ia?null:v))}function C(ia){if(""==ia)null!=G&&(G.click(),G=null);else{if(null==TemplatesDialog.tagsList[d]){var aa={};for(La in Ea)for(var la=Ea[La],ma=0;ma<la.length;ma++){var oa=la[ma];if(null!=oa.tags)for(var fa=oa.tags.toLowerCase().split(";"),ja=0;ja<fa.length;ja++)null==
0
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
vulnerable
5)&&"application/pdf"!==q.type||"image/svg"===q.type.substring(0,9)?p.readAsText(q):p.readAsDataURL(q)})(c[g])};EditorUi.prototype.openLocalFile=function(c,e,g,q,p){var t=this.getCurrentFile(),x=mxUtils.bind(this,function(){window.openFile=null;if(null==e&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var B=mxUtils.parseXml(c);null!=B&&(this.editor.setGraphXml(B.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,c,e||this.defaultFilename,g,q,p))});if(null!= c&&0<c.length)null==t||!t.isModified()&&(mxClient.IS_CHROMEAPP||EditorUi.isElectronApp||null!=q)?x():(mxClient.IS_CHROMEAPP||EditorUi.isElectronApp||null!=q)&&null!=t&&t.isModified()?this.confirm(mxResources.get("allChangesLost"),null,x,mxResources.get("cancel"),mxResources.get("discardChanges")):(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(c,e),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){null!=t&&t.isModified()?this.confirm(mxResources.get("allChangesLost"), null,x,mxResources.get("cancel"),mxResources.get("discardChanges")):x()})));else throw Error(mxResources.get("notADiagramFile"));};EditorUi.prototype.getBasenames=function(){var c={};if(null!=this.pages)for(var e=0;e<this.pages.length;e++)this.updatePageRoot(this.pages[e]),this.addBasenamesForCell(this.pages[e].root,c);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),c);e=[];for(var g in c)e.push(g);return e};EditorUi.prototype.addBasenamesForCell=function(c,e){function g(x){if(null!=
0
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
vulnerable
A&&"function"===typeof A.substring&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(A,"")?this.isOffline()?this.showError(mxResources.get("error"),mxResources.get("notInOffline")):this.parseFileData(A,mxUtils.bind(this,function(ba){4==ba.readyState&&(200<=ba.status&&299>=ba.status&&"<mxGraphModel"==ba.responseText.substring(0,13)?Ba(ba.responseText,I):this.handleError({message:413==ba.status?mxResources.get("diagramTooLarge"):mxResources.get("unknownError")}))}),""):null!=A&&"function"===typeof A.substring&& this.isLucidChartData(A)?this.convertLucidChart(A,mxUtils.bind(this,function(ba){Ba(ba)}),mxUtils.bind(this,function(ba){this.handleError(ba)})):null==A||"object"!==typeof A||null==A.format||null==A.data&&null==A.url?(A=l(A),Ba(A,I)):this.loadDescriptor(A,mxUtils.bind(this,function(ba){Ba(Ca(),I)}),mxUtils.bind(this,function(ba){this.handleError(ba,mxResources.get("errorLoadingFile"))}))}}));var x=window.opener||window.parent;t="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||
0
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
vulnerable
function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,t,x,null,1<p,I,c,g,q);t=this.isServices(p)?p>I?390:280:160;this.showDialog(e.container,420,t,!0,!0);e.init()};EditorUi.prototype.openInNewWindow=function(c,e,g){var q=window.open("about:blank");null==q||null==q.document?mxUtils.popup(c,!0):("image/svg+xml"!=e||mxClient.IS_SVG?"image/svg+xml"!=e||g?(c=g?c:btoa(unescape(encodeURIComponent(c))),q.document.write('<html><img style="max-width:100%;" src="data:'+e+";base64,"+ c+'"/></html>')):q.document.write("<html>"+c+"</html>"):q.document.write("<html><pre>"+mxUtils.htmlEntities(c,!1)+"</pre></html>"),q.document.close())};var d=EditorUi.prototype.addChromelessToolbarItems;EditorUi.prototype.isChromelessImageExportEnabled=function(){return"draw.io"!=this.getServiceName()||/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname)};EditorUi.prototype.addChromelessToolbarItems=function(c){if(null!=urlParams.tags){this.tagsDialog=
0
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
vulnerable
!0;Editor.enableRealtime=!0;Editor.compressXml=!0;Editor.defaultCompressed=!1;Editor.oneDriveInlinePicker=null!=window.urlParams&&"0"==window.urlParams.inlinePicker?!1:!0;Editor.globalVars=null;Editor.config=null;Editor.configVersion=null;Editor.defaultBorder=5;Editor.commonProperties=[{name:"enumerate",dispName:"Enumerate",type:"bool",defVal:!1,onChange:function(k){k.refresh()}},{name:"enumerateValue",dispName:"Enumerate Value",type:"string",defVal:"",isVisible:function(k,y){return"1"==mxUtils.getValue(k.style,
0
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
vulnerable
p+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.getHtml2=function(c,e,g,q,p){e=window.DRAWIO_VIEWER_URL||EditorUi.drawHost+"/js/viewer-static.min.js";null!=p&&(p=p.replace(/&/g,"&amp;"));c={highlight:"#0000ff",nav:this.editor.graph.foldingEnabled,resize:!0,xml:Graph.zapGremlins(c),toolbar:"pages zoom layers lightbox"};null!=this.pages&&null!=this.currentPage&&(c.page=mxUtils.indexOf(this.pages,this.currentPage)); return(null==p?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+"<!DOCTYPE html>\n<html"+(null!=p?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+(null==p?null!=g?"<title>"+mxUtils.htmlEntities(g)+"</title>\n":"":"<title>diagrams.net</title>\n")+(null!=p?'<meta http-equiv="refresh" content="0;URL=\''+p+"'\"/>\n":"")+'<meta charset="utf-8"/>\n</head>\n<body>\n<div class="mxgraph" style="max-width:100%;border:1px solid transparent;" data-mxgraph="'+ mxUtils.htmlEntities(JSON.stringify(c))+'"></div>\n'+(null==p?'<script type="text/javascript" src="'+e+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+p+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.setFileData=function(c){c=this.validateFileData(c);this.pages=this.fileNode=this.currentPage=null;var e=null!=c&&0<c.length?mxUtils.parseXml(c).documentElement:
0
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
vulnerable
K.pagecount=null!=c.pages?c.pages.length:1;K.page=null!=c.currentPage?c.currentPage.getName():"";K.pagenumber=null!=c.pages&&null!=c.currentPage?mxUtils.indexOf(c.pages,c.currentPage)+1:1;return K};var l=e.getGlobalVariable;e.getGlobalVariable=function(K){var O=c.getCurrentFile();return"filename"==K&&null!=O?O.getTitle():"page"==K&&null!=c.currentPage?c.currentPage.getName():"pagenumber"==K?null!=c.currentPage&&null!=c.pages?mxUtils.indexOf(c.pages,c.currentPage)+1:1:"pagecount"==K?null!=c.pages? c.pages.length:1:l.apply(this,arguments)};var n=null;this.addListener("fileDescriptorChanged",function(){var K=this.getCurrentFile();null!=K&&n!=K.getTitle()&&(n=null!=K.getTitle()?K.getTitle():this.defaultFilename,e.invalidateDescendantsWithPlaceholders(e.model.getRoot()),e.view.validate())});var z=e.labelLinkClicked;e.labelLinkClicked=function(K,O,V){var k=O.getAttribute("href");if(null==k||!e.isCustomLink(k)||!mxEvent.isTouchEvent(V)&&mxEvent.isPopupTrigger(V))z.apply(this,arguments);else{if(!e.isEnabled()||
0
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
vulnerable
null!=b.currentPage&&null!=b.pages&&(L=mxUtils.indexOf(b.pages,b.currentPage));for(J=f.length-1;0<=J;J--){var T=function(W){var X=new Date(W.modifiedDate),Y=null;if(0<=X.getTime()){var Z=function(ha){c.stop();E.innerText="";var na=mxUtils.parseXml(ha),ea=b.editor.extractGraphModel(na.documentElement,!0);if(null!=ea){var za=function(Ba){null!=Ba&&(Ba=Ca(Editor.parseDiagramNode(Ba)));return Ba},Ca=function(Ba){var ba=Ba.getAttribute("background");if(null==ba||""==ba||ba==mxConstants.NONE)ba=F.defaultPageBackgroundColor; v.style.backgroundColor=ba;(new mxCodec(Ba.ownerDocument)).decode(Ba,F.getModel());F.maxFitScale=1;F.fit(8);F.center();return Ba};O.style.display="none";O.innerText="";x=na;B=ha;N=parseSelectFunction=null;H=0;if("mxfile"==ea.nodeName){na=ea.getElementsByTagName("diagram");N=[];for(ha=0;ha<na.length;ha++)N.push(na[ha]);H=Math.min(L,N.length-1);0<N.length&&za(N[H]);if(1<N.length)for(O.removeAttribute("disabled"),O.style.display="",ha=0;ha<N.length;ha++)na=document.createElement("option"),ea=N[ha].getAttribute("name")||
0
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
vulnerable
y[G].url)}catch(Q){console.log("ExtFonts format error: "+Q.message)}else null!=this.graph.extFonts&&0<this.graph.extFonts.length&&(this.graph.extFonts=[])}b.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};};var f=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(k,y){k=null!=k?k:!0;var G=f.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&G.setAttribute("style", this.graph.currentStyle);var P=this.graph.getBackgroundImageObject(this.graph.backgroundImage,y);null!=P&&G.setAttribute("backgroundImage",JSON.stringify(P));G.setAttribute("math",this.graph.mathEnabled?"1":"0");G.setAttribute("shadow",this.graph.shadowVisible?"1":"0");null!=this.graph.extFonts&&0<this.graph.extFonts.length&&(P=this.graph.extFonts.map(function(Q){return Q.name+"^"+Q.url}),G.setAttribute("extFonts",P.join("|")));return G};Editor.prototype.isDataSvg=function(k){try{var y=mxUtils.parseXml(k).documentElement.getAttribute("content");
0
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
vulnerable
Ea.style.background=ua&&"none"!=ua?ua:"url('"+Dialog.prototype.noColorImage+"')";btn=mxUtils.button("",mxUtils.bind(Z,function(Da){this.editorUi.pickColor(ua,function(Ta){Ea.style.background="none"==Ta?"url('"+Dialog.prototype.noColorImage+"')":Ta;P(pa,Ta,va)});mxEvent.consume(Da)}));btn.style.height="12px";btn.style.width="40px";btn.className="geColorBtn";btn.appendChild(Ea);return btn}function T(pa,ua,va,Ea,Da,Ta,Ia){null!=ua&&(ua=ua.split(","),ha.push({name:pa,values:ua,type:va,defVal:Ea,countProperty:Da, parentRow:Ta,isDeletable:!0,flipBkg:Ia}));btn=mxUtils.button("+",mxUtils.bind(Z,function(Sa){for(var Ha=Ta,Va=0;null!=Ha.nextSibling;)if(Ha.nextSibling.getAttribute("data-pName")==pa)Ha=Ha.nextSibling,Va++;else break;var Ua={type:va,parentRow:Ta,index:Va,isDeletable:!0,defVal:Ea,countProperty:Da};Va=Y(pa,"",Ua,0==Va%2,Ia);P(pa,Ea,Ua);Ha.parentNode.insertBefore(Va,Ha.nextSibling);mxEvent.consume(Sa)}));btn.style.height="16px";btn.style.width="25px";btn.className="geColorBtn";return btn}function W(pa,
0
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
vulnerable
function(c){"simple"==c||"sketch"==c?null==this.sketchStyleElt&&(this.sketchStyleElt=document.createElement("style"),this.sketchStyleElt.setAttribute("type","text/css"),this.sketchStyleElt.innerHTML=Editor.createMinimalCss(),document.getElementsByTagName("head")[0].appendChild(this.sketchStyleElt)):null!=this.sketchStyleElt&&(this.sketchStyleElt.parentNode.removeChild(this.sketchStyleElt),this.sketchStyleElt=null)};EditorUi.prototype.createWrapperForTheme=function(c){"simple"==c||"sketch"==c?(null==
0
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
vulnerable
O.cell.id,O.text),K=!1);K||D++;M++});console.log("states checked",M,"invalid",D)}));d.actions.addAction("testCheckFile",mxUtils.bind(this,function(){var l=null!=d.pages&&null!=d.getCurrentFile()?d.getCurrentFile().getAnonymizedXmlForPages(d.pages):"";l=new TextareaDialog(d,"Paste Data:",l,function(n){if(0<n.length)try{var z=function(O){function V(Y){if(null==X[Y]){if(X[Y]=!0,null!=G[Y]){for(;0<G[Y].length;){var Z=G[Y].pop();V(Z)}delete G[Y]}}else mxLog.debug(k+": Visited: "+Y)}var k=O.parentNode.id, y=O.childNodes;O={};for(var G={},P=null,Q={},U=0;U<y.length;U++){var T=y[U];if(null!=T.id&&0<T.id.length)if(null==O[T.id]){O[T.id]=T.id;var W=T.getAttribute("parent");null==W?null!=P?mxLog.debug(k+": Multiple roots: "+T.id):P=T.id:(null==G[W]&&(G[W]=[]),G[W].push(T.id))}else Q[T.id]=T.id}y=Object.keys(Q);0<y.length?(y=k+": "+y.length+" Duplicates: "+y.join(", "),mxLog.debug(y+" (see console)")):mxLog.debug(k+": Checked");var X={};null==P?mxLog.debug(k+": No root"):(V(P),Object.keys(X).length!=Object.keys(O).length&& (mxLog.debug(k+": Invalid tree: (see console)"),console.log(k+": Invalid tree",G)))};"<"!=n.charAt(0)&&(n=Graph.decompress(n),mxLog.debug("See console for uncompressed XML"),console.log("xml",n));var C=mxUtils.parseXml(n),D=d.getPagesForNode(C.documentElement,"mxGraphModel");if(null!=D&&0<D.length)try{var M=d.getHashValueForPages(D);mxLog.debug("Checksum: ",M)}catch(O){mxLog.debug("Error: ",O.message)}else mxLog.debug("No pages found for checksum");var K=C.getElementsByTagName("root");for(n=0;n<K.length;n++)z(K[n]);
0
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
vulnerable
this.addListener("darkModeChanged",C);this.addListener("sketchModeChanged",C);this.addListener("currentThemeChanged",mxUtils.bind(this,function(){null!=this.sidebar&&this.sidebar.updateEntries();this.updateButtonContainer();this.updateDocumentTitle();this.refresh()}));e.addListener("enabledChanged",mxUtils.bind(this,function(){e.isEnabled()||this.hideShapePicker()}));c=this;mxWindow.prototype.fit=function(){if(Editor.inlineFullscreen||null==c.embedViewport)mxUtils.fit(this.div);else{var K=parseInt(this.div.offsetLeft), O=parseInt(this.div.offsetWidth),V=c.embedViewport.x+c.embedViewport.width,k=parseInt(this.div.offsetTop),y=parseInt(this.div.offsetHeight),G=c.embedViewport.y+c.embedViewport.height;this.div.style.left=Math.max(c.embedViewport.x,Math.min(K,V-O))+"px";this.div.style.top=Math.max(c.embedViewport.y,Math.min(k,G-y))+"px";this.div.style.height=Math.min(c.embedViewport.height,parseInt(this.div.style.height))+"px";this.div.style.width=Math.min(c.embedViewport.width,parseInt(this.div.style.width))+"px"}};
0
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
vulnerable
App.prototype.pickFolder=function(b,f,m,d,u){m=null!=m?m:!0;var v=this.spinner.pause();m&&b==App.MODE_GOOGLE&&null!=this.drive?this.drive.pickFolder(mxUtils.bind(this,function(E){v();if(E.action==google.picker.Action.PICKED){var F=null;null!=E.docs&&0<E.docs.length&&"folder"==E.docs[0].type&&(F=E.docs[0].id);f(F)}}),u):m&&b==App.MODE_ONEDRIVE&&null!=this.oneDrive?this.oneDrive.pickFolder(mxUtils.bind(this,function(E){v();null!=E&&null!=E.value&&0<E.value.length&&(E=OneDriveFile.prototype.getIdOf(E.value[0]), f(E))}),d):m&&b==App.MODE_GITHUB&&null!=this.gitHub?this.gitHub.pickFolder(mxUtils.bind(this,function(E){v();f(E)})):m&&b==App.MODE_GITLAB&&null!=this.gitLab?this.gitLab.pickFolder(mxUtils.bind(this,function(E){v();f(E)})):m&&b==App.MODE_TRELLO&&null!=this.trello?this.trello.pickFolder(mxUtils.bind(this,function(E){v();f(E)})):EditorUi.prototype.pickFolder.apply(this,arguments)};
0
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
vulnerable
"data:"+c+";base64,"+I);u.style.position="absolute";u.style.top="70px";u.style.right="100px";u.style.maxWidth="120px";u.style.maxHeight="80px";mxUtils.setPrefixedStyle(u.style,"transform","translate(50%,-50%)");v.appendChild(u);mxClient.IS_FF||"image/png"!=c||null==navigator.clipboard||"function"!==typeof window.ClipboardItem||(g=mxUtils.button(mxResources.get("copy"),function(n){n=b.base64ToBlob(I,"image/png");n=new ClipboardItem({"image/png":n,"text/html":new Blob(['<img src="data:'+c+";base64,"+ I+'">'],{type:"text/html"})});navigator.clipboard.write([n]).then(mxUtils.bind(this,function(){b.alert(mxResources.get("copiedToClipboard"))}))["catch"](mxUtils.bind(this,function(z){b.handleError(z)}))}),g.style.marginTop="6px",g.className="geBtn");L&&Editor.popupsAllowed&&(u.style.cursor="pointer",mxEvent.addGestureListeners(u,null,null,function(n){mxEvent.isPopupTrigger(n)||t("_blank")}))}mxUtils.br(v);var A=document.createElement("div");A.style.textAlign="center";var S=0;A.style.marginTop="6px";
0
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
vulnerable
(B=new mxCodec(mxUtils.createXmlDocument()),B=B.encode(new mxGraphModel(t.root)),this.editor.graph.saveViewState(t.viewState,B,null,q),x=x.cloneNode(!1),mxUtils.setTextContent(x,Graph.compressNode(B))));c(x)}return p};EditorUi.prototype.anonymizeString=function(c,e){for(var g=[],q=0;q<c.length;q++){var p=c.charAt(q);0<=EditorUi.ignoredAnonymizedChars.indexOf(p)?g.push(p):isNaN(parseInt(p))?p.toLowerCase()!=p?g.push(String.fromCharCode(65+Math.round(25*Math.random()))):p.toUpperCase()!=p?g.push(String.fromCharCode(97+ Math.round(25*Math.random()))):/\s/.test(p)?g.push(" "):g.push("?"):g.push(e?"0":Math.round(9*Math.random()))}return g.join("")};EditorUi.prototype.anonymizePatch=function(c){if(null!=c[EditorUi.DIFF_INSERT])for(var e=0;e<c[EditorUi.DIFF_INSERT].length;e++)try{var g=mxUtils.parseXml(c[EditorUi.DIFF_INSERT][e].data).documentElement.cloneNode(!1);null!=g.getAttribute("name")&&g.setAttribute("name",this.anonymizeString(g.getAttribute("name")));c[EditorUi.DIFF_INSERT][e].data=mxUtils.getXml(g)}catch(t){c[EditorUi.DIFF_INSERT][e].data=
0
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
vulnerable
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,g){this.openDatabase(mxUtils.bind(this,function(q){try{g=g||"objects";var p=q.transaction([g],"readonly").objectStore(g).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!=
0
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
vulnerable
t.getGlobalVariable=function(S){return"page"==S?A.getName():"pagenumber"==S?1:I.apply(this,arguments)};document.body.appendChild(t.container);t.model.setRoot(A.root)}this.editor.exportToCanvas(mxUtils.bind(this,function(S){try{null==B&&(B=this.getFileData(!0,null,null,null,null,null,null,null,null,!1));var l=S.toDataURL("image/png");l=Editor.writeGraphModelToPng(l,"tEXt","mxfile",encodeURIComponent(B));c(l.substring(l.lastIndexOf(",")+1));t!=this.editor.graph&&t.container.parentNode.removeChild(t.container)}catch(n){null!=
0
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
vulnerable
6)this.curveTo(ha[na],ha[na+1],ha[na+2],ha[na+3],ha[na+4],ha[na+5]);this.lastX=Z;this.lastY=ca}};k.prototype.rect=function(U,T,W,X){this.passThrough?this.originalRect.apply(this.canvas,arguments):(this.path=[],this.nextShape=this.rc.generator.rectangle(U,T,W,X,this.getStyle(!0,!0)))};k.prototype.ellipse=function(U,T,W,X){this.passThrough?this.originalEllipse.apply(this.canvas,arguments):(this.path=[],this.nextShape=this.rc.generator.ellipse(U+W/2,T+X/2,W,X,this.getStyle(!0,!0)))};k.prototype.roundrect=
0
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
vulnerable
C.translate(Math.floor((1-n.x)/z),Math.floor((1-n.y)/z));C.scale(1/z);var M=0,K=C.save;C.save=function(){M++;K.apply(this,arguments)};var O=C.restore;C.restore=function(){M--;O.apply(this,arguments)};var V=l.drawShape;l.drawShape=function(k){mxLog.debug("entering shape",k,M);V.apply(this,arguments);mxLog.debug("leaving shape",k,M)};l.drawState(u.getView().getState(u.model.root),C);mxLog.show();mxLog.debug(mxUtils.getXml(D));mxLog.debug("stateCounter",M)}));d.actions.addAction("testShowConsole",function(){mxLog.isVisible()?
0
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
vulnerable
EditorUi.lightboxHost+"/?client=1"+(null!=e?"&page="+e:"")+(p?"&edit=_blank":"")+(t?"&layers=1":"")+"');}}})(this);"),n+="cursor:pointer;"),c&&(c=parseInt(B.getAttribute("width")),p=parseInt(B.getAttribute("height")),B.setAttribute("viewBox","-0.5 -0.5 "+c+" "+p),n+="max-width:100%;max-height:"+p+"px;",B.removeAttribute("height")),""!=n&&B.setAttribute("style",n),this.editor.addFontCss(B),this.editor.graph.mathEnabled&&this.editor.addMathCss(B),x(mxUtils.getXml(B))};EditorUi.prototype.timeSince=function(c){c= Math.floor((new Date-c)/1E3);var e=Math.floor(c/31536E3);if(1<e)return e+" "+mxResources.get("years");e=Math.floor(c/2592E3);if(1<e)return e+" "+mxResources.get("months");e=Math.floor(c/86400);if(1<e)return e+" "+mxResources.get("days");e=Math.floor(c/3600);if(1<e)return e+" "+mxResources.get("hours");e=Math.floor(c/60);return 1<e?e+" "+mxResources.get("minutes"):1==e?e+" "+mxResources.get("minute"):null};EditorUi.prototype.decodeNodeIntoGraph=function(c,e){if(null!=c){var g=null;if("diagram"==c.nodeName)g=
0
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
vulnerable
Graph.recentCustomFonts[P]=Q,y=document.getElementsByTagName("head")[0],null!=G&&("link"==Q.elt.nodeName.toLowerCase()?(Q.elt.onload=G,Q.elt.onerror=G):G()),null!=y&&y.appendChild(Q.elt)):null!=G&&G()}else null!=G&&G()}else null!=G&&G();return k};Graph.getFontUrl=function(k,y){k=Graph.customFontElements[k.toLowerCase()];null!=k&&(y=k.url);return y};Graph.processFontAttributes=function(k){k=k.getElementsByTagName("*");for(var y=0;y<k.length;y++){var G=k[y].getAttribute("data-font-src");if(null!=G){var P=
0
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
vulnerable
Editor.isSettingsEnabled=function(){return"undefined"!==typeof window.mxSettings&&(isLocalStorage||mxClient.IS_CHROMEAPP)};Editor.configureFontCss=function(k){if(null!=k){Editor.prototype.fontCss=k;var y=document.getElementsByTagName("script")[0];if(null!=y&&null!=y.parentNode){var G=document.createElement("style");G.setAttribute("type","text/css");G.appendChild(document.createTextNode(k));y.parentNode.insertBefore(G,y);k=k.split("url(");for(G=1;G<k.length;G++){var P=k[G].indexOf(")");P=Editor.trimCssUrl(k[G].substring(0,
0
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
vulnerable
function(z){H=z};this.setAutoScroll=function(z){R=z};this.setOpenFill=function(z){J=z};this.setStopClickEnabled=function(z){g=z};this.setSelectInserted=function(z){q=z};this.setSmoothing=function(z){m=z};this.setPerfectFreehandMode=function(z){t=z};this.isPerfectFreehandMode=function(){return t};this.setBrushSize=function(z){p.size=z};this.getBrushSize=function(){return p.size};var x=function(z){e=z;b.getRubberband().setEnabled(!z);b.graphHandler.setSelectEnabled(!z);b.graphHandler.setMoveEnabled(!z); b.container.style.cursor=z?"crosshair":"";b.fireEvent(new mxEventObject("freehandStateChanged"))};this.startDrawing=function(){x(!0)};this.isDrawing=function(){return e};var B=mxUtils.bind(this,function(z){if(d){var C=F.length,D=g&&0<E.length&&null!=F&&2>F.length;D||E.push.apply(E,F);F=[];E.push(null);u.push(d);d=null;(D||H)&&this.stopDrawing();H&&(!D||2<=C)&&this.startDrawing();mxEvent.consume(z)}}),I=new mxCell;I.edge=!0;var A=function(){var z=b.getCurrentCellStyle(I);z=mxUtils.getValue(b.currentVertexStyle,
0
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
vulnerable
arguments);u()};u();var J=document.createElement("canvas");J.width=R.offsetWidth;J.height=R.offsetHeight;R.style.overflow="hidden";J.style.position="relative";R.appendChild(J);var c=J.getContext("2d");this.ui=b;var e=b.editor.graph;this.graph=e;this.container=R;this.canvas=J;var g=function(x,B,I,A,S){x=Math.round(x);B=Math.round(B);I=Math.round(I);A=Math.round(A);c.beginPath();c.moveTo(x+.5,B+.5);c.lineTo(I+.5,A+.5);c.stroke();S&&(m?(c.save(),c.translate(x,B),c.rotate(-Math.PI/2),c.fillText(S,0,0), c.restore()):c.fillText(S,x,B))},q=function(){c.clearRect(0,0,J.width,J.height);c.beginPath();c.lineWidth=.7;c.strokeStyle=H.strokeClr;c.setLineDash([]);c.font="9px Arial";c.textAlign="center";var x=e.view.scale,B=e.view.getBackgroundPageBounds(),I=e.view.translate,A=e.pageVisible;I=A?L+(m?B.y-e.container.scrollTop:B.x-e.container.scrollLeft):L+(m?I.y*x-e.container.scrollTop:I.x*x-e.container.scrollLeft);var S=0;A&&(S=e.getPageLayout(),S=m?S.y*e.pageFormat.height:S.x*e.pageFormat.width);var l;switch(N.unit){case mxConstants.POINTS:var n=
0
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
vulnerable
function(k,y){for(var G=0;G<y.length;G++){var P=y[G],Q;for(Q in P)this.updateCustomLinkAction(k,P[Q],"cells"),this.updateCustomLinkAction(k,P[Q],"excludeCells")}};Graph.prototype.updateCustomLinkAction=function(k,y,G){if(null!=y&&null!=y[G]){for(var P=[],Q=0;Q<y[G].length;Q++)if("*"==y[G][Q])P.push(y[G][Q]);else{var U=k[y[G][Q]];null!=U?""!=U&&P.push(U):P.push(y[G][Q])}y[G]=P}};Graph.prototype.getCellsForAction=function(k,y){y=this.getCellsById(k.cells).concat(this.getCellsForTags(k.tags,null,y));
0
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
vulnerable
StorageFile.listFiles=function(b,f,m,d){b.getDatabaseItems(function(u){var v=[];if(null!=u)for(var E=0;E<u.length;E++)"."==u[E].title.charAt(0)||null!=f&&u[E].type!=f||v.push(u[E]);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};
0
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
vulnerable
null,null,null,!0,null,null,p,g,q);this.showDialog(c.container,620,460,!0,!1);c.init()};EditorUi.prototype.showBackgroundImageDialog=function(c,e,g,q){c=null!=c?c:mxUtils.bind(this,function(p,t,x,B){t||(p=new ChangePageSetup(this,q?x:null,p),p.ignoreColor=!q,null!=B&&q&&(p.shadowVisible=B),this.editor.graph.model.execute(p))});c=new BackgroundImageDialog(this,c,e,g,q);this.showDialog(c.container,400,q?240:220,!0,!0);c.init()};EditorUi.prototype.showLibraryDialog=function(c,e,g,q,p){c=new LibraryDialog(this,
0
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
vulnerable
document.createElement("canvas");C.width=S;C.height=l;var D=C.toDataURL();z!==D&&(e=z,B=S,I=l)}}}catch(M){}g(e,B,I)};EditorUi.prototype.extractGraphModelFromPng=function(c){return Editor.extractGraphModelFromPng(c)};EditorUi.prototype.loadImage=function(c,e,g){try{var q=new Image;q.onload=function(){q.width=0<q.width?q.width:120;q.height=0<q.height?q.height:120;e(q)};null!=g&&(q.onerror=g);q.src=c}catch(p){if(null!=g)g(p);else throw p;}};EditorUi.prototype.getDefaultSketchMode=function(){var c="1"== urlParams.sketch;return"0"!=(null!=urlParams.rough?urlParams.rough:c)};var u=EditorUi.prototype.createUi;EditorUi.prototype.createUi=function(){Editor.isSettingsEnabled()&&(this.doSetSketchMode(null!=mxSettings.settings.sketchMode&&null==urlParams.rough&&null==urlParams.sketch?mxSettings.settings.sketchMode:this.getDefaultSketchMode()),null!=mxSettings.settings.sidebarTitles&&(Sidebar.prototype.sidebarTitles=mxSettings.settings.sidebarTitles),this.formatWidth=mxSettings.getFormatWidth());u.apply(this,
0
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
vulnerable
function(){b.spinner.stop();if(null==b.linkPicker){var x=b.drive.createLinkPicker();b.linkPicker=x.setCallback(function(B){LinkDialog.filePicked(B)}).build()}b.linkPicker.setVisible(!0)}))});"undefined"!=typeof Dropbox&&"undefined"!=typeof Dropbox.choose&&F(IMAGE_PATH+"/dropbox-logo.svg",mxResources.get("dropbox"),function(){Dropbox.choose({linkType:"direct",cancel:function(){},success:function(x){H.value=x[0].link;H.focus()}})});null!=b.oneDrive&&F(IMAGE_PATH+"/onedrive-logo.svg",mxResources.get("oneDrive"),
0
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
vulnerable
arguments)};var v=EditorUi.prototype.init;EditorUi.prototype.init=function(){mxStencilRegistry.allowEval=mxStencilRegistry.allowEval&&!this.isOfflineApp();var c=this,e=this.editor.graph;Graph.touchStyle&&(e.panningHandler.isPanningTrigger=function(K){var O=K.getEvent();return null==K.getState()&&!mxEvent.isMouseEvent(O)&&!e.freehand.isDrawing()||mxEvent.isPopupTrigger(O)&&(null==K.getState()||mxEvent.isControlDown(O)||mxEvent.isShiftDown(O))});e.cellEditor.editPlantUmlData=function(K,O,V){var k=JSON.parse(V);
0
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
vulnerable
G,[K]);var U=e.model.getGeometry(K);null!=U&&(U=U.clone(),U.width=Math.max(U.width,P),U.height=Math.max(U.height,Q),e.cellsResized([K],[U],!1));e.setAttributeForCell(K,"mermaidData",JSON.stringify({data:y,config:k.config},null,2))}finally{e.getModel().endUpdate()}},function(G){c.handleError(G)})},null,null,400,220);c.showDialog(O.container,420,300,!0,!0);O.init()};var g=e.cellEditor.startEditing;e.cellEditor.startEditing=function(K,O){try{var V=this.graph.getAttributeForCell(K,"plantUmlData");if(null!= V)this.editPlantUmlData(K,O,V);else if(V=this.graph.getAttributeForCell(K,"mermaidData"),null!=V)this.editMermaidData(K,O,V);else{var k=e.getCellStyle(K);"1"==mxUtils.getValue(k,"metaEdit","0")?c.showDataDialog(K):g.apply(this,arguments)}}catch(y){c.handleError(y)}};e.getLinkTitle=function(K){return c.getLinkTitle(K)};e.customLinkClicked=function(K){var O=!1;try{c.handleCustomLink(K),O=!0}catch(V){c.handleError(V)}return O};var q=e.parseBackgroundImage;e.parseBackgroundImage=function(K){var O=q.apply(this,
0
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
vulnerable
m.viewState.scale=1;delete m.viewState.scrollLeft;delete m.viewState.scrollTop;delete m.viewState.currentRoot;delete m.viewState.defaultParent;m.setName(f);m=this.insertPage(m,mxUtils.indexOf(this.pages,b)+1)}}catch(L){this.handleError(L)}return m};EditorUi.prototype.initDiagramNode=function(b){var f=(new mxCodec(mxUtils.createXmlDocument())).encode(new mxGraphModel(b.root));this.editor.graph.saveViewState(b.viewState,f);mxUtils.setTextContent(b.node,Graph.compressNode(f))};
0
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
vulnerable
function(c,e,g,q,p,t,x,B){EditorUi.logEvent("SHOULD NOT BE CALLED: loadUrl");return this.editor.loadUrl(c,e,g,q,p,t,x,B)};EditorUi.prototype.loadFonts=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: loadFonts");return this.editor.loadFonts(c)};EditorUi.prototype.createSvgDataUri=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: createSvgDataUri");return Editor.createSvgDataUri(c)};EditorUi.prototype.embedCssFonts=function(c,e){EditorUi.logEvent("SHOULD NOT BE CALLED: embedCssFonts");return this.editor.embedCssFonts(c,
0
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
vulnerable
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))};this.isCellLocked=function(K){for(;null!=K;){if("1"==mxUtils.getValue(this.getCurrentCellStyle(K),
0
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
vulnerable
function(){var c=document.createElement("div");c.className="geButtonContainer";c.style.overflow="1"==urlParams.embed?"hidden":"";return c};EditorUi.prototype.openLink=function(c,e,g){return this.editor.graph.openLink(c,e,g)};EditorUi.prototype.showSplash=function(c){};EditorUi.prototype.getLocalData=function(c,e){e(localStorage.getItem(c))};EditorUi.prototype.setLocalData=function(c,e,g){localStorage.setItem(c,e);null!=g&&g()};EditorUi.prototype.removeLocalData=function(c,e){localStorage.removeItem(c); e()};EditorUi.prototype.setShareCursorPosition=function(c){this.shareCursorPosition=c;this.fireEvent(new mxEventObject("shareCursorPositionChanged"))};EditorUi.prototype.isShareCursorPosition=function(){return this.shareCursorPosition};EditorUi.prototype.setShowRemoteCursors=function(c){this.showRemoteCursors=c;this.fireEvent(new mxEventObject("showRemoteCursorsChanged"))};EditorUi.prototype.isShowRemoteCursors=function(){return this.showRemoteCursors};EditorUi.prototype.setMathEnabled=function(c){this.editor.graph.mathEnabled=
0
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
vulnerable
Fa.substring(Fa.indexOf(",")+1);Pa.style.cursor="pointer";Pa.style.width="100%";Pa.style.height="100%";ma.appendChild(Pa);ra=b.createMermaidXml("%% Input: "+Ma+"\n"+ra,EditorUi.defaultMermaidConfig,Fa,Ka,Xa);var Ra="<mxfile><diagram>"+Graph.compress(ra)+"</diagram></mxfile>";if(Ga||"undefined"===typeof mxMermaidToDrawio)ba=na=ra;ra=k.cloneNode(!0);ma.appendChild(ra);Fa=function(Oa){P=null!=b.sidebar.tooltip&&"none"!=b.sidebar.tooltip.style.display};Ka=function(Oa){P||x(Ra,mxEvent.getClientX(Oa),mxEvent.getClientY(Oa), Pa,Ma)};mxEvent.addGestureListeners(Pa,Fa,null,Ka);mxEvent.addGestureListeners(ra,Fa,null,Ka)},function(ra){b.handleError(ra)})});La.setAttribute("disabled","disabled");La.className="geBtn gePrimaryBtn";oa=function(){window.setTimeout(function(){""!=la.value?La.removeAttribute("disabled"):La.setAttribute("disabled","disabled")},0)};ja=urlParams["smart-template"];null!=ja&&"1"!=ja&&(la.value=decodeURIComponent(ja),oa(),"1"==urlParams["smart-template-generate"]&&window.setTimeout(function(){La.click()},
0
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
vulnerable
"#ffffff");this.convertImages(ca.getSvg(null,null,ha,na,null,T,null,null,null,Y,null,za,Ca,Ba),mxUtils.bind(this,function(da){try{var qa=new Image;qa.onload=mxUtils.bind(this,function(){try{var Aa=function(){mxClient.IS_SF?window.setTimeout(function(){pa.drawImage(qa,0,0);k(xa,da)},0):(pa.drawImage(qa,0,0),k(xa,da))},xa=document.createElement("canvas"),wa=parseInt(da.getAttribute("width")),Qa=parseInt(da.getAttribute("height"));W=null!=W?W:1;null!=y&&(W=U?Math.min(1,Math.min(3*y/(4*Qa),y/wa)):y/wa);
0
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
vulnerable
this.cellEditor.textarea.getElementsByTagName("font");y=Graph.getFontUrl(k,y);for(var P=0;P<G.length;P++)G[P].getAttribute("face")==k&&G[P].getAttribute("data-font-src")!=y&&G[P].setAttribute("data-font-src",y)}};var t=Graph.prototype.isFastZoomEnabled;Graph.prototype.isFastZoomEnabled=function(){return t.apply(this,arguments)&&(!this.shadowVisible||!mxClient.IS_SF)};Graph.prototype.updateGlobalUrlVariables=function(){this.globalVars=Editor.globalVars;if(null!=urlParams.vars)try{this.globalVars=null!=
0
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
vulnerable
c.shortcut):E.apply(this,arguments)};EditorUi.prototype.toggleFormatPanel=function(J){null!=this.formatWindow?this.formatWindow.window.setVisible(null!=J?J:!this.formatWindow.window.isVisible()):b(this)};EditorUi.prototype.isFormatPanelVisible=function(){return null!=this.formatWindow&&this.formatWindow.window.isVisible()||null==this.formatWindow&&0<this.formatWidth};DiagramFormatPanel.prototype.isMathOptionVisible=function(){return!0};var F=EditorUi.prototype.destroy;EditorUi.prototype.destroy=function(){this.destroyWindows();
0
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
vulnerable
function(){try{null!=this.resolvedFontCss&&this.addFontCss(da,this.resolvedFontCss),qa.src=Editor.createSvgDataUri(mxUtils.getXml(da))}catch(Aa){null!=Q&&Q(Aa)}});this.embedExtFonts(mxUtils.bind(this,function(Aa){try{null!=Aa&&this.addFontCss(da,Aa),this.loadFonts(ka)}catch(xa){null!=Q&&Q(xa)}}))}catch(Aa){null!=Q&&Q(Aa)}}),G,Z)}catch(da){null!=Q&&Q(da)}};Editor.crcTable=[];for(var u=0;256>u;u++)for(var v=u,E=0;8>E;E++)v=1==(v&1)?3988292384^v>>>1:v>>>1,Editor.crcTable[u]=v;Editor.updateCRC=function(k, y,G,P){for(var Q=0;Q<P;Q++)k=Editor.crcTable[(k^y.charCodeAt(G+Q))&255]^k>>>8;return k};Editor.crc32=function(k){for(var y=-1,G=0;G<k.length;G++)y=y>>>8^Editor.crcTable[(y^k.charCodeAt(G))&255];return(y^-1)>>>0};Editor.writeGraphModelToPng=function(k,y,G,P,Q){function U(Z,ca){var ha=X;X+=ca;return Z.substring(ha,X)}function T(Z){Z=U(Z,4);return Z.charCodeAt(3)+(Z.charCodeAt(2)<<8)+(Z.charCodeAt(1)<<16)+(Z.charCodeAt(0)<<24)}function W(Z){return String.fromCharCode(Z>>24&255,Z>>16&255,Z>>8&255,Z&255)}
0
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
vulnerable
0;V<D.length;V++){var k=e.view.getState(e.model.getTerminal(D[V],!1));null!=k&&(!M&&Math.min(k.x+k.width,K.x+K.width)>=Math.max(k.x,K.x)||M&&Math.min(k.y+k.height,K.y+K.height)>=Math.max(k.y,K.y))&&O.push(k)}O.sort(function(y,G){return M?y.x+y.width-G.x-G.width:y.y+y.height-G.y-G.height})}return O}function J(D,M){var K=F(D),O=M==mxConstants.DIRECTION_EAST||M==mxConstants.DIRECTION_WEST;(K==mxConstants.DIRECTION_EAST||K==mxConstants.DIRECTION_WEST)==O&&K!=M?c.actions.get("selectParent").funct():K== M?(M=e.getOutgoingTreeEdges(D),null!=M&&0<M.length&&e.setSelectionCell(e.model.getTerminal(M[0],!1))):(K=e.getIncomingTreeEdges(D),null!=K&&0<K.length&&(O=R(e.model.getTerminal(K[0],!0),O,D),D=e.view.getState(D),null!=D&&(D=mxUtils.indexOf(O,D),0<=D&&(D+=M==mxConstants.DIRECTION_NORTH||M==mxConstants.DIRECTION_WEST?-1:1,0<=D&&D<=O.length-1&&e.setSelectionCell(O[D].cell)))))}var c=this,e=c.editor.graph,g=e.getModel(),q=c.menus.createPopupMenu;c.menus.createPopupMenu=function(D,M,K){q.apply(this,arguments);
0
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
vulnerable
""),Da.value=ua,Da.style.width="96px",Da.style.borderWidth="0px",Ha.appendChild(Da)):(Ha.innerHTML=mxUtils.htmlEntities(decodeURIComponent(ua)),mxEvent.addListener(Ha,"click",mxUtils.bind(Z,function(){function Ua(){var aa=ia.value;aa=0==aa.length&&"string"!=Ia?0:aa;va.allowAuto&&(null!=aa.trim&&"auto"==aa.trim().toLowerCase()?(aa="auto",Ia="string"):(aa=parseFloat(aa),aa=isNaN(aa)?0:aa));null!=va.min&&aa<va.min?aa=va.min:null!=va.max&&aa>va.max&&(aa=va.max);aa=encodeURIComponent(("int"==Ia?parseInt(aa): aa)+"");P(pa,aa,va)}var ia=document.createElement("input");Q(Ha,ia,!0);ia.value=decodeURIComponent(ua);ia.className="gePropEditor";"int"!=Ia&&"float"!=Ia||va.allowAuto||(ia.type="number",ia.step="int"==Ia?"1":"any",null!=va.min&&(ia.min=parseFloat(va.min)),null!=va.max&&(ia.max=parseFloat(va.max)));k.appendChild(ia);mxEvent.addListener(ia,"keypress",function(aa){13==aa.keyCode&&Ua()});ia.focus();mxEvent.addListener(ia,"blur",function(){Ua()})})));va.isDeletable&&(Da=mxUtils.button("-",mxUtils.bind(Z,
0
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
vulnerable
0<Object.getOwnPropertyNames(y).length&&this.container.appendChild(this.addProperties(this.createPanel(),y,k))}};var c=StyleFormatPanel.prototype.addStyleOps;StyleFormatPanel.prototype.addStyleOps=function(k){var y=this.editorUi.getSelectionState();1==y.cells.length?this.addActions(k,["copyStyle","pasteStyle"]):1<=y.cells.length&&this.addActions(k,["pasteStyle","pasteData"]);return c.apply(this,arguments)};EditorUi.prototype.propertiesCollapsed=!0;StyleFormatPanel.prototype.addProperties=function(k,
0
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
vulnerable
Math.floor((new Date-c)/1E3);var e=Math.floor(c/31536E3);if(1<e)return e+" "+mxResources.get("years");e=Math.floor(c/2592E3);if(1<e)return e+" "+mxResources.get("months");e=Math.floor(c/86400);if(1<e)return e+" "+mxResources.get("days");e=Math.floor(c/3600);if(1<e)return e+" "+mxResources.get("hours");e=Math.floor(c/60);return 1<e?e+" "+mxResources.get("minutes"):1==e?e+" "+mxResources.get("minute"):null};EditorUi.prototype.decodeNodeIntoGraph=function(c,e){if(null!=c){var g=null;if("diagram"==c.nodeName)g= c;else if("mxfile"==c.nodeName){var q=c.getElementsByTagName("diagram");if(0<q.length){g=q[0];var p=e.getGlobalVariable;e.getGlobalVariable=function(t){return"page"==t?g.getAttribute("name")||mxResources.get("pageWithNumber",[1]):"pagenumber"==t?1:p.apply(this,arguments)}}}null!=g&&(c=Editor.parseDiagramNode(g))}q=this.editor.graph;try{this.editor.graph=e,this.editor.setGraphXml(c)}catch(t){}finally{this.editor.graph=q}return c};EditorUi.prototype.getSvgFileProperties=function(c){return this.getPngFileProperties(c)};
0
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
vulnerable
this.sidebarWindow.window.addListener(mxEvent.SHOW,mxUtils.bind(this,function(){this.sidebarWindow.window.fit()}));this.sidebarWindow.window.minimumSize=new mxRectangle(0,0,90,90);this.sidebarWindow.window.setVisible(!1)}};EditorUi.prototype.setSketchMode=function(c){this.spinner.spin(document.body,mxResources.get("working")+"...")&&window.setTimeout(mxUtils.bind(this,function(){this.spinner.stop();this.doSetSketchMode(c);null==urlParams.rough&&(mxSettings.settings.sketchMode=c,mxSettings.save()); this.fireEvent(new mxEventObject("sketchModeChanged"))}),0)};Editor.createMinimalCss=function(){return(Editor.isDarkMode()?"html body .geMenubarContainer .geMenuItem .geMenuItem, html body .geMenubarContainer a.geMenuItem { color: #353535; }html body .geToolbarContainer .geMenuItem, html body .geToolbarContainer .geToolbarButton, html body .geMenubarContainer .geMenuItem .geMenuItem, html body .geMenubarContainer a.geMenuItem,html body .geMenubarContainer .geToolbarButton { filter: invert(1); }html > body.geEditor > div > a.geItem { background-color: "+
0
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
vulnerable
gridSize:parseFloat(b.getAttribute("gridSize"))||mxGraph.prototype.gridSize,guidesEnabled:"0"!=b.getAttribute("guides"),foldingEnabled:"0"!=b.getAttribute("fold"),shadowVisible:"1"==b.getAttribute("shadow"),pageVisible:this.isLightboxView()?!1:null!=f?"0"!=f:this.defaultPageVisible,background:null!=v&&0<v.length?v:null,backgroundImage:E,pageScale:isNaN(m)?mxGraph.prototype.pageScale:m,pageFormat:isNaN(d)||isNaN(u)?"undefined"===typeof mxSettings||null!=this.defaultPageFormat?mxGraph.prototype.pageFormat: mxSettings.getPageFormat():new mxRectangle(0,0,d,u),tooltips:"0"!=b.getAttribute("tooltips"),connect:"0"!=b.getAttribute("connect"),arrows:"0"!=b.getAttribute("arrows"),mathEnabled:"1"==b.getAttribute("math"),selectionCells:null,defaultParent:null,scrollbars:this.defaultScrollbars,scale:1,hiddenTags:[],extFonts:F||[]}};
0
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
vulnerable
k.baseUrl||G.crossOriginImages&&G.isCorsEnabledForUrl(P)?"chrome-extension://"==P.substring(0,19)||mxClient.IS_CHROMEAPP||(P=y.apply(this,arguments)):P=PROXY_URL+"?url="+encodeURIComponent(P)}return P};return k};Editor.createSvgDataUri=function(k){return"data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(k)))};Editor.prototype.convertImageToDataUri=function(k,y){try{var G=!0,P=window.setTimeout(mxUtils.bind(this,function(){G=!1;y(Editor.svgBrokenImage.src)}),this.timeout);if(/(\.svg)$/i.test(k))mxUtils.get(k, mxUtils.bind(this,function(U){window.clearTimeout(P);G&&y(Editor.createSvgDataUri(U.getText()))}),function(){window.clearTimeout(P);G&&y(Editor.svgBrokenImage.src)});else{var Q=new Image;this.crossOriginImages&&(Q.crossOrigin="anonymous");Q.onload=function(){window.clearTimeout(P);if(G)try{var U=document.createElement("canvas"),T=U.getContext("2d");U.height=Q.height;U.width=Q.width;T.drawImage(Q,0,0);y(U.toDataURL())}catch(W){y(Editor.svgBrokenImage.src)}};Q.onerror=function(){window.clearTimeout(P); G&&y(Editor.svgBrokenImage.src)};Q.src=k}}catch(U){y(Editor.svgBrokenImage.src)}};Editor.prototype.convertImages=function(k,y,G,P){null==P&&(P=this.createImageUrlConverter());var Q=0,U=G||{};G=mxUtils.bind(this,function(T,W){T=k.getElementsByTagName(T);for(var X=0;X<T.length;X++)mxUtils.bind(this,function(Y){try{if(null!=Y){var Z=P.convert(Y.getAttribute(W));if(null!=Z&&"data:"!=Z.substring(0,5)){var ca=U[Z];null==ca?(Q++,this.convertImageToDataUri(Z,function(ha){null!=ha&&(U[Z]=ha,Y.setAttribute(W,
0
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
vulnerable
mxUtils.bind(this,function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,!1,x,null,1<B,I,q,t,p);B=this.isServices(B)?4<B?390:280:160;this.showDialog(c.container,420,B,!0,!0);c.init()};EditorUi.prototype.isServices=function(c){return 1!=c};EditorUi.prototype.getEditBlankXml=function(){return this.getFileData(!0)};EditorUi.prototype.exportFile=function(c,e,g,q,p,t){};EditorUi.prototype.pickFolder=function(c,e,g){e(null)};EditorUi.prototype.exportSvg=function(c,e,g,q,
0
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
vulnerable
mxResources.get("ok"),la,ia,function(sa){var ta=null!=sa&&0<sa.length;return ta&&e?(la(sa),!1):ta},null,null,null,fa,c?null:[]),b.showDialog(ia.container,350,80,!0,!0),ia.init())}}function I(ia){ka.innerText=mxResources.get(ha||ia?"create":"copy");ia=ia?"none":"";R&&(Aa.style.display=ia);for(var aa=O.querySelectorAll(".geTempDlgLinkToDiagram"),la=0;la<aa.length;la++)aa[la].style.display=ia}function A(ia,aa,la,ma,oa){oa||(ea.innerText="",x(),X=ia,Y=ma);var fa=null;if(la){fa=document.createElement("table");
0
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
vulnerable
V)this.editPlantUmlData(K,O,V);else if(V=this.graph.getAttributeForCell(K,"mermaidData"),null!=V)this.editMermaidData(K,O,V);else{var k=e.getCellStyle(K);"1"==mxUtils.getValue(k,"metaEdit","0")?c.showDataDialog(K):g.apply(this,arguments)}}catch(y){c.handleError(y)}};e.getLinkTitle=function(K){return c.getLinkTitle(K)};e.customLinkClicked=function(K){var O=!1;try{c.handleCustomLink(K),O=!0}catch(V){c.handleError(V)}return O};var q=e.parseBackgroundImage;e.parseBackgroundImage=function(K){var O=q.apply(this,
0
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
vulnerable
EditorUi.prototype.createMenu=function(c,e,g,q){g=null!=g?g:"geToolbarButton";var p=this.menus.get(c);q=this.menubar.addMenu(mxResources.get(c),p.funct,null,q);q.className=g;q.style.display="inline-block";q.style.cursor="pointer";q.style.height="24px";q.setAttribute("title",mxResources.get(c));this.menus.menuCreated(p,q,g);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,g,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";p.style.backgroundSize="100% 100%";p.style.display="inline-block";p.style.cursor="pointer";p.style.marginLeft="6px";p.style.width=q+"px";p.style.height=q+"px";null!=g&&(mxEvent.addListener(p,
0
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
vulnerable
EditorUi.prototype.patchPages=function(b,f,m,d,u){var v={},E=[],F={},L={},N={},H={};if(null!=d&&null!=d[EditorUi.DIFF_UPDATE])for(var R in d[EditorUi.DIFF_UPDATE])v[R]=d[EditorUi.DIFF_UPDATE][R];if(null!=f[EditorUi.DIFF_REMOVE])for(d=0;d<f[EditorUi.DIFF_REMOVE].length;d++)L[f[EditorUi.DIFF_REMOVE][d]]=!0;if(null!=f[EditorUi.DIFF_INSERT])for(d=0;d<f[EditorUi.DIFF_INSERT].length;d++)F[f[EditorUi.DIFF_INSERT][d].previous]=f[EditorUi.DIFF_INSERT][d];if(null!=f[EditorUi.DIFF_UPDATE])for(R in f[EditorUi.DIFF_UPDATE])d= f[EditorUi.DIFF_UPDATE][R],null!=d.previous&&(H[d.previous]=R);if(null!=b){var J="";for(d=0;d<b.length;d++){var c=b[d].getId();N[c]=b[d];null!=H[J]||L[c]||null!=f[EditorUi.DIFF_UPDATE]&&null!=f[EditorUi.DIFF_UPDATE][c]&&null!=f[EditorUi.DIFF_UPDATE][c].previous||(H[J]=c);J=c}}var e={},g=mxUtils.bind(this,function(p){var t=null!=p?p.getId():"";if(null!=p&&!e[t]){e[t]=!0;E.push(p);var x=null!=f[EditorUi.DIFF_UPDATE]?f[EditorUi.DIFF_UPDATE][t]:null;null!=x&&(this.updatePageRoot(p),null!=x.name&&p.setName(x.name), null!=x.view&&this.patchViewState(p,x.view),null!=x.cells&&this.patchPage(p,x.cells,v[p.getId()],u),!m||null==x.cells&&null==x.view||(p.needsUpdate=!0))}p=H[t];null!=p&&(delete H[t],g(N[p]));p=F[t];null!=p&&(delete F[t],q(p))}),q=mxUtils.bind(this,function(p){p=mxUtils.parseXml(p.data).documentElement;p=new DiagramPage(p);this.updatePageRoot(p);var t=N[p.getId()];null==t?g(p):(this.patchPage(t,this.diffPages([t],[p]),v[t.getId()],u),m&&(t.needsUpdate=!0))});g();for(R in H)g(N[H[R]]),delete H[R];for(R in F)q(F[R]), delete F[R];return E};EditorUi.prototype.patchViewState=function(b,f){if(null!=b.viewState&&null!=f){b==this.currentPage&&(b.viewState=this.editor.graph.getViewState());for(var m in f)try{this.patchViewStateProperty(b,f,m)}catch(d){}b==this.currentPage&&this.editor.graph.setViewState(b.viewState,!0)}};EditorUi.prototype.patchViewStateProperty=function(b,f,m){b.viewState[m]=JSON.parse(f[m])};
0
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
vulnerable
EditorUi.prototype.addTabListeners=function(b,f){mxEvent.disableContextMenu(f);var m=this.editor.graph;mxEvent.addListener(f,"dblclick",mxUtils.bind(this,function(L){this.renamePage(b);mxEvent.consume(L)}));var d=document.createElement("div");d.className="geTabMenuButton";d.style.backgroundImage="url("+mxWindow.prototype.minimizeImage+")";d.style.backgroundPosition="center center";d.style.backgroundRepeat="no-repeat";d.style.backgroundSize="10px";f.appendChild(d);var u=!1,v=!1,E=mxUtils.bind(this, function(L){u=null!=this.currentMenu;v=b==this.currentPage;m.isMouseDown||v||this.selectPage(b);this.scrollToPage()}),F=mxUtils.bind(this,function(L){if(m.isEnabled()&&!m.isMouseDown&&(v&&(mxEvent.isTouchEvent(L)||mxEvent.getSource(L)==d)||mxEvent.isPopupTrigger(L))&&(m.popupMenuHandler.hideMenu(),this.hideCurrentMenu(),!mxEvent.isTouchEvent(L)||!u)){var N=new mxPopupMenu(this.createPageMenu(b));N.div.className+=" geMenubarMenu";N.smartSeparators=!0;N.showDisabled=!0;N.autoExpand=!0;N.hideMenu=mxUtils.bind(this, function(){mxPopupMenu.prototype.hideMenu.apply(N,arguments);this.resetCurrentMenu();N.destroy()});var H=mxEvent.getClientX(L),R=mxEvent.getClientY(L);N.popup(H,R,null,L);this.setCurrentMenu(N,f)}mxEvent.consume(L)});mxEvent.addGestureListeners(d,E,null,F);mxEvent.addGestureListeners(f,E,null,F)};
0
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
vulnerable
function(){null!=t&&(t(),t=null);b.showImageDialog(mxResources.get("addImageUrl"),"",function(S,l,n){B=!1;if(null!=S){if("data:image/"==S.substring(0,11)){var z=S.indexOf(",");0<z&&(S=S.substring(0,z)+";base64,"+S.substring(z+1))}F(S,null,0,0,l,n);c.scrollTop=c.scrollHeight}})});f.setAttribute("id","btnAddImageUrl");f.className="geBtn";d.appendChild(f);this.saveBtnClickHandler=function(S,l,n,z){b.saveLibrary(S,l,n,z)};f=mxUtils.button(mxResources.get("save"),mxUtils.bind(this,function(){null!=t&&
0
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
vulnerable
p=-1,t=function(){null!=E?(null!=F&&F(p),p=E(q)):q()};this.drawRuler=t;this.sizeListener=f=v(function(){var x=e.container;m?(x=x.offsetHeight+L,J.height!=x&&(J.height=x,R.style.height=x+"px",t())):(x=x.offsetWidth+L,J.width!=x&&(J.width=x,R.style.width=x+"px",t()))},10);this.pageListener=function(){t()};this.scrollListener=d=v(function(){var x=m?e.container.scrollTop:e.container.scrollLeft;N.lastScroll!=x&&(N.lastScroll=x,t())},10);this.unitListener=function(x,B){N.setUnit(B.getProperty("unit"))};
0
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
vulnerable
EditorUi.prototype.repositionLibrary=function(c){var e=this.sidebar.getEntryContainer();if(null==c){var g=this.sidebar.palettes["L.scratchpad"];null==g&&(g=this.sidebar.palettes.search);null!=g&&(c=g[g.length-1].nextSibling)}c=null!=c?c:e.firstChild.nextSibling.nextSibling;g=e.lastChild;var q=g.previousSibling;e.insertBefore(g,c);e.insertBefore(q,g)};EditorUi.prototype.loadLibrary=function(c,e){var g=mxUtils.parseXml(c.getData());if("mxlibrary"==g.documentElement.nodeName){var q=JSON.parse(mxUtils.getTextContent(g.documentElement));
0
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
vulnerable
EditorUi.prototype.updateTabContainer=function(){if(null!=this.tabContainer&&null!=this.pages){var b=this.editor.graph,f=document.createElement("div");f.className="geTabScroller";for(var m=null,d=0;d<this.pages.length;d++)mxUtils.bind(this,function(u,v){v.className=this.pages[u]==this.currentPage?"geTab gePageTab geActivePage":"geTab gePageTab geInactivePage";v.setAttribute("draggable","true");mxEvent.addListener(v,"dragstart",mxUtils.bind(this,function(E){b.isEnabled()?(mxClient.IS_FF&&E.dataTransfer.setData("Text", "<diagram/>"),m=u):mxEvent.consume(E)}));mxEvent.addListener(v,"dragend",mxUtils.bind(this,function(E){m=null;E.stopPropagation();E.preventDefault()}));mxEvent.addListener(v,"dragover",mxUtils.bind(this,function(E){null!=m&&(E.dataTransfer.dropEffect="move");E.stopPropagation();E.preventDefault()}));mxEvent.addListener(v,"drop",mxUtils.bind(this,function(E){null!=m&&u!=m&&this.movePage(m,u);E.stopPropagation();E.preventDefault()}));f.appendChild(v)})(d,this.createTabForPage(this.pages[d],d+1));d= null!=this.tabScroller?this.tabScroller.scrollLeft:0;this.tabContainer.innerText="";"simple"!=Editor.currentTheme&&(this.pageMenuTab=this.createPageMenuTab(),this.tabContainer.appendChild(this.pageMenuTab));this.tabContainer.appendChild(f);this.isPageInsertTabVisible()&&this.tabContainer.appendChild(this.createPageInsertTab());this.leftScrollTab=this.createLeftScrollTab();this.tabContainer.appendChild(this.leftScrollTab);this.rightScrollTab=this.createRightScrollTab();this.tabContainer.appendChild(this.rightScrollTab); this.tabScroller=f;this.tabScroller.scrollLeft=d;this.checkTabScrollerOverflow();mxEvent.addListener(this.tabScroller,"scroll",mxUtils.bind(this,function(u){this.checkTabScrollerOverflow()}));window.setTimeout(mxUtils.bind(this,function(){mxUtils.setPrefixedStyle(this.leftScrollTab.style,"transition","all 0.2s linear");mxUtils.setPrefixedStyle(this.rightScrollTab.style,"transition","all 0.2s linear")}),0)}};
0
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
vulnerable
D.readAsText(C)}else this.doImportVisio(C,e,B,q)}catch(M){B(M)}else try{""==z.responseType||"text"==z.responseType?B({message:z.responseText}):(D=new FileReader,D.onload=function(){try{B({message:JSON.parse(D.result).Message})}catch(M){B(M)}},D.readAsText(z.response))}catch(M){B({})}});z.send(A)}else if(x.clear())try{this.doImportVisio(c,e,B,q)}catch(C){B(C)}}else B({message:mxResources.get("serviceUnavailableOrBlocked")})});this.doImportVisio||this.loadingExtensions||this.isOffline(!0)?I():(this.loadingExtensions=
0
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
vulnerable
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 g};EditorUi.prototype.getCopyFilename=function(c,e){var g=null!=c&&null!=c.getTitle()?c.getTitle():this.defaultFilename;c="";var q=g.lastIndexOf(".");0<=q&&(c=g.substring(q),g=g.substring(0,q));if(e){e=g;var p=new Date;g=p.getFullYear();q=p.getMonth()+1;var t=p.getDate(),x=p.getHours(),B=p.getMinutes();p=p.getSeconds(); g=e+(" "+(g+"-"+q+"-"+t+"-"+x+"-"+B+"-"+p))}return g=mxResources.get("copyOf",[g])+c};EditorUi.prototype.fileLoaded=function(c,e,g){var q=this.getCurrentFile();this.fileEditable=this.fileLoadedError=null;this.setCurrentFile(null);var p=!1;this.hideDialog();null!=q&&(EditorUi.debug("File.closed",[q]),q.removeListener(this.descriptorChangedListener),q.close());this.editor.graph.model.clear();this.editor.undoManager.clear();var t=mxUtils.bind(this,function(){this.setGraphEnabled(!1);this.setCurrentFile(null);
0
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
vulnerable
return null!=this.corsRegExp&&this.corsRegExp.test(k)||"https://raw.githubusercontent.com/"===k.substring(0,34)||"https://fonts.googleapis.com/"===k.substring(0,29)||"https://fonts.gstatic.com/"===k.substring(0,26)};Editor.prototype.createImageUrlConverter=function(){var k=new mxUrlConverter;k.updateBaseUrl();var y=k.convert,G=this;k.convert=function(P){if(null!=P){var Q="http://"==P.substring(0,7)||"https://"==P.substring(0,8);Q&&!navigator.onLine?P=Editor.svgBrokenImage.src:!Q||P.substring(0,k.baseUrl.length)== k.baseUrl||G.crossOriginImages&&G.isCorsEnabledForUrl(P)?"chrome-extension://"==P.substring(0,19)||mxClient.IS_CHROMEAPP||(P=y.apply(this,arguments)):P=PROXY_URL+"?url="+encodeURIComponent(P)}return P};return k};Editor.createSvgDataUri=function(k){return"data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(k)))};Editor.prototype.convertImageToDataUri=function(k,y){try{var G=!0,P=window.setTimeout(mxUtils.bind(this,function(){G=!1;y(Editor.svgBrokenImage.src)}),this.timeout);if(/(\.svg)$/i.test(k))mxUtils.get(k,
0
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
vulnerable
mxUtils.setOpacity(V,100),O.style.visibility="",k.stop(),M())}))}else M();A.appendChild(K);++S==R&&(mxUtils.br(A),S=0)}function t(n){var z=B.value;if(null==n||null!=z&&0<z.length)q&&b.hideDialog(),m(z,n,B)}H="1"==urlParams.noDevice?!1:H;E=null!=E?E:!0;F=null!=F?F:!0;R=null!=R?R:4;q=null!=q?q:!0;v=document.createElement("div");v.style.whiteSpace="nowrap";null==d&&b.addLanguageMenu(v);var x=document.createElement("h2");mxUtils.write(x,u||mxResources.get("create"));x.style.marginTop="0px";x.style.marginBottom=
0
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
vulnerable
function(c,e,g,q,p,t,x,B){EditorUi.logEvent("SHOULD NOT BE CALLED: loadUrl");return this.editor.loadUrl(c,e,g,q,p,t,x,B)};EditorUi.prototype.loadFonts=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: loadFonts");return this.editor.loadFonts(c)};EditorUi.prototype.createSvgDataUri=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: createSvgDataUri");return Editor.createSvgDataUri(c)};EditorUi.prototype.embedCssFonts=function(c,e){EditorUi.logEvent("SHOULD NOT BE CALLED: embedCssFonts");return this.editor.embedCssFonts(c, e)};EditorUi.prototype.embedExtFonts=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: embedExtFonts");return this.editor.embedExtFonts(c)};EditorUi.prototype.exportToCanvas=function(c,e,g,q,p,t,x,B,I,A,S,l,n,z,C,D){EditorUi.logEvent("SHOULD NOT BE CALLED: exportToCanvas");return this.editor.exportToCanvas(c,e,g,q,p,t,x,B,I,A,S,l,n,z,C,D)};EditorUi.prototype.createImageUrlConverter=function(){EditorUi.logEvent("SHOULD NOT BE CALLED: createImageUrlConverter");return this.editor.createImageUrlConverter()};
0
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
vulnerable
mxUtils.bind(this,function(Q){this.spinner.stop();y(Graph.xmlDeclaration+"\n"+Graph.svgDoctype+"\n"+mxUtils.getXml(Q))})))}else z=n+".svg",k=this.getFileData(!1,!0,null,mxUtils.bind(this,function(Q){this.spinner.stop();y(Q)}),q)}}catch(Q){this.handleError(Q)}};EditorUi.prototype.createDownloadRequest=function(c,e,g,q,p,t,x,B,I,A,S,l,n){c=this.downloadRequestBuilder(c,e,g,q,p,t,x,B,I,A,S,l,n);e="";for(var z in c)g=c[z],null!=g&&(e+=z+"="+encodeURIComponent(g)+"&");return new mxXmlRequest(EXPORT_URL, e)};EditorUi.prototype.downloadRequestBuilder=function(c,e,g,q,p,t,x,B,I,A,S,l,n){var z=this.editor.graph,C=z.getGraphBounds();g=this.getFileData(!0,null,null,null,g,0==t?!1:"xmlpng"!=e,null,null,null,!Editor.defaultCompressed,"pdf"==e);var D=null,M=null,K=null;if(C.width*C.height>MAX_AREA||g.length>MAX_REQUEST_SIZE)throw{message:mxResources.get("drawingTooLarge")};A=A?"1":"0";"pdf"==e&&(null!=S?(D=S.from,M=S.to):0==t&&(K="1"));"xmlpng"==e&&(A="1",e="png");if(("xmlpng"==e||"svg"==e)&&null!=this.pages&&
0
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
vulnerable
J.formatElt.style.width)}function f(J,c){function e(p,t){var x=J.menus.get(p);p=g.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 g=new Menubar(J,c);if(Editor.enableCustomLibraries&&("1"!=urlParams.embed||
0
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
vulnerable
J.vertex=!0;R.addCell(J);R.dblClick=function(C,D){if(null!=D&&D!=J)R.setSelectionCell(D);else{D=mxUtils.convertPoint(R.container,mxEvent.getClientX(C),mxEvent.getClientY(C));mxEvent.consume(C);C=R.view.scale;var M=R.view.translate;R.setSelectionCell(v((D.x-3*C)/C-M.x,(D.y-3*C)/C-M.y))}};u=new mxKeyHandler(R);u.bindKey(46,E);u.bindKey(8,E);R.getRubberband().isForceRubberbandEvent=function(C){return 0==C.evt.button&&(null==C.getCell()||C.getCell()==J)};R.panningHandler.isForcePanningEvent=function(C){return 2==
0
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
vulnerable
m?H=new mxHierarchicalLayout(v,mxConstants.DIRECTION_WEST):"circle"==m?H=new mxCircleLayout(v):(H=new mxFastOrganicLayout(v,!1),H.forceConstant=80);if(null!=H){var R=function(g,q){v.getModel().beginUpdate();try{null!=g&&g(),H.execute(v.getDefaultParent(),N)}catch(p){throw p;}finally{g=new mxMorphing(v),g.addListener(mxEvent.DONE,mxUtils.bind(this,function(){v.getModel().endUpdate();null!=q&&q()})),g.startAnimation()}},J=mxEdgeHandler.prototype.connect;mxEdgeHandler.prototype.connect=function(g,q,
0
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
vulnerable
t=mxEvent.getClientX(A);q.popupMenuHandler.hideMenu();mxEvent.consume(A)}));mxEvent.addGestureListeners(document.body,null,mxUtils.bind(this,function(A){var S=!1;null!=t&&(this.diagramContainer.style.width=Math.max(20,B+mxEvent.getClientX(A)-t)+"px",S=!0);null!=x&&(this.diagramContainer.style.height=Math.max(20,I+mxEvent.getClientY(A)-x)+"px",S=!0);S&&((window.opener||window.parent).postMessage(JSON.stringify({event:"resize",fullscreen:Editor.inlineFullscreen,rect:this.diagramContainer.getBoundingClientRect()}), "*"),this.inlineSizeChanged(),this.refresh())}),function(A){null==t&&null==x||mxEvent.consume(A);x=t=null});document.body.style.backgroundColor="transparent";this.diagramContainer.style.borderRadius="4px";this.bottomResizer.style.visibility="hidden";this.rightResizer.style.visibility="hidden";this.sketchMenubarElt.style.display="none";e.style.visibility="hidden";c.style.visibility="hidden";g.style.display="none";this.addListener("editInlineStart",mxUtils.bind(this,function(A){this.inlineSizeChanged();
0
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
vulnerable
[];this.traverse(u,!0,mxUtils.bind(this,function(F,L){var N=null!=L&&this.isTreeEdge(L);N&&v.push(L);F==u||null!=L&&!N||v.push(F);return(null==L||N)&&(F==u||!this.model.isCollapsed(F))}));this.model.setCollapsed(u,d);for(var E=0;E<v.length;E++)this.model.setVisible(v[E],!d)}finally{this.model.endUpdate()}};Graph.prototype.isTreeEdge=function(d){return!this.isEdgeIgnored(d)};Graph.prototype.getTreeEdges=function(d,u,v,E,F,L){return this.model.filterCells(this.getEdges(d,u,v,E,F,L),mxUtils.bind(this,
0
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
vulnerable
if(null!=k.excludeCells){for(var G=[],P=0;P<y.length;P++)0>k.excludeCells.indexOf(y[P].id)&&G.push(y[P]);y=G}return y};Graph.prototype.getCellsById=function(k){var y=[];if(null!=k)for(var G=0;G<k.length;G++)if("*"==k[G]){var P=this.model.getRoot();y=y.concat(this.model.filterDescendants(function(U){return U!=P},P))}else{var Q=this.model.getCell(k[G]);null!=Q&&y.push(Q)}return y};var C=Graph.prototype.isCellVisible;Graph.prototype.isCellVisible=function(k){return C.apply(this,arguments)&&!this.isAllTagsHidden(this.getTagsForCell(k))};
0
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
vulnerable
this.getWindows(),e=0;e<c.length;e++)null!=c[e]&&c[e].window.setVisible(!1)};EditorUi.prototype.destroyWindows=function(){null!=this.sidebarWindow&&(this.sidebarWindow.destroy(),this.sidebarWindow=null);null!=this.formatWindow&&(this.formatWindow.destroy(),this.formatWindow=null);null!=this.freehandWindow&&(this.freehandWindow.destroy(),this.freehandWindow=null);null!=this.actions.outlineWindow&&(this.actions.outlineWindow.destroy(),this.actions.outlineWindow=null);null!=this.actions.layersWindow&& (this.actions.layersWindow.destroy(),this.actions.layersWindow=null);null!=this.menus&&(null!=this.menus.tagsWindow&&(this.menus.tagsWindow.destroy(),this.menus.tagsWindow=null),null!=this.menus.findWindow&&(this.menus.findWindow.destroy(),this.menus.findWindow=null),null!=this.menus.findReplaceWindow&&(this.menus.findReplaceWindow.destroy(),this.menus.findReplaceWindow=null),null!=this.menus.commentsWindow&&(this.menus.commentsWindow.destroy(),this.menus.commentsWindow=null))};EditorUi.prototype.switchThemeConstants=
0
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
vulnerable
L;this.okButton=u;this.container=J},TemplatesDialog=function(b,f,m,d,u,v,E,F,L,N,H,R,J,c,e){function g(ia){wa.innerText=ia;wa.style.display="block";setTimeout(function(){wa.style.display="none"},4E3)}function q(){null!=y&&(y.style.fontWeight="normal",y.style.textDecoration="none",G=y,y=null)}function p(ia,aa,la,ma,oa,fa,ja){if(-1<ia.className.indexOf("geTempDlgRadioBtnActive"))return!1;ia.className+=" geTempDlgRadioBtnActive";O.querySelector(".geTempDlgRadioBtn[data-id="+ma+"]").className="geTempDlgRadioBtn "+ (ja?"geTempDlgRadioBtnLarge":"geTempDlgRadioBtnSmall");O.querySelector("."+aa).src="/images/"+la+"-sel.svg";O.querySelector("."+oa).src="/images/"+fa+".svg";return!0}function t(ia,aa,la,ma){function oa(ta,La){null==ja?(ta=/^https?:\/\//.test(ta)&&!b.editor.isCorsEnabledForUrl(ta)?PROXY_URL+"?url="+encodeURIComponent(ta):TEMPLATE_PATH+"/"+ta,mxUtils.get(ta,mxUtils.bind(this,function(Ga){200<=Ga.getStatus()&&299>=Ga.getStatus()&&(ja=Ga.getText());La(ja)}))):La(ja)}function fa(ta,La,Ga){if(null!=ta&&
0
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
vulnerable
function(K,U){return!1};this.alternateEdgeStyle="vertical";null==f&&this.loadStylesheet();var x=this.graphHandler.getGuideStates;this.graphHandler.getGuideStates=function(){var K=x.apply(this,arguments);if(this.graph.pageVisible){var U=[],L=this.graph.pageFormat,O=this.graph.pageScale,X=L.width*O;L=L.height*O;O=this.graph.view.translate;for(var W=this.graph.view.scale,J=this.graph.getPageLayout(),ha=0;ha<J.width;ha++)U.push(new mxRectangle(((J.x+ha)*X+O.x)*W,(J.y*L+O.y)*W,X*W,L*W));for(ha=1;ha<J.height;ha++)U.push(new mxRectangle((J.x*
0
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
vulnerable
b.showDialog(S.container,450,240,!0);S.init()}else u.constructor==DriveLibrary?b.showError(mxResources.get("error"),mxResources.get("diagramIsNotPublic"),mxResources.get("share"),mxUtils.bind(this,function(){b.drive.showPermissions(u.getId())}),null,mxResources.get("ok"),mxUtils.bind(this,function(){})):b.handleError({message:mxResources.get("diagramIsNotPublic")})})}),f.className="geBtn",d.appendChild(f));f=mxUtils.button(mxResources.get("export"),function(){var S=b.createLibraryDataFromImages(H),
0
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
vulnerable
function(z){H=z};this.setAutoScroll=function(z){R=z};this.setOpenFill=function(z){J=z};this.setStopClickEnabled=function(z){g=z};this.setSelectInserted=function(z){q=z};this.setSmoothing=function(z){m=z};this.setPerfectFreehandMode=function(z){t=z};this.isPerfectFreehandMode=function(){return t};this.setBrushSize=function(z){p.size=z};this.getBrushSize=function(){return p.size};var x=function(z){e=z;b.getRubberband().setEnabled(!z);b.graphHandler.setSelectEnabled(!z);b.graphHandler.setMoveEnabled(!z);
0
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
vulnerable
function(k){this.model.beginUpdate();try{for(var y=0;y<k.length;y++)this.model.setVisible(k[y],!this.model.isVisible(k[y]))}finally{this.model.endUpdate()}};Graph.prototype.setCellsVisible=function(k,y){this.model.beginUpdate();try{for(var G=0;G<k.length;G++)this.model.setVisible(k[G],y)}finally{this.model.endUpdate()}};Graph.prototype.highlightCells=function(k,y,G,P){for(var Q=0;Q<k.length;Q++)this.highlightCell(k[Q],y,G,P)};Graph.prototype.highlightCell=function(k,y,G,P,Q){y=null!=y?y:mxConstants.DEFAULT_VALID_COLOR;
0
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
vulnerable
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 E(S){for(S=document.elementFromPoint(S.clientX,
0
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
vulnerable
{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];StyleFormatPanel.prototype.customColorSchemes=null;StyleFormatPanel.prototype.findCommonProperties=function(k,y,G){if(null!=y){var P=function(U){if(null!=U)if(G)for(var T=0;T<U.length;T++)y[U[T].name]=U[T];else for(var W in y){var X=!1;for(T=0;T<U.length;T++)if(U[T].name==W&&U[T].type==y[W].type){X=!0;break}X||delete y[W]}},Q=this.editorUi.editor.graph.view.getState(k);
0
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
vulnerable
(ja?"geTempDlgRadioBtnLarge":"geTempDlgRadioBtnSmall");O.querySelector("."+aa).src="/images/"+la+"-sel.svg";O.querySelector("."+oa).src="/images/"+fa+".svg";return!0}function t(ia,aa,la,ma){function oa(ta,La){null==ja?(ta=/^https?:\/\//.test(ta)&&!b.editor.isCorsEnabledForUrl(ta)?PROXY_URL+"?url="+encodeURIComponent(ta):TEMPLATE_PATH+"/"+ta,mxUtils.get(ta,mxUtils.bind(this,function(Ga){200<=Ga.getStatus()&&299>=Ga.getStatus()&&(ja=Ga.getText());La(ja)}))):La(ja)}function fa(ta,La,Ga){if(null!=ta&& mxUtils.isAncestorNode(document.body,aa)&&(ta=mxUtils.parseXml(ta),ta=Editor.extractGraphModel(ta.documentElement,!0),null!=ta)){"mxfile"==ta.nodeName&&(ta=Editor.parseDiagramNode(ta.getElementsByTagName("diagram")[0]));var ya=new mxCodec(ta.ownerDocument),Ja=new mxGraphModel;ya.decode(ta,Ja);ta=Ja.root.getChildAt(0).children||[];b.sidebar.createTooltip(aa,ta,Math.min((window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)-80,1E3),Math.min((window.innerHeight||document.documentElement.clientHeight|| 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";O.appendChild(Ma);var ra=b.sidebar.hideTooltip;b.sidebar.hideTooltip=function(){Ma&&(O.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();
0
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
vulnerable
X+O.x)*W,((J.y+ha)*L+O.y)*W,X*W,L*W));K=U.concat(K)}return K};mxDragSource.prototype.dragElementZIndex=mxPopupMenu.prototype.zIndex;mxGuide.prototype.getGuideColor=function(K,U){return null==K.cell?"#ffa500":mxConstants.GUIDE_COLOR};this.graphHandler.createPreviewShape=function(K){this.previewColor="#000000"==this.graph.background?"#ffffff":mxGraphHandler.prototype.previewColor;return mxGraphHandler.prototype.createPreviewShape.apply(this,arguments)};var z=this.graphHandler.getCells;this.graphHandler.getCells=
0
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
vulnerable
ha));Q--;0==Q&&y(k)})):Y.setAttribute(W,ca)}else null!=Z&&Y.setAttribute(W,Z)}}catch(ha){}})(T[X])});G("image","xlink:href");G("img","src");0==Q&&y(k)};Editor.base64Encode=function(k){for(var y="",G=0,P=k.length,Q,U,T;G<P;){Q=k.charCodeAt(G++)&255;if(G==P){y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(Q>>2);y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((Q&3)<<4);y+="==";break}U=k.charCodeAt(G++);if(G==P){y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(Q>> 2);y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((Q&3)<<4|(U&240)>>4);y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((U&15)<<2);y+="=";break}T=k.charCodeAt(G++);y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(Q>>2);y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((Q&3)<<4|(U&240)>>4);y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((U&15)<<2|(T&192)>>6); y+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(T&63)}return y};Editor.prototype.loadUrl=function(k,y,G,P,Q,U,T,W){try{var X=!T&&(P||/(\.png)($|\?)/i.test(k)||/(\.jpe?g)($|\?)/i.test(k)||/(\.gif)($|\?)/i.test(k)||/(\.pdf)($|\?)/i.test(k));Q=null!=Q?Q:!0;var Y=mxUtils.bind(this,function(){mxUtils.get(k,mxUtils.bind(this,function(Z){if(200<=Z.getStatus()&&299>=Z.getStatus()){if(null!=y){var ca=Z.getText();if(X){if((9==document.documentMode||10==document.documentMode)&&"undefined"!==
0
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
vulnerable
G=y.editor.graph;if(G.isEnabled()){var P=y.getCurrentFile();null!=P&&P.isAutosaveOptional()&&k.appendChild(this.createOption(mxResources.get("autosave"),function(){return y.editor.autosave},function(T){y.editor.setAutosave(T);y.editor.autosave&&P.isModified()&&P.fileChanged()},{install:function(T){this.listener=function(){T(y.editor.autosave)};y.editor.addListener("autosaveChanged",this.listener)},destroy:function(){y.editor.removeListener(this.listener)}}))}if(this.isMathOptionVisible()&&G.isEnabled()&&
0
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
vulnerable
ma.join(" ")}null!=ia?(P=ia,P.className+=" "+aa,Q=la,ka.className="geTempDlgCreateBtn"):(Q=P=null,ka.className="geTempDlgCreateBtn geTempDlgBtnDisabled")}function B(ia,aa){if(null!=Q){var la=function(sa){ja.isExternal?L(ja,function(ta){ma(ta,sa)},oa):ja.url?mxUtils.get(TEMPLATE_PATH+"/"+ja.url,mxUtils.bind(this,function(ta){200<=ta.getStatus()&&299>=ta.getStatus()?ma(ta.getText(),sa):oa()})):ma(b.emptyDiagramXml,sa)},ma=function(sa,ta){e||b.hideDialog(!0);f(sa,ta,ja,aa)},oa=function(){g(mxResources.get("cannotLoad")); fa()},fa=function(){Q=ja;ka.className="geTempDlgCreateBtn";aa&&(Aa.className="geTempDlgOpenBtn")},ja=Q;Q=null;"boolean"!==typeof aa&&(aa=ja.isExternal&&R);1==ia?N(ja.url,ja):aa?(Aa.className="geTempDlgOpenBtn geTempDlgBtnDisabled geTempDlgBtnBusy",la()):(ka.className="geTempDlgCreateBtn geTempDlgBtnDisabled geTempDlgBtnBusy",ia=null==b.mode||b.mode==App.MODE_GOOGLE||b.mode==App.MODE_BROWSER?mxResources.get("diagramName"):mxResources.get("filename"),ia=new FilenameDialog(b,b.defaultFilename+".drawio",
0
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
vulnerable
g&&t.setAttribute("resource",g);var z=mxUtils.bind(this,function(C){C=(q?"":Graph.xmlDeclaration+"\n"+Graph.svgFileComment+"\n"+Graph.svgDoctype+"\n")+mxUtils.getXml(C);null!=p&&p(C);return C});e.mathEnabled&&this.editor.addMathCss(t);if(null!=p)this.embedFonts(t,mxUtils.bind(this,function(C){B?this.editor.convertImages(C,mxUtils.bind(this,function(D){z(D)})):z(C)}));else return z(t)};EditorUi.prototype.embedFonts=function(c,e){this.editor.loadFonts(mxUtils.bind(this,function(){try{null!=this.editor.resolvedFontCss&& this.editor.addFontCss(c,this.editor.resolvedFontCss),this.editor.embedExtFonts(mxUtils.bind(this,function(g){try{null!=g&&this.editor.addFontCss(c,g),e(c)}catch(q){e(c)}}))}catch(g){e(c)}}))};EditorUi.prototype.exportImage=function(c,e,g,q,p,t,x,B,I,A,S,l,n){I=null!=I?I:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var z=this.editor.graph.isSelectionEmpty();g=null!=g?g:z;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.editor.exportToCanvas(mxUtils.bind(this,
0
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
vulnerable
arguments);N.style.backgroundColor=""};H.dblClick=function(){};var P=H.getSelectionModel().changeSelection;H.getSelectionModel().changeSelection=function(){P.call(this,[c],[c])}};L.onerror=function(){L.onload=null;L.src=Editor.errorImage};L.setAttribute("src",f);L.style.maxWidth="300px";L.style.maxHeight="300px";F.appendChild(L);E.appendChild(F);var N=document.createElement("div");N.style.width="300px";N.style.height="300px";N.style.overflow="hidden";N.style.backgroundColor="#fff9";E.appendChild(N);
0
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
vulnerable
"keys",Da,"values",Ta,"cells",ca.getSelectionCells()))}finally{ca.getModel().endUpdate()}}function Q(pa,ua,va){var Ea=mxUtils.getOffset(k,!0),Da=mxUtils.getOffset(pa,!0);ua.style.position="absolute";ua.style.left=Da.x-Ea.x+"px";ua.style.top=Da.y-Ea.y+"px";ua.style.width=pa.offsetWidth+"px";ua.style.height=pa.offsetHeight-(va?4:0)+"px";ua.style.zIndex=5}function U(pa,ua,va){var Ea=document.createElement("div");Ea.style.width="32px";Ea.style.height="4px";Ea.style.margin="2px";Ea.style.border="1px solid black"; Ea.style.background=ua&&"none"!=ua?ua:"url('"+Dialog.prototype.noColorImage+"')";btn=mxUtils.button("",mxUtils.bind(Z,function(Da){this.editorUi.pickColor(ua,function(Ta){Ea.style.background="none"==Ta?"url('"+Dialog.prototype.noColorImage+"')":Ta;P(pa,Ta,va)});mxEvent.consume(Da)}));btn.style.height="12px";btn.style.width="40px";btn.className="geColorBtn";btn.appendChild(Ea);return btn}function T(pa,ua,va,Ea,Da,Ta,Ia){null!=ua&&(ua=ua.split(","),ha.push({name:pa,values:ua,type:va,defVal:Ea,countProperty:Da,
0
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
vulnerable
var D=0,M=0,K=J.geometry,O=mxUtils.format((C.geometry.x+3-K.x)/K.width);C=mxUtils.format((C.geometry.y+3-K.y)/K.height);0>O?(D=O*K.width,O=0):1<O&&(D=(O-1)*K.width,O=1);0>C?(M=C*K.height,C=0):1<C&&(M=(C-1)*K.height,C=1);return{x:O,y:C,dx:parseInt(D),dy:parseInt(M)}}function N(C){if(1==R.getSelectionCount()){var D=R.getSelectionCell();C&&(D.constObj=null);C=L(D);S.value=100*C.x;n.value=100*C.y;l.value=C.dx;z.value=C.dy;A.style.visibility=""}else A.style.visibility="hidden"}var H=document.createElement("div");
0
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
vulnerable
t.descriptorChanged=function(){l.apply(this,arguments);var W=t.getCurrentFile();if(null!=W&&null!=W.getTitle()){var X=W.getMode();"google"==X?X="googleDrive":"github"==X?X="gitHub":"gitlab"==X?X="gitLab":"onedrive"==X&&(X="oneDrive");X=mxResources.get(X);B.setAttribute("title",W.getTitle()+(null!=X?" ("+X+")":""))}else B.removeAttribute("title")};t.setStatusText(t.editor.getStatus());B.appendChild(t.statusContainer);t.buttonContainer=document.createElement("div");t.buttonContainer.style.cssText="display:flex;justify-content:flex-end;padding-right:10px;gap:6px;white-space:nowrap;background-color:inherit;align-items:center;min-width:0;margin-left:auto;";
0
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
vulnerable
P));this.graph.isRelativeUrl(T)&&(T=null!=Q?Q+T:window.location.protocol+"//"+window.location.hostname+("/"==T.charAt(0)?"":k)+T);y.push('url("'+T+'"'+G[U].substring(P))}else y.push(G[U])}else y=[k]}return null!=y?y.join(""):null};Editor.prototype.mapFontUrl=function(k,y,G){/^https?:\/\//.test(y)&&!this.isCorsEnabledForUrl(y)&&(y=PROXY_URL+"?url="+encodeURIComponent(y));G(k,y)};Editor.prototype.embedCssFonts=function(k,y){var G=k.split("url("),P=0;null==this.cachedFonts&&(this.cachedFonts={});var Q=
0
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
vulnerable
this.libraryLoaded(c,q,g.documentElement.getAttribute("title"),e)}else throw{message:mxResources.get("notALibraryFile")};};EditorUi.prototype.getLibraryStorageHint=function(c){return""};EditorUi.prototype.libraryLoaded=function(c,e,g,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=
0
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
vulnerable
k.baseUrl||G.crossOriginImages&&G.isCorsEnabledForUrl(P)?"chrome-extension://"==P.substring(0,19)||mxClient.IS_CHROMEAPP||(P=y.apply(this,arguments)):P=PROXY_URL+"?url="+encodeURIComponent(P)}return P};return k};Editor.createSvgDataUri=function(k){return"data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(k)))};Editor.prototype.convertImageToDataUri=function(k,y){try{var G=!0,P=window.setTimeout(mxUtils.bind(this,function(){G=!1;y(Editor.svgBrokenImage.src)}),this.timeout);if(/(\.svg)$/i.test(k))mxUtils.get(k,
0
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
vulnerable
[C],"{1} ago"));z.setAttribute("title",n.toLocaleDateString()+" "+n.toLocaleTimeString())}function N(n){var z=document.createElement("img");z.className="geCommentBusyImg";z.src=IMAGE_PATH+"/spin.gif";n.appendChild(z);n.busyImg=z}function H(n){n.style.border="1px solid red";n.removeChild(n.busyImg)}function R(n){n.style.border="";n.removeChild(n.busyImg)}function J(n,z,C,D,M){function K(U,T,W){var X=document.createElement("li");X.className="geCommentAction";var Y=document.createElement("a");Y.className=
0
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
vulnerable
Ka+" ("+Xa.length+")",Ra=Ka=mxUtils.htmlEntities(Ka);15<Ka.length&&(Ka=Ka.substring(0,15)+"&hellip;");return{lbl:Ka+" ("+Xa.length+")",fullLbl:Pa,lblOnly:Ra}}function oa(Ka,Xa,Pa,Ra,Oa){mxEvent.addListener(Pa,"click",function(){y!=Pa&&(null!=y?(y.style.fontWeight="normal",y.style.textDecoration="none"):(da.style.display="none",ba.style.minHeight="100%"),y=Pa,y.style.fontWeight="bold",y.style.textDecoration="underline",Ba.scrollTop=0,V&&(k=!0),za.innerHTML=Xa,Ca.style.display="none",A(Oa?aa[Ka]:Ra? Da[Ka][Ra]:ia[Ka],Oa?!1:!0))})}var fa=O.querySelector(".geTemplatesList");if(0<la){la=document.createElement("div");la.style.cssText="font-weight: bold;background: #f9f9f9;padding: 5px 0 5px 0;text-align: center;margin-top: 10px;";mxUtils.write(la,mxResources.get("custom"));fa.appendChild(la);for(var ja in aa){la=document.createElement("div");var sa=aa[ja];sa=ma(ja,sa);la.className="geTemplateCatLink";la.setAttribute("title",sa.fullLbl);la.innerHTML=sa.lbl;fa.appendChild(la);oa(ja,sa.lblOnly,la,null,
0
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
vulnerable
c=D;this.confirmImageResize(function(V){C=V;O()},I)}else O()};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 g=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?
0
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
vulnerable
Toolbar.prototype.selectedBackground="rgb(242, 242, 242)"),Editor.prototype.initialTopSpacing=3,EditorUi.prototype.menubarHeight=41,EditorUi.prototype.toolbarHeight=38);"sketch"==Editor.currentTheme&&(Editor.configurationKey=".sketch-configuration",Editor.settingsKey=".sketch-config")};EditorUi.initTheme();EditorUi.prototype.showImageDialog=function(c,e,g,q,p,t,x){c=new ImageDialog(this,c,e,g,q,p,t,x);this.showDialog(c.container,Graph.fileSupport?480:360,Graph.fileSupport?200:90,!0,!0);c.init()};
0
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
vulnerable
D.readAsText(C)}else this.doImportVisio(C,e,B,q)}catch(M){B(M)}else try{""==z.responseType||"text"==z.responseType?B({message:z.responseText}):(D=new FileReader,D.onload=function(){try{B({message:JSON.parse(D.result).Message})}catch(M){B(M)}},D.readAsText(z.response))}catch(M){B({})}});z.send(A)}else if(x.clear())try{this.doImportVisio(c,e,B,q)}catch(C){B(C)}}else B({message:mxResources.get("serviceUnavailableOrBlocked")})});this.doImportVisio||this.loadingExtensions||this.isOffline(!0)?I():(this.loadingExtensions=
0
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
vulnerable
k);mxEvent.addListener(this.container,"mousemove",k);mxEvent.addListener(this.container,"mouseleave",function(Q){y=null});this.isMouseInsertPoint=function(){return null!=y};var G=this.getInsertPoint;this.getInsertPoint=function(){return null!=y?this.getPointForEvent(y):G.apply(this,arguments)};var P=this.layoutManager.getLayout;this.layoutManager.getLayout=function(Q){var U=this.graph.getCellStyle(Q);if(null!=U&&"rack"==U.childLayout){var T=new mxStackLayout(this.graph,!1);T.gridSize=null!=U.rackUnitSize? parseFloat(U.rackUnitSize):"undefined"!==typeof mxRackContainer?mxRackContainer.unitSize:20;T.marginLeft=U.marginLeft||0;T.marginRight=U.marginRight||0;T.marginTop=U.marginTop||0;T.marginBottom=U.marginBottom||0;T.allowGaps=U.allowGaps||0;T.horizontal="1"==mxUtils.getValue(U,"horizontalRack","0");T.resizeParent=!1;T.fill=!0;return T}return P.apply(this,arguments)};this.updateGlobalUrlVariables()};var g=Graph.prototype.postProcessCellStyle;Graph.prototype.postProcessCellStyle=function(k,y){return Graph.processFontStyle(g.apply(this,
0
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
vulnerable
function(c){c=mxUtils.parseXml(c);var e=this.editor.extractGraphModel(c.documentElement);c=[];if(null!=e){var g=new mxCodec(e.ownerDocument),q=new mxGraphModel;g.decode(e,q);e=q.getChildAt(q.getRoot(),0);for(g=0;g<q.getChildCount(e);g++)c.push(q.getChildAt(e,g))}return c};EditorUi.prototype.openFileHandle=function(c,e,g,q,p){if(null!=e&&0<e.length){if(!this.useCanvasForExport&&/(\.png)$/i.test(e)||/(\.pdf)$/i.test(e))e=e.substring(0,e.length-4),/(\.drawio)$/i.test(e)||(e+=".drawio");var t=mxUtils.bind(this,
0
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
vulnerable