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
e.parentNode&&e.parentNode.removeChild(e)}))};var G=!1;EditorUi.prototype.initFormatWindow=function(){if(!G&&null!=this.formatWindow){G=!0;var J=this.formatWindow.window.toggleMinimized,c=240;this.formatWindow.window.toggleMinimized=function(){J.apply(this,arguments);this.minimized?(c=parseInt(this.div.style.width),this.div.style.width="140px",this.table.style.width="140px",this.div.style.left=parseInt(this.div.style.left)+c-140+"px"):(this.div.style.width=c+"px",this.table.style.width=this.div.style.width, this.div.style.left=Math.max(0,parseInt(this.div.style.left)-c+140)+"px");this.fit()};mxEvent.addListener(this.formatWindow.window.title,"dblclick",mxUtils.bind(this,function(e){mxEvent.getSource(e)==this.formatWindow.window.title&&this.formatWindow.window.toggleMinimized()}))}};var S=EditorUi.prototype.init;EditorUi.prototype.init=function(){function J(W,X,Z){var Y=t.menus.get(W),ea=B.addMenu(mxResources.get(W),mxUtils.bind(this,function(){Y.funct.apply(this,arguments)}),I);ea.className="geMenuItem";
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
StorageFile.insertFile=function(b,f,m,d,u){var v=mxUtils.bind(this,function(D){var F=function(){var K=new StorageFile(b,m,f);K.saveFile(f,!1,function(){d(K)},u)};D?b.confirm(mxResources.get("replaceIt",[f]),F,u):F()});StorageFile.getFileContent(b,f,function(D){v(null!=D)},function(){v(!1)})};StorageFile.getFileContent=function(b,f,m,d){b.getDatabaseItem(f,function(u){m(null!=u?u.data:null)},mxUtils.bind(this,function(){null==b.database?b.getLocalData(f,m):null!=d&&d()}),"files")};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
g)this.editPlantUmlData(L,U,g);else if(g=this.graph.getAttributeForCell(L,"mermaidData"),null!=g)this.editMermaidData(L,U,g);else{var y=e.getCellStyle(L);"1"==mxUtils.getValue(y,"metaEdit","0")?c.showDataDialog(L):k.apply(this,arguments)}}catch(H){c.handleError(H)}};e.getLinkTitle=function(L){return c.getLinkTitle(L)};e.customLinkClicked=function(L){var U=!1;try{c.handleCustomLink(L),U=!0}catch(g){c.handleError(g)}return U};var q=e.parseBackgroundImage;e.parseBackgroundImage=function(L){var U=q.apply(this, arguments);null!=U&&null!=U.src&&Graph.isPageLink(U.src)&&(U={originalSrc:U.src});return U};var p=e.setBackgroundImage;e.setBackgroundImage=function(L){null!=L&&null!=L.originalSrc&&(L=c.createImageForPageLink(L.originalSrc,c.currentPage,this));p.apply(this,arguments)};this.editor.addListener("pageRenamed",mxUtils.bind(this,function(){e.refreshBackgroundImage()}));this.editor.addListener("pageMoved",mxUtils.bind(this,function(){e.refreshBackgroundImage()}));this.editor.addListener("pagesPatched",
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(z){G=z};this.setAutoScroll=function(z){S=z};this.setOpenFill=function(z){J=z};this.setStopClickEnabled=function(z){k=z};this.setSelectInserted=function(z){q=z};this.setSmoothing=function(z){m=z};this.setPerfectFreehandMode=function(z){t=z};this.isPerfectFreehandMode=function(){return t};this.setBrushSize=function(z){p.size=z};this.getBrushSize=function(){return p.size};var x=function(z){e=z;b.getRubberband().setEnabled(!z);b.graphHandler.setSelectEnabled(!z);b.graphHandler.setMoveEnabled(!z);
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
return T}),B=!0);return B};var x=p.stop;p.stop=function(){x.call(this);this.active=!1;null!=p.status&&null!=p.status.parentNode&&p.status.parentNode.removeChild(p.status);p.status=null};p.pause=function(){return function(){}};return p};EditorUi.prototype.isCompatibleString=function(c){try{var e=mxUtils.parseXml(c),k=this.editor.extractGraphModel(e.documentElement,!0);return null!=k&&0==k.getElementsByTagName("parsererror").length}catch(q){}return!1};EditorUi.prototype.isVisioData=function(c){return 8<
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
return O};Editor.getDiagramNodeXml=function(g){var y=mxUtils.getTextContent(g),H=null;0<y.length?H=Graph.decompress(y):null!=g.firstChild&&(H=mxUtils.getXml(g.firstChild));return H};Editor.extractGraphModelFromPdf=function(g){g=g.substring(g.indexOf(",")+1);g=window.atob&&!mxClient.IS_SF?atob(g):Base64.decode(g,!0);if("%PDF-1.7"==g.substring(0,8)){var y=g.indexOf("EmbeddedFile");if(-1<y){var H=g.indexOf("stream",y)+9;if(0<g.substring(y,H).indexOf("application#2Fvnd.jgraph.mxfile"))return y=g.indexOf("endstream",
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
K.getCell())};var ba=this.getCursorForCell;this.getCursorForCell=function(K){if(!this.isEnabled()||this.isCellLocked(K)){if(null!=this.getClickableLinkForCell(K))return"pointer";if(this.isCellLocked(K))return"default"}return ba.apply(this,arguments)};this.selectRegion=function(K,U){var L=mxEvent.isAltDown(U)?K:null;K=this.getCells(K.x,K.y,K.width,K.height,null,null,L,null,!0);if(this.isToggleEvent(U))for(L=0;L<K.length;L++)this.selectCellForEvent(K[L],U);else this.selectCellsForEvent(K,U);return K};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,t,x,null,1<p,I,c,k,q);t=this.isServices(p)?p>I?390:280:160;this.showDialog(e.container,420,t,!0,!0);e.init()};EditorUi.prototype.openInNewWindow=function(c,e,k){var q=window.open("about:blank");null==q||null==q.document?mxUtils.popup(c,!0):("image/svg+xml"!=e||mxClient.IS_SVG?"image/svg+xml"!=e||k?(c=k?c:btoa(unescape(encodeURIComponent(c))),q.document.write('<html><img style="max-width:100%;" src="data:'+e+";base64,"+ c+'"/></html>')):q.document.write("<html>"+c+"</html>"):q.document.write("<html><pre>"+mxUtils.htmlEntities(c,!1)+"</pre></html>"),q.document.close())};var d=EditorUi.prototype.addChromelessToolbarItems;EditorUi.prototype.isChromelessImageExportEnabled=function(){return"draw.io"!=this.getServiceName()||/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname)};EditorUi.prototype.addChromelessToolbarItems=function(c){if(null!=urlParams.tags){this.tagsDialog=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"/pid/misc.xml"];mxStencilRegistry.libraries.pid2valves=[SHAPES_PATH+"/pid2/mxPidValves.js"];mxStencilRegistry.libraries.pidFlowSensors=[STENCIL_PATH+"/pid/flow_sensors.xml"];mxMarker.getPackageForType=function(g){var y=null;null!=g&&0<g.length&&("ER"==g.substring(0,2)?y="mxgraph.er":"sysML"==g.substring(0,5)&&(y="mxgraph.sysml"));return y};var A=mxMarker.createMarker;mxMarker.createMarker=function(g,y,H,O,P,V,R,W,X,Z){if(null!=H&&null==mxMarker.markers[H]){var Y=this.getPackageForType(H);null!=Y&& mxStencilRegistry.getStencil(Y)}return A.apply(this,arguments)};var N=mxStencil.prototype.drawShape;mxStencil.prototype.drawShape=function(g,y,H,O,P,V){"1"==mxUtils.getValue(y.style,"lineShape",null)&&g.setFillColor(mxUtils.getValue(y.style,mxConstants.STYLE_STROKECOLOR,this.stroke));return N.apply(this,arguments)};PrintDialog.prototype.create=function(g,y){function H(){fa.value=Math.max(1,Math.min(W,Math.max(parseInt(fa.value),parseInt(ea.value))));ea.value=Math.max(1,Math.min(W,Math.min(parseInt(fa.value),
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
J.vertex=!0;S.addCell(J);S.dblClick=function(E,A){if(null!=A&&A!=J)S.setSelectionCell(A);else{A=mxUtils.convertPoint(S.container,mxEvent.getClientX(E),mxEvent.getClientY(E));mxEvent.consume(E);E=S.view.scale;var N=S.view.translate;S.setSelectionCell(v((A.x-3*E)/E-N.x,(A.y-3*E)/E-N.y))}};u=new mxKeyHandler(S);u.bindKey(46,D);u.bindKey(8,D);S.getRubberband().isForceRubberbandEvent=function(E){return 0==E.evt.button&&(null==E.getCell()||E.getCell()==J)};S.panningHandler.isForcePanningEvent=function(E){return 2==
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
var X=this.fill,Z=this.stroke;this.stroke=this.fill=null;var Y=this.configurePointerEvents,ea=V.setStrokeColor;V.setStrokeColor=function(){};var fa=V.setFillColor;V.setFillColor=function(){};W||null==X||(this.configurePointerEvents=function(){});V.handJiggle.passThrough=!0;O.apply(this,arguments);V.handJiggle.passThrough=!1;V.setFillColor=fa;V.setStrokeColor=ea;this.configurePointerEvents=Y;this.stroke=Z;this.fill=X;V.restore();W&&null!=X&&(V.addTolerance=function(){})}O.apply(this,arguments);V.addTolerance=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"...",c[p])})))};EditorUi.prototype.installFormatToolbar=function(J){var c=this.editor.graph,e=document.createElement("div");e.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%;";c.getSelectionModel().addListener(mxEvent.CHANGE,mxUtils.bind(this,function(k,q){0<c.getSelectionCount()?(J.appendChild(e),e.innerHTML="Selected: "+c.getSelectionCount()):null!= e.parentNode&&e.parentNode.removeChild(e)}))};var G=!1;EditorUi.prototype.initFormatWindow=function(){if(!G&&null!=this.formatWindow){G=!0;var J=this.formatWindow.window.toggleMinimized,c=240;this.formatWindow.window.toggleMinimized=function(){J.apply(this,arguments);this.minimized?(c=parseInt(this.div.style.width),this.div.style.width="140px",this.table.style.width="140px",this.div.style.left=parseInt(this.div.style.left)+c-140+"px"):(this.div.style.width=c+"px",this.table.style.width=this.div.style.width,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
f.appendChild(S);f.appendChild(m);G.appendChild(f);var J=F,c,e,k=function(x,C,I,B){var T="data:"==x.substring(0,5);!b.isOffline()||T&&"undefined"===typeof chrome?0<x.length&&b.spinner.spin(document.body,mxResources.get("inserting"))?b.loadImage(x,function(l){b.spinner.stop();b.hideDialog();var n=!1===B?1:null!=C&&null!=I?Math.max(C/l.width,I/l.height):Math.min(1,Math.min(520/l.width,520/l.height));v&&(x=b.convertDataUri(x));d(x,Math.round(Number(l.width)*n),Math.round(Number(l.height)*n),J,c,e)}, function(){b.spinner.stop();d(null);b.showError(mxResources.get("error"),mxResources.get("fileNotFound"),mxResources.get("ok"))}):(b.hideDialog(),d(x,null,null,J,c,e)):(x=b.convertDataUri(x),C=null==C?120:C,I=null==I?100:I,b.hideDialog(),d(x,C,I,J,c,e))},q=function(x,C){if(null!=x){var I=u?null:M.getModel().getGeometry(M.getSelectionCell());null!=I?k(x,I.width,I.height,C):k(x,null,null,C)}else b.hideDialog(),d(null)};this.init=function(){S.focus();if(Graph.fileSupport){S.setAttribute("placeholder",
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
DrawioFile.prototype.autosave=function(b,f,m,d){null==this.lastAutosave&&(this.lastAutosave=Date.now());b=Date.now()-this.lastAutosave<f?b:0;this.clearAutosave();var u=window.setTimeout(mxUtils.bind(this,function(){try{if(this.lastAutosave=null,this.autosaveThread==u&&(this.autosaveThread=null),EditorUi.debug("DrawioFile.autosave",[this],"thread",u,"modified",this.isModified(),"now",this.isAutosaveNow(),"saving",this.savingFile),this.isModified()&&this.isAutosaveNow()){var v=this.isAutosaveRevision(); v&&(this.lastAutosaveRevision=(new Date).getTime());this.save(v,mxUtils.bind(this,function(D){this.autosaveCompleted();null!=m&&m(D)}),mxUtils.bind(this,function(D){null!=d&&d(D)}))}else this.isModified()||this.ui.editor.setStatus(""),null!=m&&m(null)}catch(D){null!=d&&d(D)}}),b);EditorUi.debug("DrawioFile.autosave",[this],"thread",u,"delay",b,"saving",this.savingFile);this.autosaveThread=u};DrawioFile.prototype.isAutosaveNow=function(){return!0};DrawioFile.prototype.autosaveCompleted=function(){};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
mxEvent.getClientX(A),mxEvent.getClientY(A),this.graph.getSubtree(this.state.cell));this.graph.graphHandler.cellWasClicked=!0;this.graph.isMouseTrigger=mxEvent.isMouseEvent(A);this.graph.isMouseDown=!0;c.hoverIcons.reset();mxEvent.consume(A)})))};var n=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){n.apply(this,arguments);null!=this.moveHandle&&(this.moveHandle.style.left=this.state.x+this.state.width+(40>this.state.width?10:0)+2+"px",this.moveHandle.style.top= this.state.y+this.state.height+(40>this.state.height?10:0)+2+"px")};var z=mxVertexHandler.prototype.setHandlesVisible;mxVertexHandler.prototype.setHandlesVisible=function(A){z.apply(this,arguments);null!=this.moveHandle&&(this.moveHandle.style.display=A?"":"none")};var E=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=function(A,N){E.apply(this,arguments);null!=this.moveHandle&&(this.moveHandle.parentNode.removeChild(this.moveHandle),this.moveHandle=null)}};if("undefined"!==typeof Sidebar){var m=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
this.tooltipHandler.show;this.tooltipHandler.show=function(){aa.apply(this,arguments);if(null!=this.div)for(var K=this.div.getElementsByTagName("a"),U=0;U<K.length;U++)null!=K[U].getAttribute("href")&&null==K[U].getAttribute("target")&&K[U].setAttribute("target","_blank")};this.tooltipHandler.getStateForEvent=function(K){return K.sourceState};this.getCursorForMouseEvent=function(K){var U=null==K.state&&null!=K.sourceState&&this.isCellLocked(K.sourceState.cell);return this.getCursorForCell(U?K.sourceState.cell: K.getCell())};var ba=this.getCursorForCell;this.getCursorForCell=function(K){if(!this.isEnabled()||this.isCellLocked(K)){if(null!=this.getClickableLinkForCell(K))return"pointer";if(this.isCellLocked(K))return"default"}return ba.apply(this,arguments)};this.selectRegion=function(K,U){var L=mxEvent.isAltDown(U)?K:null;K=this.getCells(K.x,K.y,K.width,K.height,null,null,L,null,!0);if(this.isToggleEvent(U))for(L=0;L<K.length;L++)this.selectCellForEvent(K[L],U);else this.selectCellsForEvent(K,U);return K};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
0));mxEvent.addListener(la,"change",oa);mxEvent.addListener(la,"keydown",oa);mxEvent.addListener(la,"cut",oa);mxEvent.addListener(la,"paste",oa);mxEvent.addListener(la,"keydown",function(Ga){13==Ga.keyCode&&La.click()});oa=document.createElement("div");oa.style.height="40px";oa.style.marginTop="4px";oa.style.marginBottom="4px";oa.style.whiteSpace="nowrap";oa.style.overflowX="auto";oa.style.overflowY="hidden";oa.appendChild(ha);oa.appendChild(La);aa.appendChild(oa);aa.appendChild(ma);return aa}function I(){if(za&& null!=c)m||b.hideDialog(),c(za,Ba,N.value);else if(d)m||b.hideDialog(),d(na,N.value,Ca,ea);else{var aa=N.value;null!=aa&&0<aa.length&&b.pickFolder(b.mode,function(la){b.createFile(aa,na,null!=ea&&0<ea.length?ea:null,null,function(){b.hideDialog()},null,la,null,null!=fa&&0<fa.length?fa:null)},b.mode!=App.MODE_GOOGLE||null==b.stateArg||null==b.stateArg.folderId)}}function B(aa,la,ma,oa,ha,ja,sa){null!=da&&(da.style.backgroundColor="transparent",da.style.border="1px solid transparent");U.removeAttribute("disabled");
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];StyleFormatPanel.prototype.customColorSchemes=null;StyleFormatPanel.prototype.findCommonProperties=function(g,y,H){if(null!=y){var O=function(V){if(null!=V)if(H)for(var R=0;R<V.length;R++)y[V[R].name]=V[R];else for(var W in y){var X=!1;for(R=0;R<V.length;R++)if(V[R].name==W&&V[R].type==y[W].type){X=!0;break}X||delete y[W]}},P=this.editorUi.editor.graph.view.getState(g);
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
this.customFonts)))}finally{H.getModel().endUpdate()}}}));this.editorUi.showDialog(P.container,380,Editor.enableWebFonts?250:180,!0,!0);P.init()}),n,null,!0)})))}})();function DiagramPage(b,f){this.node=b;null!=f?this.node.setAttribute("id",f):null==this.getId()&&this.node.setAttribute("id",Editor.guid())}DiagramPage.prototype.node=null;DiagramPage.prototype.root=null;DiagramPage.prototype.viewState=null;DiagramPage.prototype.getId=function(){return this.node.getAttribute("id")};DiagramPage.prototype.getName=function(){return this.node.getAttribute("name")};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
n.value;n.parentNode.removeChild(n);z.parentNode.removeChild(z)}catch(E){b.handleError(E)}t.innerHTML='<div style="padding-top:10px;text-align:center;"><img src="'+IMAGE_PATH+'/spin.gif" valign="middle"> '+mxUtils.htmlEntities(mxResources.get("loading"))+"...</div>";e=b.canReplyToReplies();b.commentsSupported()?b.getComments(function(E){function A(N){if(null!=N){N.sort(function(L,U){return new Date(L.modifiedDate)-new Date(U.modifiedDate)});for(var Q=0;Q<N.length;Q++)A(N[Q].replies)}}E.sort(function(N,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
p?4E3:3E4);B=!0}return B};EditorUi.prototype.setCurrentFile=function(c){null!=c&&(c.opened=new Date);this.currentFile=c};EditorUi.prototype.getCurrentFile=function(){return this.currentFile};EditorUi.prototype.isExportToCanvas=function(){return this.editor.isExportToCanvas()};EditorUi.prototype.createImageDataUri=function(c,e,k,q){c=c.toDataURL("image/"+k);if(null!=c&&6<c.length)null!=e&&(c=Editor.writeGraphModelToPng(c,"tEXt","mxfile",encodeURIComponent(e))),0<q&&(c=Editor.writeGraphModelToPng(c,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
parseFloat(y[3])+6,g.setAttribute("viewBox",y[0]+" "+y[1]+" "+w+" "+h))))));return V};Graph.prototype.setShadowVisible=function(g,y){mxClient.IS_SVG&&!mxClient.IS_SF&&(y=null!=y?y:!0,(this.shadowVisible=g)?this.view.getDrawPane().setAttribute("filter","url(#"+this.shadowId+")"):this.view.getDrawPane().removeAttribute("filter"),y&&this.fireEvent(new mxEventObject("shadowVisibleChanged")))};Graph.prototype.selectUnlockedLayer=function(){if(null==this.defaultParent){var g=this.model.getChildCount(this.model.root), y=0;do var H=this.model.getChildAt(this.model.root,y);while(y++<g&&"1"==mxUtils.getValue(this.getCellStyle(H),"locked","0"));null!=H&&this.setDefaultParent(H)}};mxStencilRegistry.libraries.mockup=[SHAPES_PATH+"/mockup/mxMockupButtons.js"];mxStencilRegistry.libraries.arrows2=[SHAPES_PATH+"/mxArrows.js"];mxStencilRegistry.libraries.atlassian=[STENCIL_PATH+"/atlassian.xml",SHAPES_PATH+"/mxAtlassian.js"];mxStencilRegistry.libraries.bpmn=[SHAPES_PATH+"/mxBasic.js",STENCIL_PATH+"/bpmn.xml",SHAPES_PATH+
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
g.ownerSVGElement))}};var n=Graph.prototype.refresh;Graph.prototype.refresh=function(){n.apply(this,arguments);this.refreshBackgroundImage()};Graph.prototype.refreshBackgroundImage=function(){null!=this.backgroundImage&&null!=this.backgroundImage.originalSrc&&(this.setBackgroundImage(this.backgroundImage),this.view.validateBackgroundImage())};var z=Graph.prototype.loadStylesheet;Graph.prototype.loadStylesheet=function(){z.apply(this,arguments);this.currentStyle="default-style2"};Graph.prototype.handleCustomLink=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
delete F[S];return D};EditorUi.prototype.patchViewState=function(b,f){if(null!=b.viewState&&null!=f){b==this.currentPage&&(b.viewState=this.editor.graph.getViewState());for(var m in f)try{this.patchViewStateProperty(b,f,m)}catch(d){}b==this.currentPage&&this.editor.graph.setViewState(b.viewState,!0)}};EditorUi.prototype.patchViewStateProperty=function(b,f,m){b.viewState[m]=JSON.parse(f[m])};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
e.addListener(mxEvent.SIZE,f);e.container.addEventListener("scroll",d);e.view.addListener("unitChanged",this.unitListener);b.addListener("pageViewChanged",this.pageListener);b.addListener("pageScaleChanged",this.pageListener);b.addListener("pageFormatChanged",this.pageListener);this.setStyle=function(x){G=x;S.style.background=G.bkgClr;q()};this.origGuideMove=mxGuide.prototype.move;mxGuide.prototype.move=function(x,C,I,B){if(m&&4<x.height||!m&&4<x.width){if(null!=M.guidePart)try{c.putImageData(M.guidePart.imgData1,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
ma[Xa],0<ia.length&&(oa=document.createElement("div"),oa.className="geTempDlgImportCat",oa.innerText=mxResources.get(Xa,null,Xa),da.appendChild(oa),B(ia,aa,la,null,!0))}function T(ia,aa){qa.innerText="";x();var la=Math.floor(qa.offsetWidth/150)-1;aa=!aa&&ia.length>la?la:ia.length;for(var ma=0;ma<aa;ma++){var oa=ia[ma];oa.isCategory=!0;var ha=document.createElement("div"),ja=mxResources.get(oa.title);null==ja&&(ja=oa.title.substring(0,1).toUpperCase()+oa.title.substring(1));ha.className="geTempDlgNewDiagramCatItem"; ha.setAttribute("title",ja);ja=mxUtils.htmlEntities(ja);15<ja.length&&(ja=ja.substring(0,15)+"&hellip;");null==O&&(I(!0),x(ha,"geTempDlgNewDiagramCatItemActive",oa));var sa=document.createElement("div");sa.className="geTempDlgNewDiagramCatItemImg";var ta=document.createElement("img");ta.src=NEW_DIAGRAM_CATS_PATH+"/"+oa.img;sa.appendChild(ta);ha.appendChild(sa);sa=document.createElement("div");sa.className="geTempDlgNewDiagramCatItemLbl";sa.innerHTML=ja;ha.appendChild(sa);qa.appendChild(ha);(function(La, Ga){mxEvent.addListener(ha,"click",function(){O!=Ga&&(I(!0),x(Ga,"geTempDlgNewDiagramCatItemActive",La))});mxEvent.addListener(ha,"dblclick",C)})(oa,ha)}ha=document.createElement("div");ha.className="geTempDlgNewDiagramCatItem";ja=mxResources.get("showAllTemps");ha.setAttribute("title",ja);sa=document.createElement("div");sa.className="geTempDlgNewDiagramCatItemImg";sa.innerText="...";sa.style.fontSize="32px";ha.appendChild(sa);sa=document.createElement("div");sa.className="geTempDlgNewDiagramCatItemLbl"; sa.innerText=ja;ha.appendChild(sa);qa.appendChild(ha);mxEvent.addListener(ha,"click",function(){function La(){var ya=Ga.querySelector(".geTemplateDrawioCatLink");null!=ya?ya.click():setTimeout(La,200)}fa=!0;var Ga=L.querySelector(".geTemplatesList");Ga.style.display="block";Ba.style.width="";xa.style.display="";xa.value="";Y=null;La()});na.style.display=ia.length<=la?"none":""}function l(ia,aa,la){function ma(Ka,Xa){Ka=mxResources.get(Ka,null,Ka.substring(0,1).toUpperCase()+Ka.substring(1));var Pa=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
g.baseUrl||H.crossOriginImages&&H.isCorsEnabledForUrl(O)?"chrome-extension://"==O.substring(0,19)||mxClient.IS_CHROMEAPP||(O=y.apply(this,arguments)):O=PROXY_URL+"?url="+encodeURIComponent(O)}return O};return g};Editor.createSvgDataUri=function(g){return"data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(g)))};Editor.prototype.convertImageToDataUri=function(g,y){try{var H=!0,O=window.setTimeout(mxUtils.bind(this,function(){H=!1;y(Editor.svgBrokenImage.src)}),this.timeout);if(/(\.svg)$/i.test(g))mxUtils.get(g,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
c?c:"",extras:JSON.stringify(p),scale:x,border:C,w:l&&isFinite(l)?l:null,h:n&&isFinite(n)?n:null}};EditorUi.prototype.setMode=function(c,e){this.mode=c};EditorUi.prototype.getDiagramId=function(){var c=window.location.hash;null!=c&&0<c.length&&(c=c.substring(1));if(null!=c&&1<c.length){var e=c.indexOf("#");0<=e&&(c=c.substring(0,e))}return c};EditorUi.prototype.getHashObject=function(){var c=window.location.hash,e={};if(null!=c&&0<c.length){var k=c.lastIndexOf("#");if(0<k){c=decodeURIComponent(c.substring(k+ 1));try{e=JSON.parse(c)}catch(q){}}}return e};EditorUi.prototype.updateHashObject=function(){if(null!=this.currentFile&&""!=this.currentFile.getHash()&&null!=this.currentPage&&0<this.getSelectedPageIndex()){var c=this.getHashObject();c.pageId=this.currentPage.getId();this.setHashObject(c)}else this.setHashObject(null)};EditorUi.prototype.setHashObject=function(c){if(Editor.enableHashObjects){var e=window.location.hash;if(null==e||""==e)e="#";var k=e.lastIndexOf("#");0<k&&(e=e.substring(0,k));try{null==
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
520,!0,!0,null,null,null,null,!0);this.importCsvDialog.init()};EditorUi.prototype.showCustomLayoutDialog=function(c){this.loadOrgChartLayouts(mxUtils.bind(this,function(){var e=new TextareaDialog(this,mxResources.get("layout"),c,mxUtils.bind(this,function(k){if(0<k.length)try{var q=JSON.parse(k);this.executeLayouts(this.editor.graph.createLayouts(q));this.customLayoutConfig=q;this.hideDialog()}catch(p){this.handleError(p)}}),null,null,null,null,mxUtils.bind(this,function(k,q){var p=mxUtils.button(mxResources.get("copy"), mxUtils.bind(this,function(){try{var t=q.value;q.value=JSON.stringify(JSON.parse(t));q.focus();mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode?q.select():document.execCommand("selectAll",!1,null);document.execCommand("copy");this.alert(mxResources.get("copiedToClipboard"));q.value=t}catch(x){this.handleError(x)}}));p.setAttribute("title","copy");p.className="geBtn";k.appendChild(p)}),!0,null,null,"https://www.drawio.com/doc/faq/apply-layouts");this.showDialog(e.container,620,460,!0,!0);e.init()}))};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(z){G=z};this.setAutoScroll=function(z){S=z};this.setOpenFill=function(z){J=z};this.setStopClickEnabled=function(z){k=z};this.setSelectInserted=function(z){q=z};this.setSmoothing=function(z){m=z};this.setPerfectFreehandMode=function(z){t=z};this.isPerfectFreehandMode=function(){return t};this.setBrushSize=function(z){p.size=z};this.getBrushSize=function(){return p.size};var x=function(z){e=z;b.getRubberband().setEnabled(!z);b.graphHandler.setSelectEnabled(!z);b.graphHandler.setMoveEnabled(!z);
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
K.getCell())};var ba=this.getCursorForCell;this.getCursorForCell=function(K){if(!this.isEnabled()||this.isCellLocked(K)){if(null!=this.getClickableLinkForCell(K))return"pointer";if(this.isCellLocked(K))return"default"}return ba.apply(this,arguments)};this.selectRegion=function(K,U){var L=mxEvent.isAltDown(U)?K:null;K=this.getCells(K.x,K.y,K.width,K.height,null,null,L,null,!0);if(this.isToggleEvent(U))for(L=0;L<K.length;L++)this.selectCellForEvent(K[L],U);else this.selectCellsForEvent(K,U);return K};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
x,e.container.scrollTop=C,this.pasteCells(t,k,!1,!0)}catch(I){this.handleError(I)}}),0)}}catch(I){this.handleError(I)}}),!0);var p=this.isSelectionAllowed;this.isSelectionAllowed=function(t){return mxEvent.getSource(t)==k?!0:p.apply(this,arguments)}};EditorUi.prototype.setCurrentTheme=function(c,e){mxSettings.setUi(c);(e=this.doSetCurrentTheme(c)||e)||this.alert(mxResources.get("restartForChangeRequired"))};EditorUi.prototype.isDefaultTheme=function(c){return""==c||"dark"==c||"default"==c||"kennedy"==
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
this.sketchMainMenuElt.appendChild(this.sketchPickerMenuElt)):(this.sketchPickerMenuElt.style.cssText="position:absolute;left:10px;border-radius:4px;padding:0px 4px 4px;white-space:nowrap;max-height:100%;z-index:1;width:48px;box-sizing:border-box;transform:translate(0, -50%);top:50%;user-select:none;",this.sketchWrapperElt.appendChild(this.sketchPickerMenuElt));mxClient.IS_POINTER&&(this.sketchPickerMenuElt.style.touchAction="none")}};EditorUi.prototype.getNetworkStatus=function(){var c=null;if(this.isOffline(!0))c= mxResources.get("offline");else{var e=this.getCurrentFile();null!=e&&(e.invalidChecksum?c=mxResources.get("error")+": "+mxResources.get("checksum"):null==e.sync||e.sync.enabled&&e.sync.isRealtimeActive()?null==e.sync||e.sync.isConnected()?e.isRealtimeEnabled()&&e.isRealtimeSupported()&&1<e.getRealtimeState()&&(c=e.getRealtimeError(),c=mxResources.get("realtimeCollaboration")+": "+(null!=c&&null!=c.message?c.message:mxResources.get("error"))):c=mxResources.get("notConnected"):c=mxResources.get("realtimeCollaboration")+ ": "+mxResources.get("disabled"))}return c};EditorUi.prototype.createMenubarForTheme=function(c){if("simple"==c||"sketch"==c){if(null==this.sketchMenubarElt){this.sketchMenubarElt=document.createElement("div");this.sketchMenubarElt.className="geToolbarContainer";if("simple"==c){this.sketchMenubarElt.style.cssText="position:relative;flex-grow:0.5;overflow:visible;"+("1"!=urlParams.embed?"flex-shrink:0;":"min-width:0;")+"display:flex;white-space:nowrap;user-select:none;justify-content:flex-end;align-items:center;flex-wrap:nowrap;gap:6px;";
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
g.prototype.lineTo=function(V,R){this.passThrough?this.originalLineTo.apply(this.canvas,arguments):(this.addOp(this.lineOp,V,R),this.lastX=V,this.lastY=R)};g.prototype.moveTo=function(V,R){this.passThrough?this.originalMoveTo.apply(this.canvas,arguments):(this.addOp(this.moveOp,V,R),this.lastX=V,this.lastY=R,this.firstX=V,this.firstY=R)};g.prototype.close=function(){this.passThrough?this.originalClose.apply(this.canvas,arguments):this.addOp(this.closeOp)};g.prototype.quadTo=function(V,R,W,X){this.passThrough?
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
H=y.editor.graph;if(H.isEnabled()){var O=y.getCurrentFile();null!=O&&O.isAutosaveOptional()&&g.appendChild(this.createOption(mxResources.get("autosave"),function(){return y.editor.autosave},function(R){y.editor.setAutosave(R);y.editor.autosave&&O.isModified()&&O.fileChanged()},{install:function(R){this.listener=function(){R(y.editor.autosave)};y.editor.addListener("autosaveChanged",this.listener)},destroy:function(){y.editor.removeListener(this.listener)}}))}if(this.isMathOptionVisible()&&H.isEnabled()&&
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
0;U<A.length;U++){var g=e.view.getState(e.model.getTerminal(A[U],!1));null!=g&&(!N&&Math.min(g.x+g.width,Q.x+Q.width)>=Math.max(g.x,Q.x)||N&&Math.min(g.y+g.height,Q.y+Q.height)>=Math.max(g.y,Q.y))&&L.push(g)}L.sort(function(y,H){return N?y.x+y.width-H.x-H.width:y.y+y.height-H.y-H.height})}return L}function J(A,N){var Q=F(A),L=N==mxConstants.DIRECTION_EAST||N==mxConstants.DIRECTION_WEST;(Q==mxConstants.DIRECTION_EAST||Q==mxConstants.DIRECTION_WEST)==L&&Q!=N?c.actions.get("selectParent").funct():Q== N?(N=e.getOutgoingTreeEdges(A),null!=N&&0<N.length&&e.setSelectionCell(e.model.getTerminal(N[0],!1))):(Q=e.getIncomingTreeEdges(A),null!=Q&&0<Q.length&&(L=S(e.model.getTerminal(Q[0],!0),L,A),A=e.view.getState(A),null!=A&&(A=mxUtils.indexOf(L,A),0<=A&&(A+=N==mxConstants.DIRECTION_NORTH||N==mxConstants.DIRECTION_WEST?-1:1,0<=A&&A<=L.length-1&&e.setSelectionCell(L[A].cell)))))}var c=this,e=c.editor.graph,k=e.getModel(),q=c.menus.createPopupMenu;c.menus.createPopupMenu=function(A,N,Q){q.apply(this,arguments);
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
I.style.paddingRight=18*B.childNodes.length+"px"}};EditorUi.prototype.addLibraryEntries=function(c,e){for(var k=0;k<c.length;k++){var q=c[k],p=q.data;if(null!=p){p=this.convertDataUri(p);var t="shape=image;verticalLabelPosition=bottom;verticalAlign=top;imageAspect=0;";"fixed"==q.aspect&&(t+="aspect=fixed;");e.appendChild(this.sidebar.createVertexTemplate(t+"image="+p,q.w,q.h,"",q.title||"",!1,null,!0))}else null!=q.xml&&(p=this.stringToCells("<"==q.xml.charAt(0)?q.xml:Graph.decompress(q.xml)),0<p.length&& e.appendChild(this.sidebar.createVertexTemplateFromCells(p,q.w,q.h,q.title||"",!0,null,!0)))}};EditorUi.prototype.getResource=function(c){return null!=c?c[mxLanguage]||c.main:null};EditorUi.prototype.footerHeight=0;"1"==urlParams.savesidebar&&(Sidebar.prototype.thumbWidth=64,Sidebar.prototype.thumbHeight=64);EditorUi.initTheme=function(){"atlas"==Editor.currentTheme&&(mxClient.link("stylesheet",STYLE_PATH+"/atlas.css"),"undefined"!==typeof Toolbar&&(Toolbar.prototype.unselectedBackground="linear-gradient(rgb(255, 255, 255) 0px, rgb(242, 242, 242) 100%)",
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
null;EditorUi.prototype.shareCursorPosition=!0;EditorUi.prototype.showRemoteCursors=!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var c=document.createElement("canvas");EditorUi.prototype.canvasSupported=!(!c.getContext||!c.getContext("2d"))}catch(p){}try{var e=document.createElement("canvas"),k=new Image;k.onload=function(){try{e.getContext("2d").drawImage(k,0,0);var p=e.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=p&&6<p.length}catch(t){}};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
L.cell.id,L.text),Q=!1);Q||A++;N++});console.log("states checked",N,"invalid",A)}));d.actions.addAction("testCheckFile",mxUtils.bind(this,function(){var l=null!=d.pages&&null!=d.getCurrentFile()?d.getCurrentFile().getAnonymizedXmlForPages(d.pages):"";l=new TextareaDialog(d,"Paste Data:",l,function(n){if(0<n.length)try{var z=function(L){function U(Z){if(null==X[Z]){if(X[Z]=!0,null!=H[Z]){for(;0<H[Z].length;){var Y=H[Z].pop();U(Y)}delete H[Z]}}else mxLog.debug(g+": Visited: "+Z)}var g=L.parentNode.id,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
libs:ia.getAttribute("libs"),clibs:ia.getAttribute("clibs"),title:ia.getAttribute("title")}),ia=ia.nextSibling;T(Ia)}});var Va=function(ia,aa,la){Ca.style.display="";Qa.stop();U=!1;if(g)g=!1;else if(aa)da.innerText=aa;else{la=la||{};aa=0;for(var ma in la)aa+=la[ma].length;0==ia.length&&0==aa?da.innerText=mxResources.get("noDiagrams"):B(ia,!1,W,0==aa?null:la)}};z(R);var Ua=null;mxEvent.addListener(xa,"keyup",N);mxEvent.addListener(xa,"search",N);mxEvent.addListener(xa,"input",N);mxEvent.addListener(ka, "click",function(ia){C(!1,!1)});S&&mxEvent.addListener(Aa,"click",function(ia){C(!1,!0)});J&&mxEvent.addListener(L.querySelector(".geTempDlgLinkToDiagramBtn"),"click",function(ia){C(!0)});mxEvent.addListener(L.querySelector(".geTempDlgCancelBtn"),"click",function(){null!=m&&m();e||b.hideDialog(!0)})};TemplatesDialog.tagsList={};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
za,this.stylesheet=da,this.refresh());return Ba};var I=mxCellRenderer.prototype.destroy;mxCellRenderer.prototype.destroy=function(g){I.apply(this,arguments);null!=g.secondLabel&&(g.secondLabel.destroy(),g.secondLabel=null)};mxCellRenderer.prototype.getShapesForState=function(g){return[g.shape,g.text,g.secondLabel,g.control]};var B=mxGraphView.prototype.resetValidationState;mxGraphView.prototype.resetValidationState=function(){B.apply(this,arguments);this.enumerationState=0};var T=mxGraphView.prototype.stateValidated;
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"ready";x.postMessage(t,"*");if("json"==urlParams.proto){var C=this.editor.graph.openLink;this.editor.graph.openLink=function(I,B,T){C.apply(this,arguments);x.postMessage(JSON.stringify({event:"openLink",href:I,target:B,allowOpener:T}),"*")}}};EditorUi.prototype.createEmbedButton=function(c,e,k,q){var p="simple"==Editor.currentTheme||"sketch"==Editor.currentTheme||"min"==Editor.currentTheme,t=document.createElement("button");t.setAttribute("title",c+(null!=k?" ("+k+")":""));t.style.marginLeft="6px";
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
EditorUi.prototype.convertImages=function(c,e,k,q){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImages");return this.editor.convertImages(c,e,k,q)};EditorUi.prototype.convertImageToDataUri=function(c,e){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImageToDataUri");return this.editor.convertImageToDataUri(c,e)};EditorUi.prototype.base64Encode=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: base64Encode");return Editor.base64Encode(c)};EditorUi.prototype.updateCRC=function(c,e,k,q){EditorUi.logEvent("SHOULD NOT BE CALLED: updateCRC");
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"sketchStyle","rough")?this.createComicCanvas(V):this.createRoughCanvas(V)};var H=mxImageShape.prototype.paintVertexShape;mxImageShape.prototype.paintVertexShape=function(V,R,W,X,Z){null!=V.handJiggle&&V.handJiggle.passThrough||H.apply(this,arguments)};var O=mxShape.prototype.paint;mxShape.prototype.paint=function(V){var R=V.addTolerance,W=!0;null!=this.style&&(W="1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1"));if(null!=V.handJiggle&&V.handJiggle.constructor==g&&!this.outline){V.save();
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
(q<<5)-q+this.hashValue(c.childNodes[p],e,k)<<0}else if(null!=c&&"function"!==typeof c){c=String(c);e=0;null!=k&&(k.byteCount+=c.length);for(p=0;p<c.length;p++)e=(e<<5)-e+c.charCodeAt(p)<<0;q^=e}return q};EditorUi.prototype.descriptorChanged=function(){};EditorUi.prototype.restoreLibraries=function(){};EditorUi.prototype.saveLibrary=function(c,e,k,q,p,t,x){};EditorUi.prototype.isScratchpadEnabled=function(){return isLocalStorage||mxClient.IS_CHROMEAPP};EditorUi.prototype.toggleScratchpad=function(){this.isScratchpadEnabled()&&
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"4px");null!=Y&&na.setAttribute("title",Y);null!=ea&&(W=function(){ea.isEnabled()?(na.removeAttribute("disabled"),na.style.cursor="pointer"):(na.setAttribute("disabled","disabled"),na.style.cursor="default")},ea.addListener("stateChanged",W),x.addListener("enabledChanged",W),W());return na}function e(W,X,Z){Z=document.createElement("div");Z.className="geMenuItem";Z.style.display="inline-block";Z.style.verticalAlign="top";Z.style.marginRight="6px";Z.style.padding="0 4px 0 4px";Z.style.height="30px";
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
Z&&Z()}}catch(Ma){this.handleError(Ma)}};EditorUi.prototype.getSearch=function(c){var e="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=c&&0<window.location.search.length){var k="?",q;for(q in urlParams)0>mxUtils.indexOf(c,q)&&null!=urlParams[q]&&(e+=k+q+"="+urlParams[q],k="&")}else e=window.location.search;return e};EditorUi.prototype.getUrl=function(c){c=null!=c?c:window.location.pathname;var e=0<c.indexOf("?")?1:0;if("1"==urlParams.offline)c+=window.location.search;else{var k="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "), q;for(q in urlParams)0>mxUtils.indexOf(k,q)&&(c=0==e?c+"?":c+"&",null!=urlParams[q]&&(c+=q+"="+urlParams[q],e++))}return c};EditorUi.prototype.showLinkDialog=function(c,e,k,q,p){c=new LinkDialog(this,c,e,k,!0,q,p);this.showDialog(c.container,560,130,!0,!0);c.init()};EditorUi.prototype.getServiceCount=function(c){var e=1;null==this.drive&&"function"!==typeof window.DriveClient||e++;null==this.dropbox&&"function"!==typeof window.DropboxClient||e++;null==this.oneDrive&&"function"!==typeof window.OneDriveClient||
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
[];this.traverse(u,!0,mxUtils.bind(this,function(F,K){var M=null!=K&&this.isTreeEdge(K);M&&v.push(K);F==u||null!=K&&!M||v.push(F);return(null==K||M)&&(F==u||!this.model.isCollapsed(F))}));this.model.setCollapsed(u,d);for(var D=0;D<v.length;D++)this.model.setVisible(v[D],!d)}finally{this.model.endUpdate()}};Graph.prototype.isTreeEdge=function(d){return!this.isEdgeIgnored(d)};Graph.prototype.getTreeEdges=function(d,u,v,D,F,K){return this.model.filterCells(this.getEdges(d,u,v,D,F,K),mxUtils.bind(this, function(M){return this.isTreeEdge(M)}))};Graph.prototype.getIncomingTreeEdges=function(d,u){return this.getTreeEdges(d,u,!0,!1,!1)};Graph.prototype.getOutgoingTreeEdges=function(d,u){return this.getTreeEdges(d,u,!1,!0,!1)};var f=EditorUi.prototype.init;EditorUi.prototype.init=function(){f.apply(this,arguments);this.editor.isChromelessView()&&!this.editor.editable||this.addTrees()};EditorUi.prototype.addTrees=function(){function d(A){return k.isVertex(A)&&v(A)}function u(A){var N=!1;null!=A&&(N="1"==
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
da&&1==Va.length){I.view.validate();var ta=new mxHierarchicalLayout(I,"horizontalflow"==da?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);ta.intraCellSpacing=R;ta.parallelEdgeSpacing=V;ta.interRankCellSpacing=W;ta.disableEdgeStyle=!1;this.executeLayout(function(){ta.execute(I.getDefaultParent(),Ua);I.moveCells(Ua,ea,fa)},!0,Z);Z=null}else if("orgchart"==da){I.view.validate();var La=new mxOrgChartLayout(I,2,W,R),Ga=La.isVertexIgnored;La.isVertexIgnored=function(Ma){return Ga.apply(this,arguments)|| 0>mxUtils.indexOf(t,Ma)};this.executeLayout(function(){La.execute(I.getDefaultParent());ma()},!0,Z);Z=null}else if("organic"==da||"auto"==da&&Ua.length>t.length){I.view.validate();var ya=new mxFastOrganicLayout(I);ya.forceConstant=3*R;ya.disableEdgeStyle=!1;ya.resetEdges=!1;var Ja=ya.isVertexIgnored;ya.isVertexIgnored=function(Ma){return Ja.apply(this,arguments)||0>mxUtils.indexOf(t,Ma)};this.executeLayout(function(){ya.execute(I.getDefaultParent());ma()},!0,Z);Z=null}}this.hideDialog()}finally{I.model.endUpdate()}null!=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
return null!=this.corsRegExp&&this.corsRegExp.test(g)||"https://raw.githubusercontent.com/"===g.substring(0,34)||"https://fonts.googleapis.com/"===g.substring(0,29)||"https://fonts.gstatic.com/"===g.substring(0,26)};Editor.prototype.createImageUrlConverter=function(){var g=new mxUrlConverter;g.updateBaseUrl();var y=g.convert,H=this;g.convert=function(O){if(null!=O){var P="http://"==O.substring(0,7)||"https://"==O.substring(0,8);P&&!navigator.onLine?O=Editor.svgBrokenImage.src:!P||O.substring(0,g.baseUrl.length)== g.baseUrl||H.crossOriginImages&&H.isCorsEnabledForUrl(O)?"chrome-extension://"==O.substring(0,19)||mxClient.IS_CHROMEAPP||(O=y.apply(this,arguments)):O=PROXY_URL+"?url="+encodeURIComponent(O)}return O};return g};Editor.createSvgDataUri=function(g){return"data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(g)))};Editor.prototype.convertImageToDataUri=function(g,y){try{var H=!0,O=window.setTimeout(mxUtils.bind(this,function(){H=!1;y(Editor.svgBrokenImage.src)}),this.timeout);if(/(\.svg)$/i.test(g))mxUtils.get(g,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
Math.round(25*Math.random()))):/\s/.test(p)?k.push(" "):k.push("?"):k.push(e?"0":Math.round(9*Math.random()))}return k.join("")};EditorUi.prototype.anonymizePatch=function(c){if(null!=c[EditorUi.DIFF_INSERT])for(var e=0;e<c[EditorUi.DIFF_INSERT].length;e++)try{var k=mxUtils.parseXml(c[EditorUi.DIFF_INSERT][e].data).documentElement.cloneNode(!1);null!=k.getAttribute("name")&&k.setAttribute("name",this.anonymizeString(k.getAttribute("name")));c[EditorUi.DIFF_INSERT][e].data=mxUtils.getXml(k)}catch(t){c[EditorUi.DIFF_INSERT][e].data= t.message}if(null!=c[EditorUi.DIFF_UPDATE]){for(var q in c[EditorUi.DIFF_UPDATE]){var p=c[EditorUi.DIFF_UPDATE][q];null!=p.name&&(p.name=this.anonymizeString(p.name));null!=p.cells&&(e=mxUtils.bind(this,function(t){var x=p.cells[t];if(null!=x){for(var C in x)null!=x[C].value&&(x[C].value="["+x[C].value.length+"]"),null!=x[C].xmlValue&&(x[C].xmlValue="["+x[C].xmlValue.length+"]"),null!=x[C].style&&(x[C].style="["+x[C].style.length+"]"),mxUtils.isEmptyObject(x[C])&&delete x[C];mxUtils.isEmptyObject(x)&& delete p.cells[t]}}),e(EditorUi.DIFF_INSERT),e(EditorUi.DIFF_UPDATE),mxUtils.isEmptyObject(p.cells)&&delete p.cells);mxUtils.isEmptyObject(p)&&delete c[EditorUi.DIFF_UPDATE][q]}mxUtils.isEmptyObject(c[EditorUi.DIFF_UPDATE])&&delete c[EditorUi.DIFF_UPDATE]}return c};EditorUi.prototype.anonymizeAttributes=function(c,e){if(null!=c.attributes)for(var k=0;k<c.attributes.length;k++)"as"!=c.attributes[k].name&&c.setAttribute(c.attributes[k].name,this.anonymizeString(c.attributes[k].value,e));if(null!=c.childNodes)for(k=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
L.pagecount=null!=c.pages?c.pages.length:1;L.page=null!=c.currentPage?c.currentPage.getName():"";L.pagenumber=null!=c.pages&&null!=c.currentPage?mxUtils.indexOf(c.pages,c.currentPage)+1:1;return L};var l=e.getGlobalVariable;e.getGlobalVariable=function(L){var U=c.getCurrentFile();return"filename"==L&&null!=U?U.getTitle():"page"==L&&null!=c.currentPage?c.currentPage.getName():"pagenumber"==L?null!=c.currentPage&&null!=c.pages?mxUtils.indexOf(c.pages,c.currentPage)+1:1:"pagecount"==L?null!=c.pages? c.pages.length:1:l.apply(this,arguments)};var n=null,z=null;this.addListener("fileDescriptorChanged",mxUtils.bind(this,function(){var L=this.getCurrentFile(),U=null!=L&&null!=L.getTitle()?L.getTitle():this.defaultFilename;n!=U&&L==z&&(e.invalidateDescendantsWithPlaceholders(e.model.getRoot()),e.view.validate());n=U;z=L}));var E=e.labelLinkClicked;e.labelLinkClicked=function(L,U,g){var y=U.getAttribute("href");if(null==y||!e.isCustomLink(y)||!mxEvent.isTouchEvent(g)&&mxEvent.isPopupTrigger(g))E.apply(this,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(g,y){if("undefined"===typeof window.MathJax&&!mxClient.IS_IE&&!mxClient.IS_IE11){var H=function(){O=null;if(0<Editor.mathJaxQueue.length)Editor.doMathJaxRender(Editor.mathJaxQueue.shift());else Editor.onMathJaxDone()};g=null!=g?g:DRAW_MATH_URL+"/startup.js";Editor.mathJaxQueue=[];var O=null;Editor.doMathJaxRender=function(R){try{null==O?(MathJax.typesetClear([R]),MathJax.typeset([R]),H()):O!=R&&Editor.mathJaxQueue.push(R)}catch(W){MathJax.typesetClear([R]),null!=W.retry?(O=R,W.retry.then(function(){MathJax.typesetPromise([R]).then(H)["catch"](function(X){console.log("Error in MathJax.typesetPromise: "+
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(){var c=this.getCurrentFile();return null!=c?c.canReplyToReplies():!0};EditorUi.prototype.canComment=function(){var c=this.getCurrentFile();return null!=c?c.canComment():!0};EditorUi.prototype.newComment=function(c,e){var k=this.getCurrentFile();return null!=k?k.newComment(c,e):new DrawioComment(this,null,c,Date.now(),Date.now(),!1,e)};EditorUi.prototype.isRevisionHistorySupported=function(){var c=this.getCurrentFile();return null!=c&&c.isRevisionHistorySupported()};EditorUi.prototype.getRevisions=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
q;for(q in urlParams)0>mxUtils.indexOf(k,q)&&(c=0==e?c+"?":c+"&",null!=urlParams[q]&&(c+=q+"="+urlParams[q],e++))}return c};EditorUi.prototype.showLinkDialog=function(c,e,k,q,p){c=new LinkDialog(this,c,e,k,!0,q,p);this.showDialog(c.container,560,130,!0,!0);c.init()};EditorUi.prototype.getServiceCount=function(c){var e=1;null==this.drive&&"function"!==typeof window.DriveClient||e++;null==this.dropbox&&"function"!==typeof window.DropboxClient||e++;null==this.oneDrive&&"function"!==typeof window.OneDriveClient|| e++;null!=this.gitHub&&e++;null!=this.gitLab&&e++;c&&isLocalStorage&&"1"==urlParams.browser&&e++;return e};EditorUi.prototype.updateUi=function(){this.updateButtonContainer();this.updateActionStates();var c=this.getCurrentFile(),e=null!=c||"1"==urlParams.embed&&this.editor.graph.isEnabled();this.menus.get("viewPanels").setEnabled(e);this.menus.get("viewZoom").setEnabled(e);var k=("1"!=urlParams.embed||"1"==urlParams.embedRT||!this.editor.graph.isEnabled())&&(null==c||c.isRestricted());this.actions.get("makeCopy").setEnabled(!k);
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
else throw Error(mxResources.get("readOnly"));}catch(D){if(null!=m)m(D);else throw D;}};DrawioFile.prototype.createData=function(){var b=this.ui.pages;if(this.isRealtime()&&(this.ui.pages=this.ownPages,null!=this.ui.currentPage)){var f=this.ui.getPageById(this.ui.currentPage.getId(),this.ownPages);null!=f&&(f.viewState=this.ui.editor.graph.getViewState(),f.needsUpdate=!0)}f=this.ui.getFileData(null,null,null,null,null,null,null,null,this,!this.isCompressed());this.ui.pages=b;return f};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
D():F(100);mxEvent.consume(W)}));mxEvent.addListener(this.chromelessToolbar,"mouseleave",mxUtils.bind(this,function(W){mxEvent.isTouchEvent(W)||F(30)}));var Y=a.getTolerance();a.addMouseListener({startX:0,startY:0,scrollLeft:0,scrollTop:0,mouseDown:function(W,J){this.startX=J.getGraphX();this.startY=J.getGraphY();this.scrollLeft=a.container.scrollLeft;this.scrollTop=a.container.scrollTop},mouseMove:function(W,J){},mouseUp:function(W,J){mxEvent.isTouchEvent(J.getEvent())&&Math.abs(this.scrollLeft-
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
return O};Editor.getDiagramNodeXml=function(g){var y=mxUtils.getTextContent(g),H=null;0<y.length?H=Graph.decompress(y):null!=g.firstChild&&(H=mxUtils.getXml(g.firstChild));return H};Editor.extractGraphModelFromPdf=function(g){g=g.substring(g.indexOf(",")+1);g=window.atob&&!mxClient.IS_SF?atob(g):Base64.decode(g,!0);if("%PDF-1.7"==g.substring(0,8)){var y=g.indexOf("EmbeddedFile");if(-1<y){var H=g.indexOf("stream",y)+9;if(0<g.substring(y,H).indexOf("application#2Fvnd.jgraph.mxfile"))return y=g.indexOf("endstream", H-1),pako.inflateRaw(Graph.stringToArrayBuffer(g.substring(H,y)),{to:"string"})}return null}H=null;y="";for(var O=0,P=0,V=[],R=null;P<g.length;){var W=g.charCodeAt(P);P+=1;10!=W&&(y+=String.fromCharCode(W));W=="/Subject (%3Cmxfile".charCodeAt(O)?O++:O=0;if(19==O){var X=g.indexOf("%3C%2Fmxfile%3E)",P)+15;P-=9;if(X>P){H=g.substring(P,X);break}}10==W&&("endobj"==y?R=null:"obj"==y.substring(y.length-3,y.length)||"xref"==y||"trailer"==y?(R=[],V[y.split(" ")[0]]=R):null!=R&&R.push(y),y="")}null==H&&(H= Editor.extractGraphModelFromXref(V));null!=H&&(H=decodeURIComponent(H.replace(/\\\(/g,"(").replace(/\\\)/g,")")));return H};Editor.extractGraphModelFromXref=function(g){var y=g.trailer,H=null;null!=y&&(y=/.* \/Info (\d+) (\d+) R/g.exec(y.join("\n")),null!=y&&0<y.length&&(y=g[y[1]],null!=y&&(y=/.* \/Subject (\d+) (\d+) R/g.exec(y.join("\n")),null!=y&&0<y.length&&(g=g[y[1]],null!=g&&(g=g.join("\n"),H=g.substring(1,g.length-1))))));return H};Editor.extractParserError=function(g,y){var H=null;g=null!=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
L=document.createElement("div");L.style.marginTop="6px";L.style.display="inline-block";L.style.width="140px";mxUtils.write(L,mxResources.get("siblingSpacing")+": ");Q.appendChild(L);var O=document.createElement("input");O.type="number";O.value=A;O.style.width="200px";O.style.boxSizing="border-box";Q.appendChild(O);mxEvent.addListener(O,"change",function(){A=O.value});L=mxUtils.button(mxResources.get("custom")+"...",function(){var P=[{layout:"mxOrgChartLayout",config:{branchOptimizer:parseInt(U.value), parentChildSpacing:parseInt(H.value),siblingSpacing:parseInt(O.value)}}];d.hideDialog();d.showCustomLayoutDialog(JSON.stringify(P,null,2))});L.className="geBtn";Q=new CustomDialog(d,Q,function(){null==z&&(z=2);d.loadOrgChartLayouts(N)},null,null,null,L);d.showDialog(Q.container,355,140,!0,!0)},n,null,v());l.addSeparator(n);l.addItem(mxResources.get("parallels"),null,mxUtils.bind(this,function(){d.tryAndHandle(mxUtils.bind(this,function(){var z=new mxParallelEdgeLayout(u);z.checkOverlap=!0;d.prompt(mxResources.get("spacing"), z.spacing,mxUtils.bind(this,function(E){d.tryAndHandle(mxUtils.bind(this,function(){z.spacing=E;d.executeLayout(function(){z.execute(u.getDefaultParent(),u.isSelectionEmpty()?null:u.getSelectionCells())},!1)}))}))}))}),n);l.addSeparator(n);d.menus.addMenuItem(l,"runLayout",n,null,null,mxResources.get("custom")+"...")};this.put("help",new Menu(mxUtils.bind(this,function(l,n){if(!mxClient.IS_CHROMEAPP&&d.isOffline())this.addMenuItems(l,["about"],n);else{var z=l.addItem("Search:",null,null,n,null,null,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
Fa.substring(Fa.indexOf(",")+1);Pa.style.cursor="pointer";Pa.style.width="100%";Pa.style.height="100%";ma.appendChild(Pa);ra=b.createMermaidXml("%% Input: "+Ma+"\n"+ra,EditorUi.defaultMermaidConfig,Fa,Ka,Xa);var Ra="<mxfile><diagram>"+Graph.compress(ra)+"</diagram></mxfile>";if(Ga||"undefined"===typeof mxMermaidToDrawio)ba=na=ra;ra=g.cloneNode(!0);ma.appendChild(ra);Fa=function(Oa){O=null!=b.sidebar.tooltip&&"none"!=b.sidebar.tooltip.style.display};Ka=function(Oa){O||x(Ra,mxEvent.getClientX(Oa),mxEvent.getClientY(Oa),
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
mxUtils.indexOf(this.hiddenTags,g[y]))return!1;return!0};Graph.prototype.getCellsForTags=function(g,y,H,O){var P=[];if(null!=g){y=null!=y?y:this.model.getDescendants(this.model.getRoot());for(var V=0,R={},W=0;W<g.length;W++)0<g[W].length&&(R[g[W]]=!0,V++);for(W=0;W<y.length;W++)if(H&&this.model.getParent(y[W])==this.model.root||this.model.isVertex(y[W])||this.model.isEdge(y[W])){var X=this.getTagsForCell(y[W]),Z=!1;if(0<X.length&&(X=X.split(" "),X.length>=g.length)){for(var Y=Z=0;Y<X.length&&Z<V;Y++)null!= R[X[Y]]&&Z++;Z=Z==V}Z&&(1!=O||this.isCellVisible(y[W]))&&P.push(y[W])}}return P};Graph.prototype.getAllTags=function(){return this.getTagsForCells(this.model.getDescendants(this.model.getRoot()))};Graph.prototype.getCommonTagsForCells=function(g){for(var y=null,H=[],O=0;O<g.length;O++){var P=this.getTagsForCell(g[O]);H=[];if(0<P.length){P=P.split(" ");for(var V={},R=0;R<P.length;R++)if(null==y||null!=y[P[R]])V[P[R]]=!0,H.push(P[R]);y=V}else return[]}return H};Graph.prototype.getTagsForCells=function(g){for(var y=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
var PopupDialog=function(b,f,m,d,u){u=null!=u?u:!0;var v=document.createElement("div");v.style.textAlign="left";v.style.height="100%";mxUtils.write(v,mxResources.get("fileOpenLocation"));mxUtils.br(v);mxUtils.br(v);var D=mxUtils.button(mxResources.get("openInThisWindow"),function(){u&&b.hideDialog();null!=d&&d()});D.className="geBtn";D.style.marginBottom="8px";D.style.width="280px";v.appendChild(D);mxUtils.br(v);var F=mxUtils.button(mxResources.get("openInNewWindow"),function(){u&&b.hideDialog(); null!=m&&m();b.openLink(f,null,!0)});F.className="geBtn gePrimaryBtn";F.style.width=D.style.width;v.appendChild(F);mxUtils.br(v);mxUtils.br(v);mxUtils.write(v,mxResources.get("allowPopups"));this.container=v},ImageDialog=function(b,f,m,d,u,v,D,F){function K(){0<S.value.length?t.removeAttribute("disabled"):t.setAttribute("disabled","disabled")}v=null!=v?v:!0;var M=b.editor.graph,G=document.createElement("div");mxUtils.write(G,f);f=document.createElement("div");f.className="geTitle";f.style.backgroundColor=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
ha[la]=ma),ma.push(oa))}ia=ia.nextSibling}l(Ea,Ta,Ha)}})}function z(ia){D&&(Ba.scrollTop=0,da.innerText="",Qa.spin(da),g=!1,U=!0,za.innerText=mxResources.get("recentDiag"),Y=null,D(Va,function(){k(mxResources.get("cannotLoad"));Va([])},ia?null:v))}function E(ia){if(""==ia)null!=H&&(H.click(),H=null);else{if(null==TemplatesDialog.tagsList[d]){var aa={};for(La in Ea)for(var la=Ea[La],ma=0;ma<la.length;ma++){var oa=la[ma];if(null!=oa.tags)for(var ha=oa.tags.toLowerCase().split(";"),ja=0;ja<ha.length;ja++)null==
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
1024*t,C=Math.min(x+1024,k),I=Array(C-x),B=0;x<C;++B,++x)I[B]=c[x].charCodeAt(0);p[t]=new Uint8Array(I)}return new Blob(p,{type:e})};EditorUi.prototype.saveLocalFile=function(c,e,k,q,p,t,x,C){t=null!=t?t:!1;x=null!=x?x:"vsdx"!=p&&(!mxClient.IS_IOS||!navigator.standalone);p=this.getServiceCount(t);isLocalStorage&&p++;var I=4>=p?2:6<p?4:3;e=new CreateDialog(this,e,mxUtils.bind(this,function(B,T){try{if("_blank"==T)if(null!=k&&"image/"==k.substring(0,6))this.openInNewWindow(c,k,q);else if(null!=k&&"text/html"== k.substring(0,9)){var l=new EmbedDialog(this,c);this.showDialog(l.container,450,240,!0,!0);l.init()}else{var n=window.open("about:blank");null==n?mxUtils.popup(c,!0):(n.document.write("<pre>"+mxUtils.htmlEntities(c,!1)+"</pre>"),n.document.close())}else T==App.MODE_DEVICE||"download"==T?this.doSaveLocalFile(c,B,k,q,null,C):null!=B&&0<B.length&&this.pickFolder(T,mxUtils.bind(this,function(z){try{this.exportFile(c,B,k,q,T,z)}catch(E){this.handleError(E)}}))}catch(z){this.handleError(z)}}),mxUtils.bind(this, function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,t,x,null,1<p,I,c,k,q);t=this.isServices(p)?p>I?390:280:160;this.showDialog(e.container,420,t,!0,!0);e.init()};EditorUi.prototype.openInNewWindow=function(c,e,k){var q=window.open("about:blank");null==q||null==q.document?mxUtils.popup(c,!0):("image/svg+xml"!=e||mxClient.IS_SVG?"image/svg+xml"!=e||k?(c=k?c:btoa(unescape(encodeURIComponent(c))),q.document.write('<html><img style="max-width:100%;" src="data:'+e+";base64,"+
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
null,x,mxResources.get("cancel"),mxResources.get("discardChanges")):x()})));else throw Error(mxResources.get("notADiagramFile"));};EditorUi.prototype.getBasenames=function(){var c={};if(null!=this.pages)for(var e=0;e<this.pages.length;e++)this.updatePageRoot(this.pages[e]),this.addBasenamesForCell(this.pages[e].root,c);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),c);e=[];for(var k in c)e.push(k);return e};EditorUi.prototype.addBasenamesForCell=function(c,e){function k(x){if(null!= x){var C=x.lastIndexOf(".");0<C&&(x=x.substring(C+1,x.length));null==e[x]&&(e[x]=!0)}}var q=this.editor.graph,p=q.getCellStyle(c);k(mxStencilRegistry.getBasenameForStencil(p[mxConstants.STYLE_SHAPE]));q.model.isEdge(c)&&(k(mxMarker.getPackageForType(p[mxConstants.STYLE_STARTARROW])),k(mxMarker.getPackageForType(p[mxConstants.STYLE_ENDARROW])));p=q.model.getChildCount(c);for(var t=0;t<p;t++)this.addBasenamesForCell(q.model.getChildAt(c,t),e)};EditorUi.prototype.setGraphEnabled=function(c){this.diagramContainer.style.visibility=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
B&&"function"===typeof B.substring&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(B,"")?this.isOffline()?this.showError(mxResources.get("error"),mxResources.get("notInOffline")):this.parseFileData(B,mxUtils.bind(this,function(ba){4==ba.readyState&&(200<=ba.status&&299>=ba.status&&"<mxGraphModel"==ba.responseText.substring(0,13)?Ba(ba.responseText,I):this.handleError({message:413==ba.status?mxResources.get("diagramTooLarge"):mxResources.get("unknownError")}))}),""):null!=B&&"function"===typeof B.substring&& this.isLucidChartData(B)?this.convertLucidChart(B,mxUtils.bind(this,function(ba){Ba(ba)}),mxUtils.bind(this,function(ba){this.handleError(ba)})):null==B||"object"!==typeof B||null==B.format||null==B.data&&null==B.url?(B=l(B),Ba(B,I)):this.loadDescriptor(B,mxUtils.bind(this,function(ba){Ba(Ca(),I)}),mxUtils.bind(this,function(ba){this.handleError(ba,mxResources.get("errorLoadingFile"))}))}}));var x=window.opener||window.parent;t="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
p+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.getHtml2=function(c,e,k,q,p){e=window.DRAWIO_VIEWER_URL||EditorUi.drawHost+"/js/viewer-static.min.js";null!=p&&(p=p.replace(/&/g,"&amp;"));c={highlight:"#0000ff",nav:this.editor.graph.foldingEnabled,resize:!0,xml:Graph.zapGremlins(c),toolbar:"pages zoom layers lightbox"};null!=this.pages&&null!=this.currentPage&&(c.page=mxUtils.indexOf(this.pages,this.currentPage)); return(null==p?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+"<!DOCTYPE html>\n<html"+(null!=p?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+(null==p?null!=k?"<title>"+mxUtils.htmlEntities(k)+"</title>\n":"":"<title>diagrams.net</title>\n")+(null!=p?'<meta http-equiv="refresh" content="0;URL=\''+p+"'\"/>\n":"")+'<meta charset="utf-8"/>\n</head>\n<body>\n<div class="mxgraph" style="max-width:100%;border:1px solid transparent;" data-mxgraph="'+ mxUtils.htmlEntities(JSON.stringify(c))+'"></div>\n'+(null==p?'<script type="text/javascript" src="'+e+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+p+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.setFileData=function(c){c=this.validateFileData(c);this.pages=this.fileNode=this.currentPage=null;var e=null!=c&&0<c.length?mxUtils.parseXml(c).documentElement:
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
N?(N=e.getOutgoingTreeEdges(A),null!=N&&0<N.length&&e.setSelectionCell(e.model.getTerminal(N[0],!1))):(Q=e.getIncomingTreeEdges(A),null!=Q&&0<Q.length&&(L=S(e.model.getTerminal(Q[0],!0),L,A),A=e.view.getState(A),null!=A&&(A=mxUtils.indexOf(L,A),0<=A&&(A+=N==mxConstants.DIRECTION_NORTH||N==mxConstants.DIRECTION_WEST?-1:1,0<=A&&A<=L.length-1&&e.setSelectionCell(L[A].cell)))))}var c=this,e=c.editor.graph,k=e.getModel(),q=c.menus.createPopupMenu;c.menus.createPopupMenu=function(A,N,Q){q.apply(this,arguments); if(1==e.getSelectionCount()){N=e.getSelectionCell();var L=e.getOutgoingTreeEdges(N);A.addSeparator();0<L.length&&(d(e.getSelectionCell())&&this.addMenuItems(A,["selectChildren"],null,Q),this.addMenuItems(A,["selectDescendants"],null,Q));d(e.getSelectionCell())?(A.addSeparator(),0<e.getIncomingTreeEdges(N).length&&this.addMenuItems(A,["selectSiblings","selectParent"],null,Q)):0<e.model.getEdgeCount(N)&&this.addMenuItems(A,["selectConnections"],null,Q)}};c.actions.addAction("selectChildren",function(A){if(e.isEnabled()&&
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
null!=b.currentPage&&null!=b.pages&&(K=mxUtils.indexOf(b.pages,b.currentPage));for(J=f.length-1;0<=J;J--){var R=function(W){var X=new Date(W.modifiedDate),Z=null;if(0<=X.getTime()){var Y=function(fa){c.stop();D.innerText="";var na=mxUtils.parseXml(fa),da=b.editor.extractGraphModel(na.documentElement,!0);if(null!=da){var za=function(Ba){null!=Ba&&(Ba=Ca(Editor.parseDiagramNode(Ba)));return Ba},Ca=function(Ba){var ba=Ba.getAttribute("background");if(null==ba||""==ba||ba==mxConstants.NONE)ba=F.defaultPageBackgroundColor; v.style.backgroundColor=ba;(new mxCodec(Ba.ownerDocument)).decode(Ba,F.getModel());F.maxFitScale=1;F.fit(8);F.center();return Ba};L.style.display="none";L.innerText="";x=na;C=fa;M=parseSelectFunction=null;G=0;if("mxfile"==da.nodeName){na=da.getElementsByTagName("diagram");M=[];for(fa=0;fa<na.length;fa++)M.push(na[fa]);G=Math.min(K,M.length-1);0<M.length&&za(M[G]);if(1<M.length)for(L.removeAttribute("disabled"),L.style.display="",fa=0;fa<M.length;fa++)na=document.createElement("option"),da=M[fa].getAttribute("name")||
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
return Editor.updateCRC(c,e,k,q)};EditorUi.prototype.crc32=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: crc32");return Editor.crc32(c)};EditorUi.prototype.writeGraphModelToPng=function(c,e,k,q,p){EditorUi.logEvent("SHOULD NOT BE CALLED: writeGraphModelToPng");return Editor.writeGraphModelToPng(c,e,k,q,p)};EditorUi.prototype.getLocalStorageFileNames=function(){if("1"==localStorage.getItem(".localStorageMigrated")&&"1"!=urlParams.forceMigration)return null;for(var c=[],e=0;e<localStorage.length;e++){var k=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
R[X[Y]]&&Z++;Z=Z==V}Z&&(1!=O||this.isCellVisible(y[W]))&&P.push(y[W])}}return P};Graph.prototype.getAllTags=function(){return this.getTagsForCells(this.model.getDescendants(this.model.getRoot()))};Graph.prototype.getCommonTagsForCells=function(g){for(var y=null,H=[],O=0;O<g.length;O++){var P=this.getTagsForCell(g[O]);H=[];if(0<P.length){P=P.split(" ");for(var V={},R=0;R<P.length;R++)if(null==y||null!=y[P[R]])V[P[R]]=!0,H.push(P[R]);y=V}else return[]}return H};Graph.prototype.getTagsForCells=function(g){for(var y= [],H={},O=0;O<g.length;O++){var P=this.getTagsForCell(g[O]);if(0<P.length){P=P.split(" ");for(var V=0;V<P.length;V++)null==H[P[V]]&&(H[P[V]]=!0,y.push(P[V]))}}return y};Graph.prototype.getTagsForCell=function(g){return this.getAttributeForCell(g,"tags","")};Graph.prototype.addTagsForCells=function(g,y){if(0<g.length&&0<y.length){this.model.beginUpdate();try{for(var H=0;H<g.length;H++){for(var O=this.getTagsForCell(g[H]),P=O.split(" "),V=!1,R=0;R<y.length;R++){var W=mxUtils.trim(y[R]);""!=W&&0>mxUtils.indexOf(P,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
c&&"sketch"!=c);"simple"==c||"sketch"==c?(Editor.fitWindowBorders=new mxRectangle(60,30,30,30),e.defaultEdgeLength=120,null==urlParams.grid&&(e.defaultGridEnabled=!1),null==urlParams.pv&&(e.defaultPageVisible=!1)):Editor.fitWindowBorders=null};EditorUi.prototype.switchCssForTheme=function(c){"simple"==c||"sketch"==c?null==this.sketchStyleElt&&(this.sketchStyleElt=document.createElement("style"),this.sketchStyleElt.setAttribute("type","text/css"),this.sketchStyleElt.innerHTML=Editor.createMinimalCss(), document.getElementsByTagName("head")[0].appendChild(this.sketchStyleElt)):null!=this.sketchStyleElt&&(this.sketchStyleElt.parentNode.removeChild(this.sketchStyleElt),this.sketchStyleElt=null)};EditorUi.prototype.createWrapperForTheme=function(c){"simple"==c||"sketch"==c?(null==this.sketchWrapperElt&&(this.sketchWrapperElt=document.createElement("div"),this.sketchWrapperElt.style.cssText="position:absolute;top:0px;left:0px;right:0px;bottom:0px;overflow:hidden;"),"sketch"==c&&(this.sketchWrapperElt.className=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
c=this;mxWindow.prototype.fit=function(){if(Editor.inlineFullscreen||null==c.embedViewport)mxUtils.fit(this.div);else{var L=parseInt(this.div.offsetLeft),U=parseInt(this.div.offsetWidth),g=c.embedViewport.x+c.embedViewport.width,y=parseInt(this.div.offsetTop),H=parseInt(this.div.offsetHeight),O=c.embedViewport.y+c.embedViewport.height;this.div.style.left=Math.max(c.embedViewport.x,Math.min(L,g-U))+"px";this.div.style.top=Math.max(c.embedViewport.y,Math.min(y,O-H))+"px";this.div.style.height=Math.min(c.embedViewport.height, parseInt(this.div.style.height))+"px";this.div.style.width=Math.min(c.embedViewport.width,parseInt(this.div.style.width))+"px"}};if(!this.editor.chromeless||this.editor.editable)if("simple"==Editor.currentTheme||"sketch"==Editor.currentTheme)A=Editor.currentTheme,Editor.currentTheme="",this.doSetCurrentTheme(A,0,mxUtils.bind(this,function(){"1"==urlParams.embedInline?this.initializeInlineEmbedMode():(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)<Editor.smallScreenWidth&&
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
App.prototype.pickFolder=function(b,f,m,d,u){m=null!=m?m:!0;var v=this.spinner.pause();m&&b==App.MODE_GOOGLE&&null!=this.drive?this.drive.pickFolder(mxUtils.bind(this,function(D){v();if(D.action==google.picker.Action.PICKED){var F=null;null!=D.docs&&0<D.docs.length&&"folder"==D.docs[0].type&&(F=D.docs[0].id);f(F)}}),u):m&&b==App.MODE_ONEDRIVE&&null!=this.oneDrive?this.oneDrive.pickFolder(mxUtils.bind(this,function(D){v();null!=D&&null!=D.value&&0<D.value.length&&(D=OneDriveFile.prototype.getIdOf(D.value[0]), f(D))}),d):m&&b==App.MODE_GITHUB&&null!=this.gitHub?this.gitHub.pickFolder(mxUtils.bind(this,function(D){v();f(D)})):m&&b==App.MODE_GITLAB&&null!=this.gitLab?this.gitLab.pickFolder(mxUtils.bind(this,function(D){v();f(D)})):m&&b==App.MODE_TRELLO&&null!=this.trello?this.trello.pickFolder(mxUtils.bind(this,function(D){v();f(D)})):EditorUi.prototype.pickFolder.apply(this,arguments)};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"data:"+c+";base64,"+I);u.style.position="absolute";u.style.top="70px";u.style.right="100px";u.style.maxWidth="120px";u.style.maxHeight="80px";mxUtils.setPrefixedStyle(u.style,"transform","translate(50%,-50%)");v.appendChild(u);mxClient.IS_FF||"image/png"!=c||null==navigator.clipboard||"function"!==typeof window.ClipboardItem||(k=mxUtils.button(mxResources.get("copy"),function(n){n=b.base64ToBlob(I,"image/png");n=new ClipboardItem({"image/png":n,"text/html":new Blob(['<img src="data:'+c+";base64,"+ I+'">'],{type:"text/html"})});navigator.clipboard.write([n]).then(mxUtils.bind(this,function(){b.alert(mxResources.get("copiedToClipboard"))}))["catch"](mxUtils.bind(this,function(z){b.handleError(z)}))}),k.style.marginTop="6px",k.className="geBtn");K&&Editor.popupsAllowed&&(u.style.cursor="pointer",mxEvent.addGestureListeners(u,null,null,function(n){mxEvent.isPopupTrigger(n)||t("_blank")}))}mxUtils.br(v);var B=document.createElement("div");B.style.textAlign="center";var T=0;B.style.marginTop="6px";
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
(C=new mxCodec(mxUtils.createXmlDocument()),C=C.encode(new mxGraphModel(t.root)),this.editor.graph.saveViewState(t.viewState,C,null,q),x=x.cloneNode(!1),mxUtils.setTextContent(x,Graph.compressNode(C))));c(x)}return p};EditorUi.prototype.anonymizeString=function(c,e){for(var k=[],q=0;q<c.length;q++){var p=c.charAt(q);0<=EditorUi.ignoredAnonymizedChars.indexOf(p)?k.push(p):isNaN(parseInt(p))?p.toLowerCase()!=p?k.push(String.fromCharCode(65+Math.round(25*Math.random()))):p.toUpperCase()!=p?k.push(String.fromCharCode(97+ Math.round(25*Math.random()))):/\s/.test(p)?k.push(" "):k.push("?"):k.push(e?"0":Math.round(9*Math.random()))}return k.join("")};EditorUi.prototype.anonymizePatch=function(c){if(null!=c[EditorUi.DIFF_INSERT])for(var e=0;e<c[EditorUi.DIFF_INSERT].length;e++)try{var k=mxUtils.parseXml(c[EditorUi.DIFF_INSERT][e].data).documentElement.cloneNode(!1);null!=k.getAttribute("name")&&k.setAttribute("name",this.anonymizeString(k.getAttribute("name")));c[EditorUi.DIFF_INSERT][e].data=mxUtils.getXml(k)}catch(t){c[EditorUi.DIFF_INSERT][e].data=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
q,k);null!=e&&(q.style.backgroundImage="url("+e+")",q.style.backgroundPosition="center center",q.style.backgroundRepeat="no-repeat",q.style.backgroundSize="100% 100%",q.style.width="24px",q.innerText="");return q};EditorUi.prototype.createToolbarButton=function(c,e,k,q){q=null!=q?q:24;var p=document.createElement("a");p.className="geToolbarButton geAdaptiveAsset";p.setAttribute("title",e);p.style.backgroundImage="url("+c+")";p.style.backgroundPosition="center center";p.style.backgroundRepeat="no-repeat"; p.style.backgroundSize="100% 100%";p.style.display="inline-block";p.style.cursor="pointer";p.style.marginLeft="6px";p.style.width=q+"px";p.style.height=q+"px";null!=k&&(mxEvent.addListener(p,mxClient.IS_POINTER?"pointerdown":"mousedown",mxUtils.bind(this,function(t){t.preventDefault()})),mxEvent.addListener(p,"click",function(t){"disabled"!=p.getAttribute("disabled")&&k(t);mxEvent.consume(t)}));return p};EditorUi.prototype.createMenuItem=function(c,e,k){var q=this.actions.get(c),p=null!=q?q.funct:
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
this.editor.chromeless&&!this.editor.editable||!(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))||(this.toggleScratchpad(),mxSettings.save())));this.addListener("formatWidthChanged",function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})}};EditorUi.prototype.copyImage=function(c,e,k){try{null!=navigator.clipboard&&"function"===typeof window.ClipboardItem&&this.spinner.spin(document.body,mxResources.get("exporting"))&&this.editor.exportToCanvas(mxUtils.bind(this, function(q,p){try{this.spinner.stop();var t=this.createImageDataUri(q,e,"png"),x=parseInt(p.getAttribute("width")),C=parseInt(p.getAttribute("height"));this.writeImageToClipboard(t,x,C,mxUtils.bind(this,function(I){this.handleError(I)}))}catch(I){this.handleError(I)}}),null,null,null,mxUtils.bind(this,function(q){this.spinner.stop();this.handleError(q)}),null,null,null!=k?k:4,null==this.editor.graph.background||this.editor.graph.background==mxConstants.NONE,null,null,null,10,null,null,!1,null,0<c.length? c:null)}catch(q){this.handleError(q)}};EditorUi.prototype.writeImageToClipboard=function(c,e,k,q){var p=this.base64ToBlob(c.substring(c.indexOf(",")+1),"image/png");c=new ClipboardItem({"image/png":p,"text/html":new Blob(['<img src="'+c+'" width="'+e+'" height="'+k+'">'],{type:"text/html"})});navigator.clipboard.write([c])["catch"](q)};EditorUi.prototype.copyCells=function(c,e){var k=this.editor.graph;if(k.isSelectionEmpty())c.innerText="";else{var q=mxUtils.sortCells(k.model.getTopmostCells(k.getSelectionCells())),
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
t=[];p.onsuccess=function(x){null==x.target.result?c(t):(t.push(x.target.result.value),x.target.result.continue())};p.onerror=e}catch(x){null!=e&&e(x)}}),e)};EditorUi.prototype.getDatabaseItemKeys=function(c,e,k){this.openDatabase(mxUtils.bind(this,function(q){try{k=k||"objects";var p=q.transaction([k],"readonly").objectStore(k).getAllKeys();p.onsuccess=function(){c(p.result)};p.onerror=e}catch(t){null!=e&&e(t)}}),e)};EditorUi.prototype.commentsSupported=function(){var c=this.getCurrentFile();return null!=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(z){G=z};this.setAutoScroll=function(z){S=z};this.setOpenFill=function(z){J=z};this.setStopClickEnabled=function(z){k=z};this.setSelectInserted=function(z){q=z};this.setSmoothing=function(z){m=z};this.setPerfectFreehandMode=function(z){t=z};this.isPerfectFreehandMode=function(){return t};this.setBrushSize=function(z){p.size=z};this.getBrushSize=function(){return p.size};var x=function(z){e=z;b.getRubberband().setEnabled(!z);b.graphHandler.setSelectEnabled(!z);b.graphHandler.setMoveEnabled(!z); b.container.style.cursor=z?"crosshair":"";b.fireEvent(new mxEventObject("freehandStateChanged"))};this.startDrawing=function(){x(!0)};this.isDrawing=function(){return e};var C=mxUtils.bind(this,function(z){if(d){var E=F.length,A=k&&0<D.length&&null!=F&&2>F.length;A||D.push.apply(D,F);F=[];D.push(null);u.push(d);d=null;(A||G)&&this.stopDrawing();G&&(!A||2<=E)&&this.startDrawing();mxEvent.consume(z)}}),I=new mxCell;I.edge=!0;var B=function(){var z=b.getCurrentCellStyle(I);z=mxUtils.getValue(b.currentVertexStyle,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
EditorUi.lightboxHost+"/?client=1"+(null!=e?"&page="+e:"")+(p?"&edit=_blank":"")+(t?"&layers=1":"")+"');}}})(this);"),n+="cursor:pointer;"),c&&(c=parseInt(C.getAttribute("width")),p=parseInt(C.getAttribute("height")),C.setAttribute("viewBox","-0.5 -0.5 "+c+" "+p),n+="max-width:100%;max-height:"+p+"px;",C.removeAttribute("height")),""!=n&&C.setAttribute("style",n),this.editor.addFontCss(C),this.editor.graph.mathEnabled&&this.editor.addMathCss(C),x(mxUtils.getXml(C))};EditorUi.prototype.timeSince=function(c){c= Math.floor((new Date-c)/1E3);var e=Math.floor(c/31536E3);if(1<e)return e+" "+mxResources.get("years");e=Math.floor(c/2592E3);if(1<e)return e+" "+mxResources.get("months");e=Math.floor(c/86400);if(1<e)return e+" "+mxResources.get("days");e=Math.floor(c/3600);if(1<e)return e+" "+mxResources.get("hours");e=Math.floor(c/60);return 1<e?e+" "+mxResources.get("minutes"):1==e?e+" "+mxResources.get("minute"):null};EditorUi.prototype.decodeNodeIntoGraph=function(c,e){if(null!=c){var k=null;if("diagram"==c.nodeName)k=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
Editor.isSettingsEnabled=function(){return"undefined"!==typeof window.mxSettings&&(isLocalStorage||mxClient.IS_CHROMEAPP)};Editor.configureFontCss=function(g){if(null!=g){Editor.prototype.fontCss=g;var y=document.getElementsByTagName("script")[0];if(null!=y&&null!=y.parentNode){var H=document.createElement("style");H.setAttribute("type","text/css");H.appendChild(document.createTextNode(g));y.parentNode.insertBefore(H,y);g=g.split("url(");for(H=1;H<g.length;H++){var O=g[H].indexOf(")");O=Editor.trimCssUrl(g[H].substring(0,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
J.vertex=!0;S.addCell(J);S.dblClick=function(E,A){if(null!=A&&A!=J)S.setSelectionCell(A);else{A=mxUtils.convertPoint(S.container,mxEvent.getClientX(E),mxEvent.getClientY(E));mxEvent.consume(E);E=S.view.scale;var N=S.view.translate;S.setSelectionCell(v((A.x-3*E)/E-N.x,(A.y-3*E)/E-N.y))}};u=new mxKeyHandler(S);u.bindKey(46,D);u.bindKey(8,D);S.getRubberband().isForceRubberbandEvent=function(E){return 0==E.evt.button&&(null==E.getCell()||E.getCell()==J)};S.panningHandler.isForcePanningEvent=function(E){return 2==
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
t=[];p.onsuccess=function(x){null==x.target.result?c(t):(t.push(x.target.result.value),x.target.result.continue())};p.onerror=e}catch(x){null!=e&&e(x)}}),e)};EditorUi.prototype.getDatabaseItemKeys=function(c,e,k){this.openDatabase(mxUtils.bind(this,function(q){try{k=k||"objects";var p=q.transaction([k],"readonly").objectStore(k).getAllKeys();p.onsuccess=function(){c(p.result)};p.onerror=e}catch(t){null!=e&&e(t)}}),e)};EditorUi.prototype.commentsSupported=function(){var c=this.getCurrentFile();return null!=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"keys",Da,"values",Ta,"cells",ea.getSelectionCells()))}finally{ea.getModel().endUpdate()}}function P(pa,ua,va){var Ea=mxUtils.getOffset(g,!0),Da=mxUtils.getOffset(pa,!0);ua.style.position="absolute";ua.style.left=Da.x-Ea.x+"px";ua.style.top=Da.y-Ea.y+"px";ua.style.width=pa.offsetWidth+"px";ua.style.height=pa.offsetHeight-(va?4:0)+"px";ua.style.zIndex=5}function V(pa,ua,va){var Ea=document.createElement("div");Ea.style.width="32px";Ea.style.height="4px";Ea.style.margin="2px";Ea.style.border="1px solid black";
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
0==H%2,da.flipBkg),y.parentNode.insertBefore(qa,y.nextSibling),y=qa;g.appendChild(na);Ba();return g};StyleFormatPanel.prototype.addStyles=function(g){if(null!=this.defaultColorSchemes){var y=function(da){mxEvent.addListener(da,"mouseenter",function(){da.style.opacity="1"});mxEvent.addListener(da,"mouseleave",function(){da.style.opacity="0.5"})},H=this.editorUi,O=H.editor.graph,P=document.createElement("div");P.style.whiteSpace="nowrap";P.style.paddingLeft="24px";P.style.paddingRight="20px";g.style.paddingLeft=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
StorageFile.listFiles=function(b,f,m,d){b.getDatabaseItems(function(u){var v=[];if(null!=u)for(var D=0;D<u.length;D++)"."==u[D].title.charAt(0)||null!=f&&u[D].type!=f||v.push(u[D]);m(v)},function(){null==b.database?m(StorageFile.listLocalStorageFiles(f)):null!=d&&d()},"filesInfo")};StorageFile.deleteFile=function(b,f,m,d){b.removeDatabaseItem([f,f],m,function(){null==b.database?(localStorage.removeItem(f),m()):null!=d&&d()},["files","filesInfo"])};StorageLibrary=function(b,f,m){StorageFile.call(this,b,f,m)};mxUtils.extend(StorageLibrary,StorageFile);StorageLibrary.prototype.type="L";StorageLibrary.prototype.isAutosave=function(){return!0};StorageLibrary.prototype.saveAs=function(b,f,m){this.saveFile(b,!1,f,m)};StorageLibrary.prototype.getHash=function(){return"L"+encodeURIComponent(this.title)};StorageLibrary.prototype.getTitle=function(){return".scratchpad"==this.title?mxResources.get("scratchpad"):this.title};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(c,e,k,q,p){this.openDatabase(mxUtils.bind(this,function(t){try{p=p||"objects";Array.isArray(p)||(p=[p],c=[c],e=[e]);var x=t.transaction(p,"readwrite");x.oncomplete=k;x.onerror=q;for(t=0;t<p.length;t++)x.objectStore(p[t]).put(null!=c&&null!=c[t]?{key:c[t],data:e[t]}:e[t])}catch(C){null!=q&&q(C)}}),q)};EditorUi.prototype.removeDatabaseItem=function(c,e,k,q){this.openDatabase(mxUtils.bind(this,function(p){q=q||"objects";Array.isArray(q)||(q=[q],c=[c]);p=p.transaction(q,"readwrite");p.oncomplete=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
document.createElement("canvas");E.width=T;E.height=l;var A=E.toDataURL();z!==A&&(e=z,C=T,I=l)}}}catch(N){}k(e,C,I)};EditorUi.prototype.extractGraphModelFromPng=function(c){return Editor.extractGraphModelFromPng(c)};EditorUi.prototype.loadImage=function(c,e,k){try{var q=new Image;q.onload=function(){q.width=0<q.width?q.width:120;q.height=0<q.height?q.height:120;e(q)};null!=k&&(q.onerror=k);q.src=c}catch(p){if(null!=k)k(p);else throw p;}};EditorUi.prototype.getDefaultSketchMode=function(){var c="1"== urlParams.sketch;return"0"!=(null!=urlParams.rough?urlParams.rough:c)};var u=EditorUi.prototype.createUi;EditorUi.prototype.createUi=function(){Editor.isSettingsEnabled()&&(this.doSetSketchMode(null!=mxSettings.settings.sketchMode&&null==urlParams.rough&&null==urlParams.sketch?mxSettings.settings.sketchMode:this.getDefaultSketchMode()),null!=mxSettings.settings.sidebarTitles&&(Sidebar.prototype.sidebarTitles=mxSettings.settings.sidebarTitles),this.formatWidth=mxSettings.getFormatWidth());u.apply(this,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(){b.spinner.stop();if(null==b.linkPicker){var x=b.drive.createLinkPicker();b.linkPicker=x.setCallback(function(C){LinkDialog.filePicked(C)}).build()}b.linkPicker.setVisible(!0)}))});"undefined"!=typeof Dropbox&&"undefined"!=typeof Dropbox.choose&&F(IMAGE_PATH+"/dropbox-logo.svg",mxResources.get("dropbox"),function(){Dropbox.choose({linkType:"direct",cancel:function(){},success:function(x){G.value=x[0].link;G.focus()}})});null!=b.oneDrive&&F(IMAGE_PATH+"/onedrive-logo.svg",mxResources.get("oneDrive"),
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
g?g.getElementsByTagName("parsererror"):null;null!=g&&0<g.length&&(H=y||mxResources.get("invalidChars"),y=g[0].getElementsByTagName("div"),0<y.length&&(H=mxUtils.getTextContent(y[0])));return null!=H?mxUtils.trim(H):H};Editor.addRetryToError=function(g,y){null!=g&&(g=null!=g.error?g.error:g,null==g.retry&&(g.retry=y))};Editor.mermaidToDrawio=function(g,y,H){if("function"===typeof mxMermaidToDrawio)return mxMermaidToDrawio(g,y,H)};Editor.configure=function(g){if(null!=g){Editor.config=g;Editor.configVersion=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
R[X[Y]]&&Z++;Z=Z==V}Z&&(1!=O||this.isCellVisible(y[W]))&&P.push(y[W])}}return P};Graph.prototype.getAllTags=function(){return this.getTagsForCells(this.model.getDescendants(this.model.getRoot()))};Graph.prototype.getCommonTagsForCells=function(g){for(var y=null,H=[],O=0;O<g.length;O++){var P=this.getTagsForCell(g[O]);H=[];if(0<P.length){P=P.split(" ");for(var V={},R=0;R<P.length;R++)if(null==y||null!=y[P[R]])V[P[R]]=!0,H.push(P[R]);y=V}else return[]}return H};Graph.prototype.getTagsForCells=function(g){for(var y=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
m.viewState.scale=1;delete m.viewState.scrollLeft;delete m.viewState.scrollTop;delete m.viewState.currentRoot;delete m.viewState.defaultParent;m.setName(f);m=this.insertPage(m,mxUtils.indexOf(this.pages,b)+1)}}catch(K){this.handleError(K)}return m};EditorUi.prototype.initDiagramNode=function(b){var f=(new mxCodec(mxUtils.createXmlDocument())).encode(new mxGraphModel(b.root));this.editor.graph.saveViewState(b.viewState,f);mxUtils.setTextContent(b.node,Graph.compressNode(f))};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(c,e,k,q,p,t,x,C){EditorUi.logEvent("SHOULD NOT BE CALLED: loadUrl");return this.editor.loadUrl(c,e,k,q,p,t,x,C)};EditorUi.prototype.loadFonts=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: loadFonts");return this.editor.loadFonts(c)};EditorUi.prototype.createSvgDataUri=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: createSvgDataUri");return Editor.createSvgDataUri(c)};EditorUi.prototype.embedCssFonts=function(c,e){EditorUi.logEvent("SHOULD NOT BE CALLED: embedCssFonts");return this.editor.embedCssFonts(c,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
v)for(D=0;D<v.length;D++)v[D].node.style.visibility=d?"visible":"hidden"};var m=mxGuide.prototype.destroy;mxGuide.prototype.destroy=function(){m.call(this);var d=this.guidesArrVer,u=this.guidesArrHor;if(null!=d){for(var v=0;v<d.length;v++)d[v].destroy();this.guidesArrVer=null}if(null!=u){for(v=0;v<u.length;v++)u[v].destroy();this.guidesArrHor=null}}})();function mxRuler(b,f,m,d){function u(){var x=b.diagramContainer;S.style.top=x.offsetTop-K+"px";S.style.left=x.offsetLeft-K+"px";S.style.width=(m?0:x.offsetWidth)+K+"px";S.style.height=(m?x.offsetHeight:0)+K+"px"}function v(x,C,I){if(null!=D)return x;var B;return function(){var T=this,l=arguments,n=I&&!B;clearTimeout(B);B=setTimeout(function(){B=null;I||x.apply(T,l)},C);n&&x.apply(T,l)}}var D=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
var da=this.graphHandler.shouldRemoveCellsFromParent;this.graphHandler.shouldRemoveCellsFromParent=function(K,U,L){return this.graph.isCellSelected(K)?!1:da.apply(this,arguments)};var ja=this.updateMouseEvent;this.updateMouseEvent=function(K){K=ja.apply(this,arguments);null!=K.state&&this.isCellLocked(this.getLayerForCell(K.getCell()))&&(K.state=null);return K};var ia=this.isCellSelectable;this.isCellSelectable=function(K){return ia.apply(this,arguments)&&!this.isCellLocked(this.getLayerForCell(K))};
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
function(){var c=document.createElement("div");c.className="geButtonContainer";c.style.overflow="1"==urlParams.embed?"hidden":"";return c};EditorUi.prototype.openLink=function(c,e,k){return this.editor.graph.openLink(c,e,k)};EditorUi.prototype.showSplash=function(c){};EditorUi.prototype.getLocalData=function(c,e){e(localStorage.getItem(c))};EditorUi.prototype.setLocalData=function(c,e,k){localStorage.setItem(c,e);null!=k&&k()};EditorUi.prototype.removeLocalData=function(c,e){localStorage.removeItem(c); e()};EditorUi.prototype.setShareCursorPosition=function(c){this.shareCursorPosition=c;this.fireEvent(new mxEventObject("shareCursorPositionChanged"))};EditorUi.prototype.isShareCursorPosition=function(){return this.shareCursorPosition};EditorUi.prototype.setShowRemoteCursors=function(c){this.showRemoteCursors=c;this.fireEvent(new mxEventObject("showRemoteCursorsChanged"))};EditorUi.prototype.isShowRemoteCursors=function(){return this.showRemoteCursors};EditorUi.prototype.setMathEnabled=function(c){this.editor.graph.mathEnabled=
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
E.evt.button};var c=S.isCellSelectable;S.isCellSelectable=function(E){return E==J?!1:c.apply(this,arguments)};S.getLinkForCell=function(){return null};var e=S.view.getState(J);G=S.getAllConnectionConstraints(e);for(var k=0;null!=G&&k<G.length;k++){var q=S.getConnectionPoint(e,G[k]);v(q.x-3,q.y-3,G[k])}S.fit(8);S.center();k=b.createToolbarButton(Editor.zoomInImage,mxResources.get("zoomIn"),function(){S.zoomIn()},20);k.setAttribute("disabled","disabled");q=b.createToolbarButton(Editor.zoomOutImage,
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
Fa.substring(Fa.indexOf(",")+1);Pa.style.cursor="pointer";Pa.style.width="100%";Pa.style.height="100%";ma.appendChild(Pa);ra=b.createMermaidXml("%% Input: "+Ma+"\n"+ra,EditorUi.defaultMermaidConfig,Fa,Ka,Xa);var Ra="<mxfile><diagram>"+Graph.compress(ra)+"</diagram></mxfile>";if(Ga||"undefined"===typeof mxMermaidToDrawio)ba=na=ra;ra=g.cloneNode(!0);ma.appendChild(ra);Fa=function(Oa){O=null!=b.sidebar.tooltip&&"none"!=b.sidebar.tooltip.style.display};Ka=function(Oa){O||x(Ra,mxEvent.getClientX(Oa),mxEvent.getClientY(Oa), Pa,Ma)};mxEvent.addGestureListeners(Pa,Fa,null,Ka);mxEvent.addGestureListeners(ra,Fa,null,Ka)},function(ra){b.handleError(ra)})});La.setAttribute("disabled","disabled");La.className="geBtn gePrimaryBtn";oa=function(){window.setTimeout(function(){""!=la.value?La.removeAttribute("disabled"):La.setAttribute("disabled","disabled")},0)};ja=urlParams["smart-template"];null!=ja&&"1"!=ja&&(la.value=decodeURIComponent(ja),oa(),"1"==urlParams["smart-template-generate"]&&window.setTimeout(function(){La.click()},
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe
"#ffffff");this.convertImages(ea.getSvg(null,null,fa,na,null,R,null,null,null,Z,null,za,Ca,Ba),mxUtils.bind(this,function(ca){try{var qa=new Image;qa.onload=mxUtils.bind(this,function(){try{var Aa=function(){mxClient.IS_SF?window.setTimeout(function(){pa.drawImage(qa,0,0);g(xa,ca)},0):(pa.drawImage(qa,0,0),g(xa,ca))},xa=document.createElement("canvas"),wa=parseInt(ca.getAttribute("width")),Qa=parseInt(ca.getAttribute("height"));W=null!=W?W:1;null!=y&&(W=V?Math.min(1,Math.min(3*y/(4*Qa),y/wa)):y/wa);
1
JavaScript
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
https://cwe.mitre.org/data/definitions/79.html
safe