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
mxEvent.isShiftDown(R)?n.gridSize:null,!0)}:function(){e(R.keyCode,mxEvent.isShiftDown(R)?n.gridSize:null)}}return S.apply(this,arguments)};y.bindAction=mxUtils.bind(this,function(R,V,d,f){var l=this.actions.get(d);null!=l&&(d=function(){l.isEnabled()&&l.funct.apply(this,arguments)},V?f?y.bindControlShiftKey(R,d):y.bindControlKey(R,d):f?y.bindShiftKey(R,d):y.bindKey(R,d))});var G=this,L=y.escape;y.escape=function(R){L.apply(this,arguments)};y.enter=function(){};y.bindControlShiftKey(36,function(){n.exitGroup()});
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
mxConstants.NONE,null,null,null,10,null,null,!1,null,0<d.length?d:null)}catch(u){this.handleError(u)}};EditorUi.prototype.writeImageToClipboard=function(d,f,l,u){var A=this.base64ToBlob(d.substring(d.indexOf(",")+1),"image/png");d=new ClipboardItem({"image/png":A,"text/html":new Blob(['<img src="'+d+'" width="'+f+'" height="'+l+'">'],{type:"text/html"})});navigator.clipboard.write([d])["catch"](u)};EditorUi.prototype.copyCells=function(d,f){var l=this.editor.graph;if(l.isSelectionEmpty())d.innerText=
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);null!=l&&B.setAttribute("resource",l);var ia=mxUtils.bind(this,function(ma){ma=(u?"":Graph.xmlDeclaration+"\n"+Graph.svgFileComment+"\n"+Graph.svgDoctype+"\n")+mxUtils.getXml(ma);null!=A&&A(ma);return ma});f.mathEnabled&&this.editor.addMathCss(B);if(null!=A)this.embedFonts(B,mxUtils.bind(this,function(ma){M?this.editor.convertImages(ma,mxUtils.bind(this,function(aa){ia(aa)})):ia(ma)}));else return ia(B)};EditorUi.prototype.embedFonts=function(d,f){this.editor.loadFonts(mxUtils.bind(this,function(){try{null!= this.editor.resolvedFontCss&&this.editor.addFontCss(d,this.editor.resolvedFontCss),this.editor.embedExtFonts(mxUtils.bind(this,function(l){try{null!=l&&this.editor.addFontCss(d,l),f(d)}catch(u){f(d)}}))}catch(l){f(d)}}))};EditorUi.prototype.exportImage=function(d,f,l,u,A,B,F,M,O,H,ja,da,ca){O=null!=O?O:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var ia=this.editor.graph.isSelectionEmpty();l=null!=l?l:ia;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
mxGraph.prototype.getBoundingBoxFromGeometry=function(a,b){b=null!=b?b:!1;var c=null;if(null!=a)for(var d=0;d<a.length;d++)if(b||this.model.isVertex(a[d])){var e=this.getCellGeometry(a[d]);if(null!=e){var f=null;if(this.model.isEdge(a[d])){f=function(l){null!=l&&(null==g?g=new mxRectangle(l.x,l.y,0,0):g.add(new mxRectangle(l.x,l.y,0,0)))};null==this.model.getTerminal(a[d],!0)&&f(e.getTerminalPoint(!0));null==this.model.getTerminal(a[d],!1)&&f(e.getTerminalPoint(!1));e=e.points;if(null!=e&&0<e.length)for(var 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
!navigator.onLine||!d&&("1"==urlParams.stealth||"1"==urlParams.lockdown)};EditorUi.prototype.isExternalDataComms=function(){return"1"!=urlParams.offline&&!this.isOffline()&&!this.isOfflineApp()};EditorUi.prototype.createSpinner=function(d,f,l){var u=null==d||null==f;l=null!=l?l:24;var A=new Spinner({lines:12,length:l,width:Math.round(l/3),radius:Math.round(l/2),rotate:0,color:Editor.isDarkMode()?"#c0c0c0":"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),B=A.spin;A.spin=function(M,O){var H= !1;this.active||(B.call(this,M),this.active=!0,null!=O&&(u&&(f=Math.max(document.body.clientHeight||0,document.documentElement.clientHeight||0)/2,d=document.body.clientWidth/2-2),H=document.createElement("div"),H.style.position="absolute",H.style.whiteSpace="nowrap",H.style.background="#4B4243",H.style.color="white",H.style.fontFamily=Editor.defaultHtmlFont,H.style.fontSize="9pt",H.style.padding="6px",H.style.paddingLeft="10px",H.style.paddingRight="10px",H.style.zIndex=2E9,H.style.left=Math.max(0, d)+"px",H.style.top=Math.max(0,f+70)+"px",mxUtils.setPrefixedStyle(H.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(H.style,"transform","translate(-50%,-50%)"),Editor.isDarkMode()||mxUtils.setPrefixedStyle(H.style,"boxShadow","2px 2px 3px 0px #ddd"),"..."!=O.substring(O.length-3,O.length)&&"!"!=O.charAt(O.length-1)&&(O+="..."),H.innerHTML=O,M.appendChild(H),A.status=H),this.pause=mxUtils.bind(this,function(){var ja=function(){};this.active&&(ja=mxUtils.bind(this,function(){this.spin(M,O)})); this.stop();return ja}),H=!0);return H};var F=A.stop;A.stop=function(){F.call(this);this.active=!1;null!=A.status&&null!=A.status.parentNode&&A.status.parentNode.removeChild(A.status);A.status=null};A.pause=function(){return function(){}};return A};EditorUi.prototype.isCompatibleString=function(d){try{var f=mxUtils.parseXml(d),l=this.editor.extractGraphModel(f.documentElement,!0);return null!=l&&0==l.getElementsByTagName("parsererror").length}catch(u){}return!1};EditorUi.prototype.isVisioData=function(d){return 8<
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
!f||X(mxResources.get("reply"),function(){U("",!0)},ca.isResolved);J=b.getCurrentUser();null==J||J.id!=ca.user.id||d||ca.isLocked||(X(mxResources.get("edit"),function(){function Z(){K(ca,k,function(){G(k);ca.editComment(ca.content,function(){R(k)},function(ba){L(k);Z();b.handleError(ba,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})})}Z()},ca.isResolved),X(mxResources.get("delete"),function(){b.confirm(mxResources.get("areYouSure"),function(){G(k);ca.deleteComment(function(Z){if(!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
f));d.setCellStyles(mxConstants.STYLE_CLIP_PATH,L,[G]);d.setCellStyles(mxConstants.STYLE_ASPECT,"fixed",[G])}finally{d.getModel().endUpdate()}}var n=this.editorUi,y=n.editor,q=y.graph,E=function(){return Action.prototype.isEnabled.apply(this,arguments)&&q.isEnabled()};this.addAction("new...",function(){q.openLink(n.getUrl())});this.addAction("open...",function(){window.openNew=!0;window.openKey="open";n.openFile()});this.put("smartFit",new Action(mxResources.get("fitWindow")+" / "+mxResources.get("resetView"),
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
f.parentNode&&f.parentNode.removeChild(f)}))};var L=!1;EditorUi.prototype.initFormatWindow=function(){if(!L&&null!=this.formatWindow){L=!0;var V=this.formatWindow.window.toggleMinimized,d=240;this.formatWindow.window.toggleMinimized=function(){V.apply(this,arguments);this.minimized?(d=parseInt(this.div.style.width),this.div.style.width="140px",this.table.style.width="140px",this.div.style.left=parseInt(this.div.style.left)+d-140+"px"):(this.div.style.width=d+"px",this.table.style.width=this.div.style.width, this.div.style.left=Math.max(0,parseInt(this.div.style.left)-d+140)+"px");this.fit()};mxEvent.addListener(this.formatWindow.window.title,"dblclick",mxUtils.bind(this,function(f){mxEvent.getSource(f)==this.formatWindow.window.title&&this.formatWindow.window.toggleMinimized()}))}};var R=EditorUi.prototype.init;EditorUi.prototype.init=function(){function V(ha,qa,ra){var pa=B.menus.get(ha),xa=H.addMenu(mxResources.get(ha),mxUtils.bind(this,function(){pa.funct.apply(this,arguments)}),O);xa.className="geMenuItem";
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 V(){mxShape.call(this)}function d(c,m,x,p){mxShape.call(this);this.bounds=c;this.fill=m;this.stroke=x;this.strokewidth=null!=p?p:1}function f(){mxActor.call(this)}function l(){mxCylinder.call(this)}function u(){mxCylinder.call(this)}function A(){mxActor.call(this)}function B(){mxActor.call(this)}function F(){mxActor.call(this)}function M(){mxActor.call(this)}function O(){mxActor.call(this)}function H(){mxActor.call(this)}function ja(){mxActor.call(this)}function da(c,m){this.canvas=c;this.canvas.setLineJoin("round");
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 A};EditorUi.prototype.getHashValueForPages=function(d,f){var l=0,u=new mxGraphModel,A=new mxCodec;null!=f&&(f.byteCount=0,f.attrCount=0,f.eltCount=0,f.nodeCount=0);for(var B=0;B<d.length;B++){this.updatePageRoot(d[B]);var F=d[B].node.cloneNode(!1);F.removeAttribute("name");u.root=d[B].root;var M=A.encode(u);this.editor.graph.saveViewState(d[B].viewState,M,!0);M.removeAttribute("pageWidth");M.removeAttribute("pageHeight");F.appendChild(M);null!=f&&(f.eltCount+=F.getElementsByTagName("*").length, f.nodeCount+=F.getElementsByTagName("mxCell").length);l=(l<<5)-l+this.hashValue(F,function(O,H,ja,da){return!da||"mxGeometry"!=O.nodeName&&"mxPoint"!=O.nodeName||"x"!=H&&"y"!=H&&"width"!=H&&"height"!=H?da&&"mxCell"==O.nodeName&&"previous"==H?null:ja:Math.round(ja)},f)<<0}return l};EditorUi.prototype.hashValue=function(d,f,l){var u=0;if(null!=d&&"object"===typeof d&&"number"===typeof d.nodeType&&"string"===typeof d.nodeName&&"function"===typeof d.getAttribute){null!=d.nodeName&&(u^=this.hashValue(d.nodeName,
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 V(){mxShape.call(this)}function d(c,m,x,p){mxShape.call(this);this.bounds=c;this.fill=m;this.stroke=x;this.strokewidth=null!=p?p:1}function f(){mxActor.call(this)}function l(){mxCylinder.call(this)}function u(){mxCylinder.call(this)}function A(){mxActor.call(this)}function B(){mxActor.call(this)}function F(){mxActor.call(this)}function M(){mxActor.call(this)}function O(){mxActor.call(this)}function H(){mxActor.call(this)}function ja(){mxActor.call(this)}function da(c,m){this.canvas=c;this.canvas.setLineJoin("round");
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:page/id,"+l:null==this.getPageById(F)&&delete B.open}}f="data:action/json,"+JSON.stringify(u)}}catch(M){}return f};EditorUi.prototype.isRemoteVisioFormat=function(d){return/(\.v(sd|dx))($|\?)/i.test(d)||/(\.vs(s|x))($|\?)/i.test(d)};EditorUi.prototype.importVisio=function(d,f,l,u,A){var B=mxUtils.bind(this,function(F){this.loadingExtensions=!1;null!=l?l(F):this.handleError(F)});this.createTimeout(null,mxUtils.bind(this,function(F){u=null!=u?u:d.name;var M=mxUtils.bind(this,function(H){F.clear()&&
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
f,u,null,M,O,da,null,null,l.scale,l.border);return ja};EditorUi.prototype.getXmlFileData=function(d,f,l,u){d=null!=d?d:!0;f=null!=f?f:!1;l=null!=l?l:!Editor.defaultCompressed;var A=this.editor.getGraphXml(d,u);if(d&&null!=this.fileNode&&null!=this.currentPage)if(d=function(O){var H=O.getElementsByTagName("mxGraphModel");H=0<H.length?H[0]:null;null==H&&l?(H=mxUtils.trim(mxUtils.getTextContent(O)),O=O.cloneNode(!1),0<H.length&&(H=Graph.decompress(H),null!=H&&0<H.length&&O.appendChild(mxUtils.parseXml(H).documentElement))): null==H||l?O=O.cloneNode(!0):(O=O.cloneNode(!1),mxUtils.setTextContent(O,Graph.compressNode(H)));A.appendChild(O)},EditorUi.removeChildNodes(this.currentPage.node),mxUtils.setTextContent(this.currentPage.node,Graph.compressNode(A)),A=this.fileNode.cloneNode(!1),f)d(this.currentPage.node);else for(f=0;f<this.pages.length;f++){var B=this.pages[f],F=B.node;if(B!=this.currentPage)if(B.needsUpdate){var M=new mxCodec(mxUtils.createXmlDocument());M=M.encode(new mxGraphModel(B.root));this.editor.graph.saveViewState(B.viewState,
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;G.prototype.paintVertexShape=function(c,m,x,p,t){var C=Math.max(0,Math.min(p,Math.min(t,parseFloat(mxUtils.getValue(this.style,"size",this.size))))),D=Math.max(-1,Math.min(1,parseFloat(mxUtils.getValue(this.style,"darkOpacity",this.darkOpacity))));c.translate(m,x);c.begin();c.moveTo(0,0);c.lineTo(p-C,0);c.lineTo(p,C);c.lineTo(p,t);c.lineTo(0,t);c.lineTo(0,0);c.close();c.end();c.fillAndStroke();this.outline||(c.setShadow(!1),0!=D&&(c.setFillAlpha(Math.abs(D)),c.setFillColor(0>D?"#FFFFFF":"#000000"), c.begin(),c.moveTo(p-C,0),c.lineTo(p-C,C),c.lineTo(p,C),c.close(),c.fill()),c.begin(),c.moveTo(p-C,0),c.lineTo(p-C,C),c.lineTo(p,C),c.end(),c.stroke())};mxCellRenderer.registerShape("note",G);mxUtils.extend(L,G);mxCellRenderer.registerShape("note2",L);L.prototype.getLabelMargins=function(c){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var m=mxUtils.getValue(this.style,"size",15);return new mxRectangle(0,Math.min(c.height*this.scale,m*this.scale),0,0)}return null};mxUtils.extend(R,mxShape);R.prototype.isoAngle=
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(d){return null};EditorUi.prototype.getTitleForService=function(d){return mxResources.get(d)};EditorUi.prototype.pickFolder=function(d,f,l){f(null)};EditorUi.prototype.exportSvg=function(d,f,l,u,A,B,F,M,O,H,ja,da,ca,ia){if(this.spinner.spin(document.body,mxResources.get("export")))try{var ma=this.editor.graph.isSelectionEmpty();l=null!=l?l:ma;var aa=f?null:this.editor.graph.background;aa==mxConstants.NONE&&(aa=null);null==aa&&0==f&&(aa="dark"!=ja||Editor.enableSvgDarkMode?"#ffffff":Editor.darkColor);
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>mxUtils.indexOf(EditorUi.mermaidDiagramTypes,u)&&(f="classDiagram\n"+f);EditorUi.debug("EditorUi.extractMermaidDeclaration","\nlines:",l,"\ntype:",u,"\nvalue:",d,"\ntext:",f);return f};EditorUi.prototype.removeMermaidComments=function(d){d=d.split("\n");for(var f=[],l=0;l<d.length;l++)"%%"!=d[l].substring(0,2)&&f.push(d[l]);return f.join("\n")};EditorUi.prototype.generateMermaidImage=function(d,f,l,u,A){d=this.removeMermaidComments(d);var B=mxUtils.bind(this,function(M){this.loadingMermaid=!1;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
for(i=0;i<M.length;i+=3)r=i+2==M.length?r+A(M.charCodeAt(i),M.charCodeAt(i+1),0):i+1==M.length?r+A(M.charCodeAt(i),0,0):r+A(M.charCodeAt(i),M.charCodeAt(i+1),M.charCodeAt(i+2));return r}(Graph.arrayBufferToString(pako.deflateRaw(d))),!0);"txt"!=f&&(F.responseType="blob");F.onload=function(M){if(200<=this.status&&300>this.status)if("txt"==f)l(this.response);else{var O=new FileReader;O.readAsDataURL(this.response);O.onloadend=function(H){var ja=new Image;ja.onload=function(){try{var da=ja.width,ca= ja.height;if(0==da&&0==ca){var ia=O.result,ma=ia.indexOf(","),aa=decodeURIComponent(escape(atob(ia.substring(ma+1)))),la=mxUtils.parseXml(aa).getElementsByTagName("svg");0<la.length&&(da=parseFloat(la[0].getAttribute("width")),ca=parseFloat(la[0].getAttribute("height")))}l(O.result,da,ca)}catch(X){u(X)}};ja.src=O.result};O.onerror=function(H){u(H)}}else u(M)};F.onerror=function(M){u(M)};F.send()};EditorUi.prototype.insertAsPreText=function(d,f,l){var u=this.editor.graph,A=null;u.getModel().beginUpdate();
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,f,l,u,A,M,H);da!=this.editor.graph&&da.container.parentNode.removeChild(da.container);return d};EditorUi.prototype.getHtml=function(d,f,l,u,A,B){B=null!=B?B:!0;var F=null,M=EditorUi.drawHost+"/js/embed-static.min.js";if(null!=f){F=B?f.getGraphBounds():f.getBoundingBox(f.getSelectionCells());var O=f.view.scale;B=Math.floor(F.x/O-f.view.translate.x);O=Math.floor(F.y/O-f.view.translate.y);F=f.background;null==A&&(f=this.getBasenames().join(";"),0<f.length&&(M=EditorUi.drawHost+"/embed.js?s="+f));d.setAttribute("x0", B);d.setAttribute("y0",O)}null!=d&&(d.setAttribute("pan","1"),d.setAttribute("zoom","1"),d.setAttribute("resize","0"),d.setAttribute("fit","0"),d.setAttribute("border","20"),d.setAttribute("links","1"),null!=u&&d.setAttribute("edit",u));null!=A&&(A=A.replace(/&/g,"&amp;"));d=null!=d?Graph.zapGremlins(mxUtils.getXml(d)):"";u=Graph.compress(d);Graph.decompress(u)!=d&&(u=encodeURIComponent(d));return(null==A?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+ "<!DOCTYPE html>\n<html"+(null!=A?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+(null==A?null!=l?"<title>"+mxUtils.htmlEntities(l)+"</title>\n":"":"<title>draw.io</title>\n")+(null!=A?'<meta http-equiv="refresh" content="0;URL=\''+A+"'\"/>\n":"")+"</head>\n<body"+(null==A&&null!=F&&F!=mxConstants.NONE?' style="background-color:'+F+';">':">")+'\n<div class="mxgraph" style="position:relative;overflow:auto;width:100%;">\n<div style="width:1px;height:1px;overflow:hidden;">'+u+"</div>\n</div>\n"+ (null==A?'<script type="text/javascript" src="'+M+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+A+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.getHtml2=function(d,f,l,u,A){f=window.DRAWIO_VIEWER_URL||EditorUi.drawHost+"/js/viewer-static.min.js";null!=A&&(A=A.replace(/&/g,"&amp;"));d={highlight:"#0000ff",nav:this.editor.graph.foldingEnabled,resize:!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
V,[K[S]])}}R&&this.setCellStyles(mxConstants.STYLE_PERIMETER,L,[K[S]])}}finally{this.model.endUpdate()}};Graph.prototype.isFastZoomEnabled=function(){return"nocss"!=urlParams.zoom&&!mxClient.NO_FO&&!mxClient.IS_EDGE&&!this.useCssTransforms&&(this.isCssTransformsSupported()||mxClient.IS_IOS)};Graph.prototype.isCssTransformsSupported=function(){return this.dialect==mxConstants.DIALECT_SVG&&!mxClient.NO_FO&&(!this.lightbox||!mxClient.IS_SF)};Graph.prototype.getCellAt=function(E,K,S,G,L,R){this.useCssTransforms&& (E=E/this.currentScale-this.currentTranslate.x,K=K/this.currentScale-this.currentTranslate.y);return this.getScaledCellAt.apply(this,arguments)};Graph.prototype.getScaledCellAt=function(E,K,S,G,L,R){G=null!=G?G:!0;L=null!=L?L:!0;null==S&&(S=this.getCurrentRoot(),null==S&&(S=this.getModel().getRoot()));if(null!=S)for(var V=this.model.getChildCount(S)-1;0<=V;V--){var d=this.model.getChildAt(S,V),f=this.getScaledCellAt(E,K,d,G,L,R);if(null!=f)return f;if(this.isCellVisible(d)&&(L&&this.model.isEdge(d)||
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.initClipboard=function(){var b=this,e=mxClipboard.cut;mxClipboard.cut=function(q){q.cellEditor.isContentEditing()?document.execCommand("cut",!1,null):e.apply(this,arguments);b.updatePasteActionStates()};mxClipboard.copy=function(q){var E=null;if(q.cellEditor.isContentEditing())document.execCommand("copy",!1,null);else{E=E||q.getSelectionCells();E=q.getExportableCells(q.model.getTopmostCells(E));for(var K={},S=q.createCellLookup(E),G=q.cloneCells(E,null,K),L=new mxGraphModel,R=L.getChildAt(L.getRoot(), 0),V=0;V<G.length;V++){L.add(R,G[V]);var d=q.view.getState(E[V]);if(null!=d){var f=q.getCellGeometry(G[V]);null!=f&&f.relative&&!L.isEdge(E[V])&&null==S[mxObjectIdentity.get(L.getParent(E[V]))]&&(f.offset=null,f.relative=!1,f.x=d.x/d.view.scale-d.view.translate.x,f.y=d.y/d.view.scale-d.view.translate.y)}}q.updateCustomLinks(q.createCellMapping(K,S),G);mxClipboard.insertCount=1;mxClipboard.setCells(G)}b.updatePasteActionStates();return E};var g=mxClipboard.paste;mxClipboard.paste=function(q){var E= null;q.cellEditor.isContentEditing()?document.execCommand("paste",!1,null):E=g.apply(this,arguments);b.updatePasteActionStates();return E};var n=this.editor.graph.cellEditor.startEditing;this.editor.graph.cellEditor.startEditing=function(){n.apply(this,arguments);b.updatePasteActionStates()};var y=this.editor.graph.cellEditor.stopEditing;this.editor.graph.cellEditor.stopEditing=function(q,E){y.apply(this,arguments);b.updatePasteActionStates()};this.updatePasteActionStates()};
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
f.handleFileError(null,!0):this.spinner.spin(document.body,mxResources.get("updatingDocument"))&&(f.clearAutosave(),this.editor.setStatus(""),d?f.reloadFile(mxUtils.bind(this,function(){f.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(l){f.handleFileError(l,!0)})):f.synchronizeFile(mxUtils.bind(this,function(){f.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(l){f.handleFileError(l,!0)}))))};EditorUi.prototype.getFileData=function(d,f,l,u,A,B,F, M,O,H,ja){A=null!=A?A:!0;B=null!=B?B:!1;H=null!=H?H:!Editor.defaultCompressed;var da=this.editor.graph;if(f||!d&&null!=O&&/(\.svg)$/i.test(O.getTitle())){var ca=null!=da.themes&&"darkTheme"==da.defaultThemeName;if(ca||null!=this.pages&&this.currentPage!=this.pages[0]){var ia=da.getGlobalVariable;da=this.createTemporaryGraph(ca?da.getDefaultStylesheet():da.getStylesheet());da.setBackgroundImage=this.editor.graph.setBackgroundImage;da.background=this.editor.graph.background;var ma=null!=this.pages? this.pages[0]:null;null==ma||this.currentPage==ma?da.setBackgroundImage(this.editor.graph.backgroundImage):null!=ma.viewState&&null!=ma.viewState&&da.setBackgroundImage(ma.viewState.backgroundImage);da.getGlobalVariable=function(aa){return"page"==aa&&null!=ma?ma.getName():"pagenumber"==aa?1:ia.apply(this,arguments)};document.body.appendChild(da.container);null!=ma&&da.model.setRoot(ma.root)}}F=null!=F?F:this.getXmlFileData(A,B,H,ja);O=null!=O?O:this.getCurrentFile();d=this.createFileData(F,da,O,window.location.href, d,f,l,u,A,M,H);da!=this.editor.graph&&da.container.parentNode.removeChild(da.container);return d};EditorUi.prototype.getHtml=function(d,f,l,u,A,B){B=null!=B?B:!0;var F=null,M=EditorUi.drawHost+"/js/embed-static.min.js";if(null!=f){F=B?f.getGraphBounds():f.getBoundingBox(f.getSelectionCells());var O=f.view.scale;B=Math.floor(F.x/O-f.view.translate.x);O=Math.floor(F.y/O-f.view.translate.y);F=f.background;null==A&&(f=this.getBasenames().join(";"),0<f.length&&(M=EditorUi.drawHost+"/embed.js?s="+f));d.setAttribute("x0",
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 b=new mxObjectCodec(new ChangeGridColor,["ui"]);b.beforeDecode=function(e,g,n){n.ui=e.ui;return g};mxCodecRegistry.register(b)})();(function(){EditorUi.VERSION="21.6.2";EditorUi.compactUi="atlas"!=Editor.currentTheme;Editor.isDarkMode()&&(mxGraphView.prototype.gridColor=mxGraphView.prototype.defaultDarkGridColor);EditorUi.enableLogging="1"!=urlParams.stealth&&"1"!=urlParams.lockdown&&(/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname))&&"support.draw.io"!=window.location.hostname;EditorUi.drawHost=window.DRAWIO_BASE_URL;EditorUi.lightboxHost=window.DRAWIO_LIGHTBOX_URL;
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.addSplitHandler=function(b,e,g,n){function y(R){if(null!=E){var V=new mxPoint(mxEvent.getClientX(R),mxEvent.getClientY(R));n(Math.max(0,K+(e?V.x-E.x:E.y-V.y)-g));mxEvent.consume(R);K!=L()&&(S=!0,G=null)}}function q(R){y(R);E=K=null}var E=null,K=null,S=!0,G=null;mxClient.IS_POINTER&&(b.style.touchAction="none");var L=mxUtils.bind(this,function(){var R=parseInt(e?b.style.left:b.style.bottom);e||(R=R+g-this.footerHeight);return R});mxEvent.addGestureListeners(b,function(R){E=new mxPoint(mxEvent.getClientX(R),
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.editor.getEditBlankUrl=function(P){P=null!=P?P:"";"1"==urlParams.dev&&(P+=(0<P.length?"&":"?")+"dev=1");return F.apply(this,arguments)};var M=f.addClickHandler;f.addClickHandler=function(P,U,k){var z=U;U=function(J,W){if(null==W){var T=mxEvent.getSource(J);"a"==T.nodeName.toLowerCase()&&(W=T.getAttribute("href"))}null!=W&&f.isCustomLink(W)&&(mxEvent.isTouchEvent(J)||!mxEvent.isPopupTrigger(J))&&f.customLinkClicked(W)&&mxEvent.consume(J);null!=z&&z(J,W)};M.call(this,P,U,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
"...",d[A])})))};EditorUi.prototype.installFormatToolbar=function(V){var d=this.editor.graph,f=document.createElement("div");f.style.cssText="position:absolute;top:10px;z-index:1;border-radius:4px;box-shadow:0px 0px 3px 1px #d1d1d1;padding:6px;white-space:nowrap;background-color:#fff;transform:translate(-50%, 0);left:50%;";d.getSelectionModel().addListener(mxEvent.CHANGE,mxUtils.bind(this,function(l,u){0<d.getSelectionCount()?(V.appendChild(f),f.innerHTML="Selected: "+d.getSelectionCount()):null!= f.parentNode&&f.parentNode.removeChild(f)}))};var L=!1;EditorUi.prototype.initFormatWindow=function(){if(!L&&null!=this.formatWindow){L=!0;var V=this.formatWindow.window.toggleMinimized,d=240;this.formatWindow.window.toggleMinimized=function(){V.apply(this,arguments);this.minimized?(d=parseInt(this.div.style.width),this.div.style.width="140px",this.table.style.width="140px",this.div.style.left=parseInt(this.div.style.left)+d-140+"px"):(this.div.style.width=d+"px",this.table.style.width=this.div.style.width,
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
".sketch-configuration",Editor.settingsKey=".sketch-config")};EditorUi.initTheme();EditorUi.prototype.showImageDialog=function(d,f,l,u,A,B,F){d=new ImageDialog(this,d,f,l,u,A,B,F);this.showDialog(d.container,Graph.fileSupport?480:360,Graph.fileSupport?200:90,!0,!0);d.init()};EditorUi.prototype.showLocalStorageDialog=function(d,f,l,u,A,B){var F=localStorage.getItem(f);d=new TextareaDialog(this,d,null!=F?JSON.stringify(JSON.parse(F),null,2):"",mxUtils.bind(this,function(M){if(null!=M)try{if(null!=B&&
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
mxGraphHandler.prototype.shouldRemoveCellsFromParent=function(E,K,S){for(var G=0;G<K.length;G++){if(this.graph.isTableCell(K[G])||this.graph.isTableRow(K[G]))return!1;if(this.graph.getModel().isVertex(K[G])){var L=this.graph.getCellGeometry(K[G]);if(null!=L&&L.relative)return!1}}return e.apply(this,arguments)};var g=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var E=g.apply(this,arguments);E.intersects=mxUtils.bind(this,function(K,S){return this.isConnecting()? !0:mxCellMarker.prototype.intersects.apply(E,arguments)});return E};mxGraphView.prototype.createBackgroundPageShape=function(E){return new mxRectangleShape(E,"#ffffff",this.graph.defaultPageBorderColor)};mxGraphView.prototype.getBackgroundPageBounds=function(){var E=this.getGraphBounds(),K=0<E.width?E.x/this.scale-this.translate.x:0,S=0<E.height?E.y/this.scale-this.translate.y:0,G=this.graph.pageFormat,L=this.graph.pageScale,R=G.width*L;G=G.height*L;L=Math.floor(Math.min(0,K)/R);var V=Math.floor(Math.min(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(L){y.apply(this,arguments);this.graph.model.isEdge(L.cell)&&1!=L.style[mxConstants.STYLE_CURVED]&&this.updateLineJumps(L)};mxGraphView.prototype.updateLineJumps=function(L){var R=L.absolutePoints;if(Graph.lineJumpsEnabled){var V=null!=L.routedPoints,d=null;if(null!=R&&null!=this.validEdges&&"none"!==mxUtils.getValue(L.style,"jumpStyle","none")){var f=function(ia,ma,aa){var la=new mxPoint(ma,aa);la.type=ia;d.push(la);la=null!=L.routedPoints?L.routedPoints[d.length-1]:null;return null==la|| la.type!=ia||la.x!=ma||la.y!=aa},l=.5*this.scale;V=!1;d=[];for(var u=0;u<R.length-1;u++){for(var A=R[u+1],B=R[u],F=[],M=R[u+2];u<R.length-2&&mxUtils.ptSegDistSq(B.x,B.y,M.x,M.y,A.x,A.y)<1*this.scale*this.scale;)A=M,u++,M=R[u+2];V=f(0,B.x,B.y)||V;for(var O=0;O<this.validEdges.length;O++){var H=this.validEdges[O],ja=H.absolutePoints;if(null!=ja&&mxUtils.intersects(L,H)&&"1"!=H.style.noJump)for(H=0;H<ja.length-1;H++){var da=ja[H+1],ca=ja[H];for(M=ja[H+2];H<ja.length-2&&mxUtils.ptSegDistSq(ca.x,ca.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
function V(){mxShape.call(this)}function d(c,m,x,p){mxShape.call(this);this.bounds=c;this.fill=m;this.stroke=x;this.strokewidth=null!=p?p:1}function f(){mxActor.call(this)}function l(){mxCylinder.call(this)}function u(){mxCylinder.call(this)}function A(){mxActor.call(this)}function B(){mxActor.call(this)}function F(){mxActor.call(this)}function M(){mxActor.call(this)}function O(){mxActor.call(this)}function H(){mxActor.call(this)}function ja(){mxActor.call(this)}function da(c,m){this.canvas=c;this.canvas.setLineJoin("round");
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.height;if(0==da&&0==ca){var ia=O.result,ma=ia.indexOf(","),aa=decodeURIComponent(escape(atob(ia.substring(ma+1)))),la=mxUtils.parseXml(aa).getElementsByTagName("svg");0<la.length&&(da=parseFloat(la[0].getAttribute("width")),ca=parseFloat(la[0].getAttribute("height")))}l(O.result,da,ca)}catch(X){u(X)}};ja.src=O.result};O.onerror=function(H){u(H)}}else u(M)};F.onerror=function(M){u(M)};F.send()};EditorUi.prototype.insertAsPreText=function(d,f,l){var u=this.editor.graph,A=null;u.getModel().beginUpdate();
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
f)};EditorUi.prototype.embedExtFonts=function(d){EditorUi.logEvent("SHOULD NOT BE CALLED: embedExtFonts");return this.editor.embedExtFonts(d)};EditorUi.prototype.exportToCanvas=function(d,f,l,u,A,B,F,M,O,H,ja,da,ca,ia,ma,aa){EditorUi.logEvent("SHOULD NOT BE CALLED: exportToCanvas");return this.editor.exportToCanvas(d,f,l,u,A,B,F,M,O,H,ja,da,ca,ia,ma,aa)};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
EditorUi.prototype.showError=function(b,e,g,n,y,q,E,K,S,G,L,R,V){b=new ErrorDialog(this,b,e,g||mxResources.get("ok"),n,y,q,E,R,K,S);e=Math.ceil(null!=e?e.length/50:1);this.showDialog(b.container,G||340,L||100+20*e,!0,!1,V);b.init()};EditorUi.prototype.showDialog=function(b,e,g,n,y,q,E,K,S,G){this.editor.graph.tooltipHandler.resetTimer();this.editor.graph.tooltipHandler.hideTooltip();null==this.dialogs&&(this.dialogs=[]);this.dialog=new Dialog(this,b,e,g,n,y,q,E,K,S,G);this.dialogs.push(this.dialog)};
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
mxEvent.isShiftDown(R)?n.gridSize:null,!0)}:function(){e(R.keyCode,mxEvent.isShiftDown(R)?n.gridSize:null)}}return S.apply(this,arguments)};y.bindAction=mxUtils.bind(this,function(R,V,d,f){var l=this.actions.get(d);null!=l&&(d=function(){l.isEnabled()&&l.funct.apply(this,arguments)},V?f?y.bindControlShiftKey(R,d):y.bindControlKey(R,d):f?y.bindShiftKey(R,d):y.bindKey(R,d))});var G=this,L=y.escape;y.escape=function(R){L.apply(this,arguments)};y.enter=function(){};y.bindControlShiftKey(36,function(){n.exitGroup()});
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("notInOffline")):this.parseFileData(H,mxUtils.bind(this,function(ta){4==ta.readyState&&(200<=ta.status&&299>=ta.status&&"<mxGraphModel"==ta.responseText.substring(0,13)?Pa(ta.responseText,O):this.handleError({message:413==ta.status?mxResources.get("diagramTooLarge"):mxResources.get("unknownError")}))}),""):null!=H&&"function"===typeof H.substring&&this.isLucidChartData(H)?this.convertLucidChart(H,mxUtils.bind(this,function(ta){Pa(ta)}),mxUtils.bind(this,function(ta){this.handleError(ta)})): null==H||"object"!==typeof H||null==H.format||null==H.data&&null==H.url?(H=da(H),Pa(H,O)):this.loadDescriptor(H,mxUtils.bind(this,function(ta){Pa(Qa(),O)}),mxUtils.bind(this,function(ta){this.handleError(ta,mxResources.get("errorLoadingFile"))}))}}));var F=window.opener||window.parent;B="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";F.postMessage(B,"*");if("json"==urlParams.proto){var M=this.editor.graph.openLink;this.editor.graph.openLink=function(O,H,ja){M.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(d,f,l){var u=this,A=mxUtils.bind(this,function(){this.loadingExtensions=!1;"undefined"!==typeof JSZip?JSZip.loadAsync(d).then(function(B){if(mxUtils.isEmptyObject(B.files))l();else{var F=0,M,O=!1;B.forEach(function(H,ja){H=ja.name.toLowerCase();"diagram/diagram.xml"==H?(O=!0,ja.async("string").then(function(da){0==da.indexOf("<mxfile ")?f(da):l()})):0==H.indexOf("versions/")&&(H=parseInt(H.substr(9)),H>F&&(F=H,M=ja))});0<F?M.async("string").then(function(H){(new XMLHttpRequest).upload&&u.isRemoteFileFormat(H, d.name)?u.isOffline()?u.showError(mxResources.get("error"),mxResources.get("notInOffline"),null,l):u.parseFileData(H,mxUtils.bind(this,function(ja){4==ja.readyState&&(200<=ja.status&&299>=ja.status?f(ja.responseText):l())}),d.name):l()}):O||l()}},function(B){l(B)}):l()});"undefined"!==typeof JSZip||this.loadingExtensions||this.isOffline(!0)?A():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",A,null,null,null,l))};EditorUi.prototype.importFile=function(d,f,l,u,A,B,F,M,O,H,ja,da){H=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.setAttribute("title",mxResources.get("create")+"...");mxEvent.addListener(O,"click",function(ca){function ia(){K(ma,aa,function(la){G(aa);b.addComment(la,function(X){la.id=X;ja.push(la);R(aa)},function(X){L(aa);ia();b.handleError(X,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})},!0)}var ma=b.newComment("",b.getCurrentUser()),aa=V(ma,ja,null,0);ia();ca.preventDefault();mxEvent.consume(ca)});M.appendChild(O)}O=A.cloneNode();O.innerHTML='<img class="geAdaptiveAsset" src="'+
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.clearDefaultStyle=function(){y.currentEdgeStyle=mxUtils.clone(y.defaultEdgeStyle);y.currentVertexStyle=mxUtils.clone(y.defaultVertexStyle);G=L=!1;this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[]))};var R=["fontFamily","fontSource","fontSize","fontColor"];for(e=0;e<R.length;e++)0>mxUtils.indexOf(E,R[e])&&E.push(R[e]);var V="edgeStyle startArrow startFill startSize endArrow endFill endSize".split(" "),d=[["startArrow","startFill","endArrow","endFill"],["startSize",
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.graph.isCellSelected(G);return L};mxPopupMenuHandler.prototype.getCellForPopupEvent=function(E){E=E.getCell();for(var K=this.graph.getModel(),S=K.getParent(E),G=this.graph.view.getState(S),L=this.graph.isCellSelected(E);null!=G&&(K.isVertex(S)||K.isEdge(S));){var R=this.graph.isCellSelected(S);L=L||R;if(R||!L&&(this.graph.isTableCell(E)||this.graph.isTableRow(E)))E=S;S=K.getParent(S)}return E}})();EditorUi=function(b,e,g){mxEventSource.call(this);this.destroyFunctions=[];this.editor=b||new Editor;this.container=e||document.body;var n=this,y=this.editor.graph;y.lightbox=g;var q=y.getGraphBounds;y.getGraphBounds=function(){var P=q.apply(this,arguments),U=this.backgroundImage;if(null!=U&&null!=U.width&&null!=U.height){var k=this.view.translate,z=this.view.scale;P=mxRectangle.fromRectangle(P);P.add(new mxRectangle((k.x+U.x)*z,(k.y+U.y)*z,U.width*z,U.height*z))}return P};y.useCssTransforms&&(this.lazyZoomDelay=
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.diagramContainer.offsetHeight-this.bottomResizer.offsetHeight)/2+"px"}this.bottomResizer.style.visibility=Editor.inlineFullscreen?"hidden":"";this.rightResizer.style.visibility=this.bottomResizer.style.visibility;f.style.visibility="";d.style.visibility=""};EditorUi.prototype.doSetSketchMode=function(d){Editor.sketchMode!=d&&(Editor.sketchMode=d,this.updateDefaultStyles())};EditorUi.prototype.updateDefaultStyles=function(){var d=this.editor.graph;d.defaultVertexStyle=mxUtils.clone(Graph.prototype.defaultVertexStyle);
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(d){return null};EditorUi.prototype.getTitleForService=function(d){return mxResources.get(d)};EditorUi.prototype.pickFolder=function(d,f,l){f(null)};EditorUi.prototype.exportSvg=function(d,f,l,u,A,B,F,M,O,H,ja,da,ca,ia){if(this.spinner.spin(document.body,mxResources.get("export")))try{var ma=this.editor.graph.isSelectionEmpty();l=null!=l?l:ma;var aa=f?null:this.editor.graph.background;aa==mxConstants.NONE&&(aa=null);null==aa&&0==f&&(aa="dark"!=ja||Editor.enableSvgDarkMode?"#ffffff":Editor.darkColor);
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
mxGraph.prototype.getBoundingBoxFromGeometry=function(a,b){b=null!=b?b:!1;var c=null;if(null!=a)for(var d=0;d<a.length;d++)if(b||this.model.isVertex(a[d])){var e=this.getCellGeometry(a[d]);if(null!=e){var f=null;if(this.model.isEdge(a[d])){f=function(l){null!=l&&(null==g?g=new mxRectangle(l.x,l.y,0,0):g.add(new mxRectangle(l.x,l.y,0,0)))};null==this.model.getTerminal(a[d],!0)&&f(e.getTerminalPoint(!0));null==this.model.getTerminal(a[d],!1)&&f(e.getTerminalPoint(!1));e=e.points;if(null!=e&&0<e.length)for(var g= new mxRectangle(e[0].x,e[0].y,0,0),k=1;k<e.length;k++)f(e[k]);f=g}else k=this.model.getParent(a[d]),e.relative?this.model.isVertex(k)&&k!=this.view.currentRoot&&(g=this.getBoundingBoxFromGeometry([k],!1),null!=g&&(f=new mxRectangle(e.x*g.width,e.y*g.height,e.width,e.height),0<=mxUtils.indexOf(a,k)&&(f.x+=g.x,f.y+=g.y))):(f=mxRectangle.fromRectangle(e),this.model.isVertex(k)&&0<=mxUtils.indexOf(a,k)&&(g=this.getBoundingBoxFromGeometry([k],!1),null!=g&&(f.x+=g.x,f.y+=g.y))),null!=f&&null!=e.offset&& (f.x+=e.offset.x,f.y+=e.offset.y),e=this.getCurrentCellStyle(a[d]),null!=f&&(e=mxUtils.getValue(e,mxConstants.STYLE_ROTATION,0),0!=e&&(f=mxUtils.getBoundingBox(f,e)));null!=f&&(null==c?c=mxRectangle.fromRectangle(f):c.add(f))}}return c};mxGraph.prototype.refresh=function(a){this.view.clear(a,null==a);this.view.validate();this.sizeDidChange();this.fireEvent(new mxEventObject(mxEvent.REFRESH))};mxGraph.prototype.snap=function(a){this.gridEnabled&&(a=Math.round(a/this.gridSize)*this.gridSize);return a};
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(){return n.apply(this,arguments)||null!=e.shapePicker||null!=e.currentMenu};var y=b.dblClick;b.dblClick=function(S,G){if(this.isEnabled())if(null!=G||null==e.sidebar||mxEvent.isShiftDown(S)||b.isCellLocked(b.getDefaultParent()))y.apply(this,arguments);else{var L=mxUtils.convertPoint(this.container,mxEvent.getClientX(S),mxEvent.getClientY(S));mxEvent.consume(S);window.setTimeout(mxUtils.bind(this,function(){e.showShapePicker(L.x,L.y)}),30)}};if(null!=this.hoverIcons){this.hoverIcons.addListener("reset",
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.generatePlantUmlImage=function(d,f,l,u){function A(M,O,H){c1=M>>2;c2=(M&3)<<4|O>>4;c3=(O&15)<<2|H>>6;c4=H&63;r="";r+=B(c1&63);r+=B(c2&63);r+=B(c3&63);return r+=B(c4&63)}function B(M){if(10>M)return String.fromCharCode(48+M);M-=10;if(26>M)return String.fromCharCode(65+M);M-=26;if(26>M)return String.fromCharCode(97+M);M-=26;return 0==M?"-":1==M?"_":"?"}var F=new XMLHttpRequest;F.open("GET",("txt"==f?PLANT_URL+"/txt/":"png"==f?PLANT_URL+"/png/":PLANT_URL+"/svg/")+function(M){r="";
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=function(b,e,g,n,y,q){mxGraph.call(this,b,e,g,n);this.themes=y||this.defaultThemes;this.currentEdgeStyle=mxUtils.clone(this.defaultEdgeStyle);this.currentVertexStyle=mxUtils.clone(this.defaultVertexStyle);this.standalone=null!=q?q:!1;b=this.baseUrl;e=b.indexOf("//");this.domainPathUrl=this.domainUrl="";0<e&&(e=b.indexOf("/",e+2),0<e&&(this.domainUrl=b.substring(0,e)),e=b.lastIndexOf("/"),0<e&&(this.domainPathUrl=b.substring(0,e+1)));this.isHtmlLabel=function(X){X=this.getCurrentCellStyle(X); return null!=X?"1"==X.html||"wrap"==X[mxConstants.STYLE_WHITE_SPACE]:!1};if(this.immediateHandling){var E=null,K=null,S=null,G=null,L=!1,R=!1;this.addListener(mxEvent.FIRE_MOUSE_EVENT,mxUtils.bind(this,function(X,P){if("mouseDown"==P.getProperty("eventName")&&this.isEnabled()){X=P.getProperty("event");var U=X.getState();P=this.view.scale;if(!mxEvent.isAltDown(X.getEvent())&&null!=U&&(R=this.isCellSelected(U.cell),!this.panningHandler.isActive()&&!mxEvent.isControlDown(X.getEvent()))){var k=this.selectionCellsHandler.getHandler(U.cell);
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
(E=E/this.currentScale-this.currentTranslate.x,K=K/this.currentScale-this.currentTranslate.y);return this.getScaledCellAt.apply(this,arguments)};Graph.prototype.getScaledCellAt=function(E,K,S,G,L,R){G=null!=G?G:!0;L=null!=L?L:!0;null==S&&(S=this.getCurrentRoot(),null==S&&(S=this.getModel().getRoot()));if(null!=S)for(var V=this.model.getChildCount(S)-1;0<=V;V--){var d=this.model.getChildAt(S,V),f=this.getScaledCellAt(E,K,d,G,L,R);if(null!=f)return f;if(this.isCellVisible(d)&&(L&&this.model.isEdge(d)|| G&&this.model.isVertex(d))&&(f=this.view.getState(d),null!=f&&(null==R||!R(f,E,K))&&this.intersects(f,E,K)))return d}return null};Graph.prototype.isRecursiveVertexResize=function(E){return!this.isSwimlane(E.cell)&&0<this.model.getChildCount(E.cell)&&!this.isCellCollapsed(E.cell)&&"1"==mxUtils.getValue(E.style,"recursiveResize","1")&&null==mxUtils.getValue(E.style,"childLayout",null)};Graph.prototype.getAbsoluteParent=function(E){for(var K=this.getCellGeometry(E);null!=K&&K.relative;)E=this.getModel().getParent(E),
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 ErrorDialog=function(b,e,g,n,y,q,E,K,S,G,L){S=null!=S?S:!0;var R=document.createElement("div");R.style.textAlign="center";if(null!=e){var V=document.createElement("div");V.style.padding="0px";V.style.margin="0px";V.style.fontSize="18px";V.style.paddingBottom="16px";V.style.marginBottom="10px";V.style.borderBottom="1px solid #c0c0c0";V.style.color="gray";V.style.whiteSpace="nowrap";V.style.textOverflow="ellipsis";V.style.overflow="hidden";mxUtils.write(V,e);V.setAttribute("title",e);R.appendChild(V)}e= document.createElement("div");e.style.lineHeight="1.2em";e.style.padding="6px";"string"===typeof g&&(g=g.replace(/\n/g,"<br/>"));e.innerHTML=g;R.appendChild(e);g=document.createElement("div");g.style.marginTop="12px";g.style.textAlign="center";null!=q&&(e=mxUtils.button(mxResources.get("tryAgain"),function(){b.hideDialog();q()}),e.className="geBtn",g.appendChild(e),g.style.textAlign="center");null!=G&&(G=mxUtils.button(G,function(){null!=L&&L()}),G.className="geBtn",g.appendChild(G));var d=mxUtils.button(n, function(){S&&b.hideDialog();null!=y&&y()});d.className="geBtn";g.appendChild(d);null!=E&&(n=mxUtils.button(E,function(){S&&b.hideDialog();null!=K&&K()}),n.className="geBtn gePrimaryBtn",g.appendChild(n));this.init=function(){d.focus()};R.appendChild(g);this.container=R},PrintDialog=function(b,e){this.create(b,e)};
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
S+'" xmlns="'+mxConstants.NS_SVG+'"><defs><pattern id="grid" width="'+S+'" height="'+S+'" patternUnits="userSpaceOnUse"><path d="'+G.join(" ")+'" fill="none" stroke="'+E+'" opacity="0.2" stroke-width="1"/><path d="M '+S+" 0 L 0 0 0 "+S+'" fill="none" stroke="'+E+'" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(#grid)"/></svg>'};var b=mxGraph.prototype.panGraph;mxGraph.prototype.panGraph=function(E,K){b.apply(this,arguments);if(null!=this.shiftPreview1){var S=this.view.canvas; null!=S.ownerSVGElement&&(S=S.ownerSVGElement);var G=this.gridSize*this.view.scale*this.view.gridSteps;G=-Math.round(G-mxUtils.mod(this.view.translate.x*this.view.scale+E,G))+"px "+-Math.round(G-mxUtils.mod(this.view.translate.y*this.view.scale+K,G))+"px";S.style.backgroundPosition=G}};mxGraph.prototype.updatePageBreaks=function(E,K,S){var G=this.view.scale,L=this.view.translate,R=this.pageFormat,V=G*this.pageScale,d=this.view.getBackgroundPageBounds();K=d.width;S=d.height;var f=new mxRectangle(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
this.editor.getEditBlankUrl=function(P){P=null!=P?P:"";"1"==urlParams.dev&&(P+=(0<P.length?"&":"?")+"dev=1");return F.apply(this,arguments)};var M=f.addClickHandler;f.addClickHandler=function(P,U,k){var z=U;U=function(J,W){if(null==W){var T=mxEvent.getSource(J);"a"==T.nodeName.toLowerCase()&&(W=T.getAttribute("href"))}null!=W&&f.isCustomLink(W)&&(mxEvent.isTouchEvent(J)||!mxEvent.isPopupTrigger(J))&&f.customLinkClicked(W)&&mxEvent.consume(J);null!=z&&z(J,W)};M.call(this,P,U,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
qa.className="geCommentAction";var ra=document.createElement("a");ra.className="geCommentActionLnk";mxUtils.write(ra,Z);qa.appendChild(ra);mxEvent.addListener(ra,"click",function(pa){ba(pa,ca);pa.preventDefault();mxEvent.consume(pa)});T.appendChild(qa);ha&&(qa.style.display="none")}function P(){function Z(qa){ba.push(ha);if(null!=qa.replies)for(var ra=0;ra<qa.replies.length;ra++)ha=ha.nextSibling,Z(qa.replies[ra])}var ba=[],ha=k;Z(ca);return{pdiv:ha,replies:ba}}function U(Z,ba,ha,qa,ra){function pa(){G(za); ca.addReply(Ba,function(Ma){Ba.id=Ma;ca.replies.push(Ba);R(za);ha&&ha()},function(Ma){xa();L(za);b.handleError(Ma,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))},qa,ra)}function xa(){K(Ba,za,function(Ma){pa()},!0)}var Ca=P().pdiv,Ba=b.newComment(Z,b.getCurrentUser());Ba.pCommentId=ca.id;null==ca.replies&&(ca.replies=[]);var za=V(Ba,ca.replies,Ca,aa+1);ba?xa():pa()}if(la||!ca.isResolved){F.style.display="none";var k=document.createElement("div");k.className="geCommentContainer";
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=this.getCellGeometry(E);return E};Graph.prototype.isPart=function(E){return"1"==mxUtils.getValue(this.getCurrentCellStyle(E),"part","0")||this.isTableCell(E)||this.isTableRow(E)};Graph.prototype.getCompositeParents=function(E){for(var K=new mxDictionary,S=[],G=0;G<E.length;G++){var L=this.getCompositeParent(E[G]);this.isTableCell(L)&&(L=this.graph.model.getParent(L));this.isTableRow(L)&&(L=this.graph.model.getParent(L));null==L||K.get(L)||(K.put(L,!0),S.push(L))}return S};Graph.prototype.getReferenceTerminal=
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,[K[S]])}}R&&this.setCellStyles(mxConstants.STYLE_PERIMETER,L,[K[S]])}}finally{this.model.endUpdate()}};Graph.prototype.isFastZoomEnabled=function(){return"nocss"!=urlParams.zoom&&!mxClient.NO_FO&&!mxClient.IS_EDGE&&!this.useCssTransforms&&(this.isCssTransformsSupported()||mxClient.IS_IOS)};Graph.prototype.isCssTransformsSupported=function(){return this.dialect==mxConstants.DIALECT_SVG&&!mxClient.NO_FO&&(!this.lightbox||!mxClient.IS_SF)};Graph.prototype.getCellAt=function(E,K,S,G,L,R){this.useCssTransforms&&
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
new mxRectangle(0,0,0,Math.max(0,Math.min(c.height,parseFloat(mxUtils.getValue(m.style,"size",ma.prototype.size))*m.view.scale))),m.style),m,x,p)};mxStyleRegistry.putValue("calloutPerimeter",mxPerimeter.CalloutPerimeter);mxPerimeter.ParallelogramPerimeter=function(c,m,x,p){var t="0"!=mxUtils.getValue(m.style,"fixedSize","0"),C=t?M.prototype.fixedSize:M.prototype.size;null!=m&&(C=mxUtils.getValue(m.style,"size",C));t&&(C*=m.view.scale);var D=c.x,fa=c.y,I=c.width,va=c.height;m=null!=m?mxUtils.getValue(m.style, mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;m==mxConstants.DIRECTION_NORTH||m==mxConstants.DIRECTION_SOUTH?(t=t?Math.max(0,Math.min(va,C)):va*Math.max(0,Math.min(1,C)),fa=[new mxPoint(D,fa),new mxPoint(D+I,fa+t),new mxPoint(D+I,fa+va),new mxPoint(D,fa+va-t),new mxPoint(D,fa)]):(t=t?Math.max(0,Math.min(.5*I,C)):I*Math.max(0,Math.min(1,C)),fa=[new mxPoint(D+t,fa),new mxPoint(D+I,fa),new mxPoint(D+I-t,fa+va),new mxPoint(D,fa+va),new mxPoint(D+t,fa)]);va=c.getCenterX(); c=c.getCenterY();c=new mxPoint(va,c);p&&(x.x<D||x.x>D+I?c.y=x.y:c.x=x.x);return mxUtils.getPerimeterPoint(fa,c,x)};mxStyleRegistry.putValue("parallelogramPerimeter",mxPerimeter.ParallelogramPerimeter);mxPerimeter.TrapezoidPerimeter=function(c,m,x,p){var t="0"!=mxUtils.getValue(m.style,"fixedSize","0"),C=t?O.prototype.fixedSize:O.prototype.size;null!=m&&(C=mxUtils.getValue(m.style,"size",C));t&&(C*=m.view.scale);var D=c.x,fa=c.y,I=c.width,va=c.height;m=null!=m?mxUtils.getValue(m.style,mxConstants.STYLE_DIRECTION,
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.readGraphModelFromClipboardWithType=function(b,e){navigator.clipboard.read().then(mxUtils.bind(this,function(g){if(null!=g&&0<g.length&&"html"==e&&0<=mxUtils.indexOf(g[0].types,"text/html"))g[0].getType("text/html").then(mxUtils.bind(this,function(n){n.text().then(mxUtils.bind(this,function(y){try{var q=this.parseHtmlData(y),E="text/plain"!=q.getAttribute("data-type")?q.innerHTML:mxUtils.trim(null==q.innerText?mxUtils.getTextContent(q):q.innerText);try{var K=E.lastIndexOf("%3E"); 0<=K&&K<E.length-3&&(E=E.substring(0,K+3))}catch(L){}try{var S=q.getElementsByTagName("span"),G=null!=S&&0<S.length?mxUtils.trim(decodeURIComponent(S[0].textContent)):decodeURIComponent(E);this.isCompatibleString(G)&&(E=G)}catch(L){}}catch(L){}b(this.isCompatibleString(E)?E:null)}))["catch"](function(y){b(null)})}))["catch"](function(n){b(null)});else if(null!=g&&0<g.length&&"text"==e&&0<=mxUtils.indexOf(g[0].types,"text/plain"))g[0].getType("text/plain").then(function(n){n.text().then(function(y){b(y)})["catch"](function(){b(null)})})["catch"](function(){b(null)}); else b(null)}))["catch"](function(g){b(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
E.container.scrollLeft;this.scrollTop=E.container.scrollTop},mouseMove:function(da,ca){},mouseUp:function(da,ca){mxEvent.isTouchEvent(ca.getEvent())&&Math.abs(this.scrollLeft-E.container.scrollLeft)<K&&Math.abs(this.scrollTop-E.container.scrollTop)<K&&Math.abs(this.startX-ca.getGraphX())<K&&Math.abs(this.startY-ca.getGraphY())<K&&(0<parseFloat(e.style.opacity||0)?y():q(30))}})}for(var S=this.toolbarItems,G=0,L=mxUtils.bind(this,function(da,ca,ia,ma){da=this.createToolbarButton(da,ca,ia,ma);e.appendChild(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
for(i=0;i<M.length;i+=3)r=i+2==M.length?r+A(M.charCodeAt(i),M.charCodeAt(i+1),0):i+1==M.length?r+A(M.charCodeAt(i),0,0):r+A(M.charCodeAt(i),M.charCodeAt(i+1),M.charCodeAt(i+2));return r}(Graph.arrayBufferToString(pako.deflateRaw(d))),!0);"txt"!=f&&(F.responseType="blob");F.onload=function(M){if(200<=this.status&&300>this.status)if("txt"==f)l(this.response);else{var O=new FileReader;O.readAsDataURL(this.response);O.onloadend=function(H){var ja=new Image;ja.onload=function(){try{var da=ja.width,ca= ja.height;if(0==da&&0==ca){var ia=O.result,ma=ia.indexOf(","),aa=decodeURIComponent(escape(atob(ia.substring(ma+1)))),la=mxUtils.parseXml(aa).getElementsByTagName("svg");0<la.length&&(da=parseFloat(la[0].getAttribute("width")),ca=parseFloat(la[0].getAttribute("height")))}l(O.result,da,ca)}catch(X){u(X)}};ja.src=O.result};O.onerror=function(H){u(H)}}else u(M)};F.onerror=function(M){u(M)};F.send()};EditorUi.prototype.insertAsPreText=function(d,f,l){var u=this.editor.graph,A=null;u.getModel().beginUpdate();
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(la){try{f(la.target.result)}catch(X){M({message:mxResources.get("errorLoadingFile")})}});aa.readAsText(ma)}else this.doImportVisio(ma,f,M,u)}catch(la){M(la)}else try{""==ia.responseType||"text"==ia.responseType?M({message:ia.responseText}):(aa=new FileReader,aa.onload=function(){try{M({message:JSON.parse(aa.result).Message})}catch(la){M(la)}},aa.readAsText(ia.response))}catch(la){M({})}});ia.send(H)}else if(F.clear())try{this.doImportVisio(d,f,M,u)}catch(ma){M(ma)}}else M({message:mxResources.get("serviceUnavailableOrBlocked")})});
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.toolbar.edgeStyleMenu.setEnabled(d));this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};EditorUi.prototype.scheduleSanityCheck=function(){};EditorUi.prototype.stopSanityCheck=function(){};EditorUi.prototype.isDiagramActive=function(){var d=this.getCurrentFile();return null!=d&&d.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled()};var L=EditorUi.prototype.createSidebar;EditorUi.prototype.createSidebar=
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.generateMermaidImage(da,null,mxUtils.bind(this,function(ca,ia,ma){this.tryAndHandle(mxUtils.bind(this,function(){B.clear()&&(EditorUi.debug("EditorUi.generateOpenAiMermaidDiagram","\nprompt:",d,"\nresponse:",ja,"\nresult:",da),this.spinner.stop(),f(da,ca,ia,ma))}),M)}),M,mxUtils.bind(this,function(ca){3>u++?B.clear()&&(this.spinner.stop(),A()):M(ca)}))}),M);else{var H={message:mxResources.get("error")+" "+O.getStatus()};try{H=JSON.parse(O.getText()),H=H.error}catch(ja){}M(H)}}),M)}),l)});A()};
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
u.onreadystatechange=function(){f(u)};u.send("format=xml&filename="+encodeURIComponent(l)+"&data="+encodeURIComponent(d));try{EditorUi.logEvent({category:"GLIFFY-IMPORT-FILE",action:"size_"+file.size})}catch(A){}};EditorUi.prototype.isResampleImageSize=function(d,f){f=null!=f?f:this.resampleThreshold;return d>f};EditorUi.prototype.resizeImage=function(d,f,l,u,A,B,F){A=null!=A?A:this.maxImageSize;var M=Math.max(1,d.width),O=Math.max(1,d.height);if(u&&this.isResampleImageSize(null!=F?F:f.length,B))try{var H= Math.max(M/A,O/A);if(1<H){var ja=Math.round(M/H),da=Math.round(O/H),ca=document.createElement("canvas");ca.width=ja;ca.height=da;ca.getContext("2d").drawImage(d,0,0,ja,da);var ia=ca.toDataURL();if(ia.length<f.length){var ma=document.createElement("canvas");ma.width=ja;ma.height=da;var aa=ma.toDataURL();ia!==aa&&(f=ia,M=ja,O=da)}}}catch(la){}l(f,M,O)};EditorUi.prototype.extractGraphModelFromPng=function(d){return Editor.extractGraphModelFromPng(d)};EditorUi.prototype.loadImage=function(d,f,l){try{var u=
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 V(){mxShape.call(this)}function d(c,m,x,p){mxShape.call(this);this.bounds=c;this.fill=m;this.stroke=x;this.strokewidth=null!=p?p:1}function f(){mxActor.call(this)}function l(){mxCylinder.call(this)}function u(){mxCylinder.call(this)}function A(){mxActor.call(this)}function B(){mxActor.call(this)}function F(){mxActor.call(this)}function M(){mxActor.call(this)}function O(){mxActor.call(this)}function H(){mxActor.call(this)}function ja(){mxActor.call(this)}function da(c,m){this.canvas=c;this.canvas.setLineJoin("round");
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=mxEvent.getClientX(H);u.popupMenuHandler.hideMenu();mxEvent.consume(H)}));mxEvent.addGestureListeners(document.body,null,mxUtils.bind(this,function(H){var ja=!1;null!=B&&(this.diagramContainer.style.width=Math.max(20,M+mxEvent.getClientX(H)-B)+"px",ja=!0);null!=F&&(this.diagramContainer.style.height=Math.max(20,O+mxEvent.getClientY(H)-F)+"px",ja=!0);ja&&((window.opener||window.parent).postMessage(JSON.stringify({event:"resize",fullscreen:Editor.inlineFullscreen,rect:this.diagramContainer.getBoundingClientRect()}), "*"),this.inlineSizeChanged(),this.refresh())}),function(H){null==B&&null==F||mxEvent.consume(H);F=B=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";f.style.visibility="hidden";d.style.visibility="hidden";l.style.display="none";this.addListener("editInlineStart",mxUtils.bind(this,function(H){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
mxClient.IS_EDGE?"6px":"1px";F.className="geColorBtn";d.appendChild(F);mxUtils.br(d);return{getColor:function(){return B},getTarget:function(){return u.value},focus:function(){u.focus()}}};EditorUi.prototype.createUrlParameters=function(d,f,l,u,A,B,F){F=null!=F?F:[];u&&("https://viewer.diagrams.net"==EditorUi.lightboxHost&&"1"!=urlParams.dev||F.push("lightbox=1"),"auto"!=d&&F.push("target="+d),null!=f&&f!=mxConstants.NONE&&F.push("highlight="+("#"==f.charAt(0)?f.substring(1):f)),null!=A&&0<A.length&& F.push("edit="+encodeURIComponent(A)),B&&F.push("layers=1"),this.editor.graph.foldingEnabled&&F.push("nav=1"));l&&null!=this.currentPage&&null!=this.pages&&this.currentPage!=this.pages[0]&&F.push("page-id="+this.currentPage.getId());return F};EditorUi.prototype.createLink=function(d,f,l,u,A,B,F,M,O,H){O=this.createUrlParameters(d,f,l,u,A,B,O);d=this.getCurrentFile();f=!0;null!=F?l="#U"+encodeURIComponent(F):(d=this.getCurrentFile(),M||null==d||d.constructor!=window.DriveFile?l="#R"+encodeURIComponent(l?
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.addSplitHandler=function(b,e,g,n){function y(R){if(null!=E){var V=new mxPoint(mxEvent.getClientX(R),mxEvent.getClientY(R));n(Math.max(0,K+(e?V.x-E.x:E.y-V.y)-g));mxEvent.consume(R);K!=L()&&(S=!0,G=null)}}function q(R){y(R);E=K=null}var E=null,K=null,S=!0,G=null;mxClient.IS_POINTER&&(b.style.touchAction="none");var L=mxUtils.bind(this,function(){var R=parseInt(e?b.style.left:b.style.bottom);e||(R=R+g-this.footerHeight);return R});mxEvent.addGestureListeners(b,function(R){E=new mxPoint(mxEvent.getClientX(R),
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.extractMermaidMindmap=function(d){for(0<d[1].indexOf("orientation")&&d.splice(1,1);1<d.length&&""==d[1];)d.splice(1,1);for(var f=[],l=2;l<d.length;l++){var u=mxUtils.trim(d[l]);"["!=u&&"]"!=u&&"%%"!=u.substring(0,2)&&"##"!=u.substring(0,2)&&(u=d[l].replace(/[-|>]/g," "),""!=mxUtils.trim(u)&&" "==u.charAt(0)&&f.push(u))}return"mindmap\nroot(("+mxUtils.trim(d[1])+"))\n"+f.join("\n")};EditorUi.prototype.extractMermaidDeclaration=function(d){"o\n\n"==d.substring(0,3)&&(d=d.substring(3)); var f=d.split("```");f=1<f.length?f:d.split("<pre>");f=1<f.length?f:d.split("~~~");f=1<f.length?f:d.split("%%");f=1<f.length?f:d.split("(Begins)");f=mxUtils.trim(1>=f.length?d:f[1]);var l=f.split("\n");if(0<l.length&&"mermaid"==mxUtils.trim(l[0])||1<l.length&&0<=mxUtils.indexOf(EditorUi.mermaidDiagramTypes,l[1]))l.shift(),f=mxUtils.trim(l.join("\n")),l=f.split("\n");var u=l[0].split(" ")[0].replace(/:$/,"");try{"mindmap"==u&&2<l.length&&(f=this.extractMermaidMindmap(l))}catch(A){}"@"!=u.charAt(0)&& 0>mxUtils.indexOf(EditorUi.mermaidDiagramTypes,u)&&(f="classDiagram\n"+f);EditorUi.debug("EditorUi.extractMermaidDeclaration","\nlines:",l,"\ntype:",u,"\nvalue:",d,"\ntext:",f);return f};EditorUi.prototype.removeMermaidComments=function(d){d=d.split("\n");for(var f=[],l=0;l<d.length;l++)"%%"!=d[l].substring(0,2)&&f.push(d[l]);return f.join("\n")};EditorUi.prototype.generateMermaidImage=function(d,f,l,u,A){d=this.removeMermaidComments(d);var B=mxUtils.bind(this,function(M){this.loadingMermaid=!1;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
"size",this.fixedSize)))):p*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));x=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(c,[new mxPoint(0,t),new mxPoint(m,0),new mxPoint(p,0),new mxPoint(p-m,t)],this.isRounded,x,!0);c.end()};mxCellRenderer.registerShape("parallelogram",M);mxUtils.extend(O,mxActor);O.prototype.size=.2;O.prototype.fixedSize=20;O.prototype.isRoundable=function(){return!0};O.prototype.redrawPath=function(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
c.begin(),c.moveTo(p-C,0),c.lineTo(p-C,C),c.lineTo(p,C),c.close(),c.fill()),c.begin(),c.moveTo(p-C,0),c.lineTo(p-C,C),c.lineTo(p,C),c.end(),c.stroke())};mxCellRenderer.registerShape("note",G);mxUtils.extend(L,G);mxCellRenderer.registerShape("note2",L);L.prototype.getLabelMargins=function(c){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var m=mxUtils.getValue(this.style,"size",15);return new mxRectangle(0,Math.min(c.height*this.scale,m*this.scale),0,0)}return null};mxUtils.extend(R,mxShape);R.prototype.isoAngle=
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.cellWasClicked=!0,this.consumeMouseEvent(mxEvent.MOUSE_DOWN,b)))};mxGraphHandler.prototype.getGuideStates=function(){var a=this.graph.getDefaultParent(),b=this.graph.getModel(),c=mxUtils.bind(this,function(d){return null!=this.graph.view.getState(d)&&b.isVertex(d)&&null!=b.getGeometry(d)&&!b.getGeometry(d).relative});return this.graph.view.getCellStates(b.filterDescendants(c,a))};mxGraphHandler.prototype.getCells=function(a){return!this.delayedSelection&&this.graph.isCellMovable(a)?[a]:this.graph.getMovableCells(this.graph.getSelectionCells())};
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.body.removeChild(e),document.body.removeChild(g),document.body.style.overflow=E,GraphViewer.resizeSensorEnabled=!0,K.apply(this,arguments))};var S=y.editor.graph,G=S.container;G.style.overflow="hidden";this.lightboxChrome&&null==b?(G.style.border="1px solid #c0c0c0",G.style.margin="40px",mxEvent.addListener(document.documentElement,"keydown",q)):(e.style.display="none",g.style.display="none");var L=this;S.getImageFromBundles=function(V){return L.getImageUrl(V)};var R=y.createTemporaryGraph;
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.addRadiobox=function(d,f,l,u,A,B,F){return this.addCheckbox(d,l,u,A,B,F,!0,f)};EditorUi.prototype.addCheckbox=function(d,f,l,u,A,B,F,M){B=null!=B?B:!0;var O=document.createElement("input");O.style.marginRight="8px";O.style.marginTop="16px";O.setAttribute("type",F?"radio":"checkbox");F="geCheckbox-"+Editor.guid();O.id=F;null!=M&&O.setAttribute("name",M);l&&(O.setAttribute("checked","checked"),O.defaultChecked=!0);u&&O.setAttribute("disabled","disabled");B&&(d.appendChild(O),l=document.createElement("label"),
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
f)};EditorUi.prototype.embedExtFonts=function(d){EditorUi.logEvent("SHOULD NOT BE CALLED: embedExtFonts");return this.editor.embedExtFonts(d)};EditorUi.prototype.exportToCanvas=function(d,f,l,u,A,B,F,M,O,H,ja,da,ca,ia,ma,aa){EditorUi.logEvent("SHOULD NOT BE CALLED: exportToCanvas");return this.editor.exportToCanvas(d,f,l,u,A,B,F,M,O,H,ja,da,ca,ia,ma,aa)};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
function(d){var f=L.apply(this,arguments),l=mxUtils.bind(this,function(){f.refresh();this.restoreOpenLibraries()});Editor.enableCssDarkMode||this.addListener("darkModeChanged",l);this.addListener("sketchModeChanged",l);this.addListener("currentThemeChanged",l);return f};EditorUi.prototype.restoreOpenLibraries=function(){var d=this.openLibraries;this.openLibraries=null;if(null!=d)for(var f=0;f<d.length;f++)this.libraryLoaded(d[f].file,d[f].images,d[f].title,null!=d[f].div?"none"!=d[f].div.style.display:
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
F.freehand){var ma=F.freehand.createStyle;F.freehand.createStyle=function(ha){return ma.apply(this,arguments)+"sketch=0;"}}B.editor.addListener("statusChanged",mxUtils.bind(this,function(){B.setStatusText(B.editor.getStatus())}));B.setStatusText(B.editor.getStatus());var aa=B.menus.get("viewZoom");if(null!=aa){var la=function(ha){if(mxEvent.isAltDown(ha))B.hideCurrentMenu(),B.actions.get("customZoom").funct(),mxEvent.consume(ha);else if("geMenuItem"==mxEvent.getSource(ha).className||mxEvent.isShiftDown(ha))B.hideCurrentMenu(), B.actions.get("smartFit").funct(),mxEvent.consume(ha)},X=B.actions.get("zoomIn"),P=B.actions.get("zoomOut"),U=B.actions.get("resetView"),k=B.actions.get("undo"),z=B.actions.get("redo"),J=d("",k.funct,null,mxResources.get("undo")+" ("+k.shortcut+")",k,Editor.undoImage),W=d("",z.funct,null,mxResources.get("redo")+" ("+z.shortcut+")",z,Editor.redoImage),T=d("",la,!0,mxResources.get("fit")+" ("+Editor.ctrlKey+"+H)",U,Editor.zoomFitImage);M.style.cssText="position:absolute;left:0px;right:0px;top:0px;height:30px;padding:8px;text-align:left;white-space:nowrap;";
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
DrawioFile.prototype.fileSaved=function(b,e,g,n,y,q,E){this.lastSaved=new Date;this.ageStart=null;this.stats.saved++;try{this.invalidChecksum=this.inConflictState=!1;q=null!=q?q:this.ui.getPagesForXml(b);try{null==this.sync||this.isOptimisticSync()?(this.setShadowPages(q),null!=this.sync&&(this.sync.lastModified=this.getLastModifiedDate(),this.sync.resetUpdateStatusThread(),this.isRealtime()&&this.sync.scheduleCleanup()),null!=g&&g()):this.sync.fileSaved(q,e,g,n,y,E)}catch(G){this.invalidChecksum= this.inConflictState=!0;this.descriptorChanged();null!=n&&n(G);try{if(this.errorReportsEnabled)this.sendErrorReport("Error in fileSaved",null,G);else{var K=this.getCurrentUser(),S=null!=K?K.id:"unknown";EditorUi.logError("Error in fileSaved",null,this.getMode()+"."+this.getId(),S,G)}}catch(L){}}EditorUi.debug("DrawioFile.fileSaved",[this],"savedData",[b],"desc",[e],"inConflictState",this.inConflictState,"invalidChecksum",this.invalidChecksum)}catch(G){this.descriptorChanged(),null!=n&&n(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
return!mxUtils.getValue(E.style,mxConstants.STYLE_CURVED,!1)&&("connector"==K||"filledEdge"==K||"wire"==K)};Graph.prototype.isAutoSizeState=function(E){return"1"==mxUtils.getValue(E.style,mxConstants.STYLE_AUTOSIZE,null)};Graph.prototype.isImageState=function(E){return null!=mxUtils.getValue(E.style,mxConstants.STYLE_IMAGE,null)};Graph.prototype.isShadowState=function(E){return"image"!=mxUtils.getValue(E.style,mxConstants.STYLE_SHAPE,null)};Graph.prototype.getVerticesAndEdges=function(E,K){E=null!= E?E:!0;K=null!=K?K:!0;var S=this.model;return S.filterDescendants(function(G){return E&&S.isVertex(G)||K&&S.isEdge(G)},S.getRoot())};Graph.prototype.applyNewEdgeStyle=function(E,K,S){E=this.getCellStyle(E).newEdgeStyle;if(null!=E){this.model.beginUpdate();try{var G=JSON.parse(E),L;for(L in G)this.setCellStyles(L,G[L],K),"edgeStyle"==L&&"elbowEdgeStyle"==G[L]&&null!=S&&this.setCellStyles("elbow",S==mxConstants.DIRECTION_SOUTH||S==mxConstants.DIRECTION_NOTH?"vertical":"horizontal",K)}finally{this.model.endUpdate()}}};
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
DrawioFile.prototype.patch=function(b,e,g,n){if(null!=b){var y=this.ui.editor.undoManager,q=y.history.slice(),E=y.indexOfNextAdd,K=this.ui.editor.graph;K.container.style.visibility="hidden";var S=this.changeListenerEnabled;this.changeListenerEnabled=g;var G=K.foldingEnabled,L=K.mathEnabled,R=K.cellRenderer.redraw;K.cellRenderer.redraw=function(A){A.view.graph.isEditing(A.cell)&&(A.view.graph.scrollCellToVisible(A.cell),A.view.graph.cellEditor.resize());R.apply(this,arguments)};K.model.beginUpdate();
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!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.graph.getSelectionModel().removeListener(this.changeHandler),this.changeHandler=null)}}();(function(){function b(c,m,x){mxShape.call(this);this.line=c;this.stroke=m;this.strokewidth=null!=x?x:1;this.updateBoundsFromLine()}function e(){mxSwimlane.call(this)}function g(){mxSwimlane.call(this)}function n(){mxCylinder.call(this)}function y(){mxConnector.call(this)}function q(){mxCylinder.call(this)}function E(){mxActor.call(this)}function K(){mxCylinder.call(this)}function S(){mxCylinder.call(this)}function G(){mxCylinder.call(this)}function L(){mxCylinder.call(this)}function R(){mxShape.call(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
Graph.prototype.createLayersDialog=function(b,e){var g=document.createElement("div");g.style.position="absolute";for(var n=this.getModel(),y=n.getChildCount(n.root),q=0;q<y;q++)mxUtils.bind(this,function(E){function K(){n.isVisible(E)?(L.setAttribute("src",Editor.visibleImage),mxUtils.setOpacity(G,75)):(L.setAttribute("src",Editor.hiddenImage),mxUtils.setOpacity(G,25))}var S=this.convertValueToString(E)||mxResources.get("background")||"Background",G=document.createElement("div");G.style.overflow=
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
2))+"px";this.linkHint.style.top=Math.round(v.y+v.height+Editor.hintOffset)+"px";this.linkHint.style.display=1<this.graph.getSelectionCount()?"none":""}};var Ea=mxEdgeHandler.prototype.reset;mxEdgeHandler.prototype.reset=function(){Ea.apply(this,arguments);null!=this.linkHint&&(this.linkHint.style.visibility="")};var Ka=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){Ka.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint= null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.graph.getSelectionModel().removeListener(this.changeHandler),this.changeHandler=null)}}();(function(){function b(c,m,x){mxShape.call(this);this.line=c;this.stroke=m;this.strokewidth=null!=x?x:1;this.updateBoundsFromLine()}function e(){mxSwimlane.call(this)}function g(){mxSwimlane.call(this)}function n(){mxCylinder.call(this)}function y(){mxConnector.call(this)}function q(){mxCylinder.call(this)}function E(){mxActor.call(this)}function K(){mxCylinder.call(this)}function S(){mxCylinder.call(this)}function G(){mxCylinder.call(this)}function L(){mxCylinder.call(this)}function R(){mxShape.call(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
E.style.backgroundPosition=d,E.style.backgroundImage=V,!R||null!=G.background&&G.background!=mxConstants.NONE?E.style.backgroundColor=L:(E.style.backgroundColor=G.diagramBackgroundColor,G.container.style.backgroundColor=""))};mxGraphView.prototype.createSvgGrid=function(E,K){for(K=this.graph.gridSize*this.scale*(null!=K?K:1);K<this.minGridSize;)K*=2;for(var S=this.gridSteps*K,G=[],L=1;L<this.gridSteps;L++){var R=L*K;G.push("M 0 "+R+" L "+S+" "+R+" M "+R+" 0 L "+R+" "+S)}return'<svg width="'+S+'" height="'+ S+'" xmlns="'+mxConstants.NS_SVG+'"><defs><pattern id="grid" width="'+S+'" height="'+S+'" patternUnits="userSpaceOnUse"><path d="'+G.join(" ")+'" fill="none" stroke="'+E+'" opacity="0.2" stroke-width="1"/><path d="M '+S+" 0 L 0 0 0 "+S+'" fill="none" stroke="'+E+'" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(#grid)"/></svg>'};var b=mxGraph.prototype.panGraph;mxGraph.prototype.panGraph=function(E,K){b.apply(this,arguments);if(null!=this.shiftPreview1){var S=this.view.canvas;
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
mxGraphView.prototype.updateFloatingTerminalPoint=function(L,R,V,d){if(null==R||null==L||"1"!=R.style.snapToPoint&&"1"!=L.style.snapToPoint)K.apply(this,arguments);else{R=this.getTerminalPort(L,R,d);var f=this.getNextPoint(L,V,d),l=this.graph.isOrthogonal(L),u=mxUtils.toRadians(Number(R.style[mxConstants.STYLE_ROTATION]||"0")),A=new mxPoint(R.getCenterX(),R.getCenterY());if(0!=u){var B=Math.cos(-u),F=Math.sin(-u);f=mxUtils.getRotatedPoint(f,B,F,A)}B=parseFloat(L.style[mxConstants.STYLE_PERIMETER_SPACING]|| 0);B+=parseFloat(L.style[d?mxConstants.STYLE_SOURCE_PERIMETER_SPACING:mxConstants.STYLE_TARGET_PERIMETER_SPACING]||0);f=this.getPerimeterPoint(R,f,0==u&&l,B);0!=u&&(B=Math.cos(u),F=Math.sin(u),f=mxUtils.getRotatedPoint(f,B,F,A));L.setAbsoluteTerminalPoint(this.snapToAnchorPoint(L,R,V,d,f),d)}};mxGraphView.prototype.snapToAnchorPoint=function(L,R,V,d,f){if(null!=R&&null!=L){L=this.graph.getAllConnectionConstraints(R);d=V=null;if(null!=L)for(var l=0;l<L.length;l++){var u=this.graph.getConnectionPoint(R,
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
1):"pagenumber"==l?K.currentPage+1:"pagecount"==l?S.length:L.apply(this,arguments)}}}this.diagrams=[];var R=null;this.selectPage=function(l){this.handlingResize||(this.currentPage=mxUtils.mod(l,this.diagrams.length),this.updateGraphXml(Editor.parseDiagramNode(this.diagrams[this.currentPage])))};this.selectPageById=function(l){l=this.getIndexById(l);var u=0<=l;u&&this.selectPage(l);return u};G=mxUtils.bind(this,function(){if(null==this.xmlNode||"mxfile"!=this.xmlNode.nodeName)this.diagrams=[];this.xmlNode!=
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
ra);Z(k,ra);Z(k,4)}while(ra);return"data:image/png;base64,"+(window.btoa?btoa(T):Base64.encode(T,!0))}};if(window.ColorDialog){FilenameDialog.filenameHelpLink="https://www.drawio.com/doc/faq/save-file-formats";var K=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(k,z){K.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()};var S=ColorDialog.resetRecentColors;ColorDialog.resetRecentColors=function(){S.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors); mxSettings.save()}}"undefined"!==typeof window.EditDataDialog&&(EditDataDialog.getDisplayIdForCell=function(k,z){var J=null;null!=k.editor.graph.getModel().getParent(z)?J=z.getId():null!=k.currentPage&&(J=k.currentPage.getId());return J});if(null!=window.StyleFormatPanel){var G=Format.prototype.init;Format.prototype.init=function(){G.apply(this,arguments);this.editorUi.editor.addListener("fileLoaded",this.update)};var L=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||
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.random()))):A.toUpperCase()!=A?l.push(String.fromCharCode(97+Math.round(25*Math.random()))):/\s/.test(A)?l.push(" "):l.push("?"):l.push(f?"0":Math.round(9*Math.random()))}return l.join("")};EditorUi.prototype.anonymizePatch=function(d){if(null!=d[EditorUi.DIFF_INSERT])for(var f=0;f<d[EditorUi.DIFF_INSERT].length;f++)try{var l=mxUtils.parseXml(d[EditorUi.DIFF_INSERT][f].data).documentElement.cloneNode(!1);null!=l.getAttribute("name")&&l.setAttribute("name",this.anonymizeString(l.getAttribute("name"))); d[EditorUi.DIFF_INSERT][f].data=mxUtils.getXml(l)}catch(B){d[EditorUi.DIFF_INSERT][f].data=B.message}if(null!=d[EditorUi.DIFF_UPDATE]){for(var u in d[EditorUi.DIFF_UPDATE]){var A=d[EditorUi.DIFF_UPDATE][u];null!=A.name&&(A.name=this.anonymizeString(A.name));null!=A.cells&&(f=mxUtils.bind(this,function(B){var F=A.cells[B];if(null!=F){for(var M in F)null!=F[M].value&&(F[M].value="["+F[M].value.length+"]"),null!=F[M].xmlValue&&(F[M].xmlValue="["+F[M].xmlValue.length+"]"),null!=F[M].style&&(F[M].style= "["+F[M].style.length+"]"),mxUtils.isEmptyObject(F[M])&&delete F[M];mxUtils.isEmptyObject(F)&&delete A.cells[B]}}),f(EditorUi.DIFF_INSERT),f(EditorUi.DIFF_UPDATE),mxUtils.isEmptyObject(A.cells)&&delete A.cells);mxUtils.isEmptyObject(A)&&delete d[EditorUi.DIFF_UPDATE][u]}mxUtils.isEmptyObject(d[EditorUi.DIFF_UPDATE])&&delete d[EditorUi.DIFF_UPDATE]}return d};EditorUi.prototype.anonymizeAttributes=function(d,f){if(null!=d.attributes)for(var l=0;l<d.attributes.length;l++)"as"!=d.attributes[l].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
mxConstants.STYLE_DASHED,"0")&&L[1].setAttribute("stroke-dasharray",8*this.state.view.scale);var R=this.state.view.graph.getFlowAnimationStyle();null!=R&&L[1].setAttribute("class",R.getAttribute("id"))}}};var n=mxCellRenderer.prototype.isShapeInvalid;mxCellRenderer.prototype.isShapeInvalid=function(L,R){return n.apply(this,arguments)||null!=L.routedPoints&&null!=R.routedPoints&&!mxUtils.equalPoints(R.routedPoints,L.routedPoints)};var y=mxGraphView.prototype.updateCellState;mxGraphView.prototype.updateCellState=
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||"undefined"!==typeof jQuery&&g instanceof jQuery||"undefined"!==typeof Elements&&g instanceof Elements;if(R){L=0;for(var V=g.length;L<V;L++)E(g[L],K)}else E(g,K);this.detach=function(){if(R)for(var d=0,f=g.length;d<f;d++)e.detach(g[d]);else e.detach(g)}}};e.detach=function(g){g.resizeSensor&&(g.removeChild(g.resizeSensor),delete g.resizeSensor,delete g.resizedAttached)};window.ResizeSensor=e})();
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
Actions.prototype.init=function(){function b(G){q.escape();G=q.deleteCells(q.getDeletableCells(q.getSelectionCells()),G);null!=G&&q.setSelectionCells(G)}function e(){if(!q.isSelectionEmpty()){q.getModel().beginUpdate();try{for(var G=q.getSelectionCells(),L=0;L<G.length;L++)q.cellLabelChanged(G[L],"")}finally{q.getModel().endUpdate()}}}function g(G,L,R,V,d){d.getModel().beginUpdate();try{var f=d.getCellGeometry(G);null!=f&&R&&V&&(R/=V,f=f.clone(),1<R?f.height=f.width/R:f.width=f.height*R,d.getModel().setGeometry(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
(f.x+=e.offset.x,f.y+=e.offset.y),e=this.getCurrentCellStyle(a[d]),null!=f&&(e=mxUtils.getValue(e,mxConstants.STYLE_ROTATION,0),0!=e&&(f=mxUtils.getBoundingBox(f,e)));null!=f&&(null==c?c=mxRectangle.fromRectangle(f):c.add(f))}}return c};mxGraph.prototype.refresh=function(a){this.view.clear(a,null==a);this.view.validate();this.sizeDidChange();this.fireEvent(new mxEventObject(mxEvent.REFRESH))};mxGraph.prototype.snap=function(a){this.gridEnabled&&(a=Math.round(a/this.gridSize)*this.gridSize);return a};
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.setAttribute("value",u.key);mxUtils.write(A,u.title);K.appendChild(A)}var B=!1;y();b.appendChild(K);mxUtils.br(b);b.appendChild(S);b.appendChild(L);var F=g,M=function(O,H){O=d[K.value];null!=O.format?(R.value=O.format.width/100,V.value=O.format.height/100,L.style.display="none",S.style.display=""):(S.style.display="none",L.style.display="");O=parseFloat(R.value);if(isNaN(O)||0>=O)R.value=g.width/100;O=parseFloat(V.value);if(isNaN(O)||0>=O)V.value=g.height/100;O=new mxRectangle(0,0,Math.floor(100* parseFloat(R.value)),Math.floor(100*parseFloat(V.value)));"custom"!=K.value&&E.checked&&(O=new mxRectangle(0,0,O.height,O.width));H&&B||O.width==F.width&&O.height==F.height||(F=O,null!=n&&n(F))};mxEvent.addListener(e,"click",function(O){q.checked=!0;M(O);mxEvent.consume(O)});mxEvent.addListener(G,"click",function(O){E.checked=!0;M(O);mxEvent.consume(O)});mxEvent.addListener(R,"blur",M);mxEvent.addListener(R,"click",M);mxEvent.addListener(V,"blur",M);mxEvent.addListener(V,"click",M);mxEvent.addListener(E,
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
"size",this.fixedSize)))):p*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));x=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(c,[new mxPoint(0,t),new mxPoint(m,0),new mxPoint(p,0),new mxPoint(p-m,t)],this.isRounded,x,!0);c.end()};mxCellRenderer.registerShape("parallelogram",M);mxUtils.extend(O,mxActor);O.prototype.size=.2;O.prototype.fixedSize=20;O.prototype.isRoundable=function(){return!0};O.prototype.redrawPath=function(c, m,x,p,t){m="0"!=mxUtils.getValue(this.style,"fixedSize","0")?Math.max(0,Math.min(.5*p,parseFloat(mxUtils.getValue(this.style,"size",this.fixedSize)))):p*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));x=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(c,[new mxPoint(0,t),new mxPoint(m,0),new mxPoint(p-m,0),new mxPoint(p,t)],this.isRounded,x,!0)};mxCellRenderer.registerShape("trapezoid",O);mxUtils.extend(H,mxActor);
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
qa.className="geCommentAction";var ra=document.createElement("a");ra.className="geCommentActionLnk";mxUtils.write(ra,Z);qa.appendChild(ra);mxEvent.addListener(ra,"click",function(pa){ba(pa,ca);pa.preventDefault();mxEvent.consume(pa)});T.appendChild(qa);ha&&(qa.style.display="none")}function P(){function Z(qa){ba.push(ha);if(null!=qa.replies)for(var ra=0;ra<qa.replies.length;ra++)ha=ha.nextSibling,Z(qa.replies[ra])}var ba=[],ha=k;Z(ca);return{pdiv:ha,replies:ba}}function U(Z,ba,ha,qa,ra){function pa(){G(za); ca.addReply(Ba,function(Ma){Ba.id=Ma;ca.replies.push(Ba);R(za);ha&&ha()},function(Ma){xa();L(za);b.handleError(Ma,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))},qa,ra)}function xa(){K(Ba,za,function(Ma){pa()},!0)}var Ca=P().pdiv,Ba=b.newComment(Z,b.getCurrentUser());Ba.pCommentId=ca.id;null==ca.replies&&(ca.replies=[]);var za=V(Ba,ca.replies,Ca,aa+1);ba?xa():pa()}if(la||!ca.isResolved){F.style.display="none";var k=document.createElement("div");k.className="geCommentContainer";
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:!1};var S=Graph.prototype.isCellMovable;Graph.prototype.isCellMovable=function(v){return null!=v&&S.apply(this,arguments)?this.isTableCell(v)||this.isTableRow(v)?this.isCellMovable(this.model.getParent(v)):!0:!1};var G=Graph.prototype.isExtendParent;Graph.prototype.isExtendParent=function(v){var N=this.model.getParent(v);if(null!=N){var Q=this.getCurrentCellStyle(N);if(null!=Q.expand)return"0"!=Q.expand}return G.apply(this,arguments)&&(null==N||!this.isTable(N))};var L=Graph.prototype.splitEdge;
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&&l()};EditorUi.prototype.alert=function(d,f,l){d=new ErrorDialog(this,null,d,mxResources.get("ok"),f);this.showDialog(d.container,l||340,100,!0,!1);d.init()};EditorUi.prototype.confirm=function(d,f,l,u,A,B){d=null!=d?d:"";var F=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},M=Math.min(220,28*Math.ceil(Math.max(1,d.length)/50));d=new ConfirmDialog(this,d,function(){F();null!=f&&f()},function(){F();null!=l&&l()},u,A,null,null,null,null,M);this.showDialog(d.container,
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(d){var f=L.apply(this,arguments),l=mxUtils.bind(this,function(){f.refresh();this.restoreOpenLibraries()});Editor.enableCssDarkMode||this.addListener("darkModeChanged",l);this.addListener("sketchModeChanged",l);this.addListener("currentThemeChanged",l);return f};EditorUi.prototype.restoreOpenLibraries=function(){var d=this.openLibraries;this.openLibraries=null;if(null!=d)for(var f=0;f<d.length;f++)this.libraryLoaded(d[f].file,d[f].images,d[f].title,null!=d[f].div?"none"!=d[f].div.style.display: d[f].expand)};var R=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){R.apply(this,arguments);var d=this.editor.graph,f=this.getCurrentFile(),l=this.getSelectionState(),u=this.isDiagramActive(),A="1"==urlParams.embed&&this.editor.graph.isEnabled()||null!=f&&f.isEditable();this.actions.get("undo").setEnabled(this.canUndo()&&A);this.actions.get("redo").setEnabled(this.canRedo()&&A);this.actions.get("autosave").setEnabled(null!=f&&f.isEditable()&&f.isAutosaveOptional());
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(d){var f=d.msgMarkers,l=this.remoteInvokeCallbacks[f.callbackId];if(null==l)throw Error("No callback for "+(null!=f?f.callbackId:"null"));d.error?l.error&&l.error(d.error.errResp):l.callback&&l.callback.apply(this,d.resp);this.remoteInvokeCallbacks[f.callbackId]=null};EditorUi.prototype.remoteInvoke=function(d,f,l,u,A){var B=!0,F=window.setTimeout(mxUtils.bind(this,function(){B=!1;A({code:App.ERROR_TIMEOUT,message:mxResources.get("timeout")})}),this.timeout),M=mxUtils.bind(this,function(){window.clearTimeout(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
this.toolbar.edgeStyleMenu.setEnabled(d));this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};EditorUi.prototype.scheduleSanityCheck=function(){};EditorUi.prototype.stopSanityCheck=function(){};EditorUi.prototype.isDiagramActive=function(){var d=this.getCurrentFile();return null!=d&&d.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled()};var L=EditorUi.prototype.createSidebar;EditorUi.prototype.createSidebar=
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
1)];null!=l&&(f.originalSrc="data:page/id,"+l)}}catch(u){}};EditorUi.prototype.updatePageLinksForCell=function(d,f){var l=document.createElement("div"),u=this.editor.graph,A=u.getLinkForCell(f);null!=A&&u.setLinkForCell(f,this.updatePageLink(d,A));if(u.isHtmlLabel(f)){l.innerHTML=Graph.sanitizeHtml(u.getLabel(f));for(var B=l.getElementsByTagName("a"),F=!1,M=0;M<B.length;M++)A=B[M].getAttribute("href"),null!=A&&(B[M].setAttribute("href",this.updatePageLink(d,A)),F=!0);F&&u.labelChanged(f,l.innerHTML)}for(M= 0;M<u.model.getChildCount(f);M++)this.updatePageLinksForCell(d,u.model.getChildAt(f,M))};EditorUi.prototype.updatePageLink=function(d,f){if(Graph.isPageLink(f)){var l=d[f.substring(f.indexOf(",")+1)];f=null!=l?"data:page/id,"+l:null}else if("data:action/json,"==f.substring(0,17))try{var u=JSON.parse(f.substring(17));if(null!=u.actions){for(var A=0;A<u.actions.length;A++){var B=u.actions[A];if(null!=B.open&&Graph.isPageLink(B.open)){var F=B.open.substring(B.open.indexOf(",")+1);l=d[F];null!=l?B.open=
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.defaultEdgeStyle.sketch="1",d.defaultEdgeStyle.curveFitting=Editor.sketchDefaultCurveFitting,d.defaultEdgeStyle.jiggle=Editor.sketchDefaultJiggle,d.defaultEdgeStyle.hachureGap="4"):this.menus.defaultFonts=Menus.prototype.defaultFonts;d.currentVertexStyle=mxUtils.clone(d.defaultVertexStyle);d.currentEdgeStyle=mxUtils.clone(d.defaultEdgeStyle);this.clearDefaultStyle()};EditorUi.prototype.getLinkTitle=function(d){var f=Graph.prototype.getLinkTitle.apply(this,arguments);if(Graph.isPageLink(d)){var l= d.indexOf(",");0<l&&(f=this.getPageById(d.substring(l+1)),f=null!=f?f.getName():mxResources.get("pageNotFound"))}else"data:"==d.substring(0,5)&&(f=mxResources.get("action"));return f};EditorUi.prototype.handleCustomLink=function(d){if(Graph.isPageLink(d)){var f=d.indexOf(",");if(d=this.getPageById(d.substring(f+1)))this.selectPage(d);else throw Error(mxResources.get("pageNotFound")||"Page not found");}else this.editor.graph.handleCustomLink(d)};EditorUi.prototype.installSettings=function(){if(Editor.isSettingsEnabled()){Editor.pagesVisible=
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.prototype.getSvg=function(k,z,J,W,T,Z,ba,ha,qa,ra,pa,xa,Ca,Ba){var za=null,Ma=null,Qa=null;Editor.enableCssDarkMode||null==this.themes||null==xa||"dark"==xa==("darkTheme"==this.defaultThemeName)||(za=this.stylesheet,Ma=this.shapeForegroundColor,Qa=this.shapeBackgroundColor,this.shapeForegroundColor="darkTheme"==this.defaultThemeName?"#000000":Editor.lightColor,this.shapeBackgroundColor="darkTheme"==this.defaultThemeName?"#ffffff":Editor.darkColor,this.stylesheet=this.getDefaultStylesheet(), this.refresh());var Pa=null;Editor.enableCssDarkMode&&null!=this.backgroundImage&&(Pa=this.backgroundImage,this.backgroundImage=this.adaptBackgroundPage(Pa,xa));var ta=M.apply(this,arguments);if(Editor.enableCssDarkMode&&("dark"==xa||"auto"==xa)){var Da=Graph.createSvgDarkModeStyle(ta.ownerDocument,xa);ta.getElementsByTagName("defs")[0].appendChild(Da)}var Aa=this.getCustomFonts();if(pa&&0<Aa.length){var ya=ta.ownerDocument;Da=null!=ya.createElementNS?ya.createElementNS(mxConstants.NS_SVG,"style"): ya.createElement("style");null!=ya.setAttributeNS?Da.setAttributeNS("type","text/css"):Da.setAttribute("type","text/css");for(var Ra="",Wa="",La=0;La<Aa.length;La++){var ab=Aa[La].name,Ea=Aa[La].url;Graph.isCssFontUrl(Ea)?Ra+="@import url("+Ea+");\n":Wa+='@font-face {\nfont-family: "'+ab+'";\nsrc: url("'+Ea+'");\n}\n'}Da.appendChild(ya.createTextNode(Ra+Wa));ta.getElementsByTagName("defs")[0].appendChild(Da)}this.mathEnabled&&(document.body.appendChild(ta),Editor.MathJaxRender(ta),ta.parentNode.removeChild(ta)); null!=Pa&&(this.backgroundImage=Pa);null!=za&&(this.shapeBackgroundColor=Qa,this.shapeForegroundColor=Ma,this.stylesheet=za,this.refresh());return ta};var O=mxCellRenderer.prototype.destroy;mxCellRenderer.prototype.destroy=function(k){O.apply(this,arguments);null!=k.secondLabel&&(k.secondLabel.destroy(),k.secondLabel=null)};mxCellRenderer.prototype.getShapesForState=function(k){return[k.shape,k.text,k.secondLabel,k.control]};var H=mxGraphView.prototype.resetValidationState;mxGraphView.prototype.resetValidationState=
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.dialogs||0==g.dialogs.length)};y.isControlDown=function(R){return mxEvent.isControlDown(R)||mxClient.IS_MAC&&R.metaKey};var E=null,K={37:mxConstants.DIRECTION_WEST,38:mxConstants.DIRECTION_NORTH,39:mxConstants.DIRECTION_EAST,40:mxConstants.DIRECTION_SOUTH},S=y.getFunction;mxKeyHandler.prototype.getFunction=function(R){if(n.isEnabled()){if(mxEvent.isShiftDown(R)&&mxEvent.isAltDown(R)){var V=g.actions.get(g.altShiftActions[R.keyCode]);if(null!=V)return V.funct}if(null!=K[R.keyCode]&&!n.isSelectionEmpty())if(!this.isControlDown(R)&& mxEvent.isShiftDown(R)&&mxEvent.isAltDown(R)){if(n.model.isVertex(n.getSelectionCell()))return function(){var d=n.connectVertex(n.getSelectionCell(),K[R.keyCode],n.defaultEdgeLength,R,!0);null!=d&&0<d.length&&(1==d.length&&n.model.isEdge(d[0])?n.setSelectionCell(n.model.getTerminal(d[0],!1)):n.setSelectionCell(d[d.length-1]),n.scrollCellToVisible(n.getSelectionCell()),null!=g.hoverIcons&&g.hoverIcons.update(n.view.getState(n.getSelectionCell())))}}else return this.isControlDown(R)?function(){e(R.keyCode, mxEvent.isShiftDown(R)?n.gridSize:null,!0)}:function(){e(R.keyCode,mxEvent.isShiftDown(R)?n.gridSize:null)}}return S.apply(this,arguments)};y.bindAction=mxUtils.bind(this,function(R,V,d,f){var l=this.actions.get(d);null!=l&&(d=function(){l.isEnabled()&&l.funct.apply(this,arguments)},V?f?y.bindControlShiftKey(R,d):y.bindControlKey(R,d):f?y.bindShiftKey(R,d):y.bindKey(R,d))});var G=this,L=y.escape;y.escape=function(R){L.apply(this,arguments)};y.enter=function(){};y.bindControlShiftKey(36,function(){n.exitGroup()});
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.write(ia,mxResources.get("timeAgo",[ma],"{1} ago"));ia.setAttribute("title",ca.toLocaleDateString()+" "+ca.toLocaleTimeString())}function G(ca){var ia=document.createElement("img");ia.className="geCommentBusyImg";ia.src=IMAGE_PATH+"/spin.gif";ca.appendChild(ia);ca.busyImg=ia}function L(ca){ca.style.border="1px solid red";ca.removeChild(ca.busyImg)}function R(ca){ca.style.border="";ca.removeChild(ca.busyImg)}function V(ca,ia,ma,aa,la){function X(Z,ba,ha){var qa=document.createElement("li");
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