Language: JavaScript
Label: safe
CWE: CWE-400 \u2014 Uncontrolled Resource Consumption
The product does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources.

Code:
Sidebar.prototype.addClickHandler=function(a,b,f){var e=b.mouseDown,g=b.mouseMove,d=b.mouseUp,k=this.editorUi.editor.graph.tolerance,n=null,u=this;b.mouseDown=function(m){e.apply(this,arguments);n=new mxPoint(mxEvent.getClientX(m),mxEvent.getClientY(m));null!=this.dragElement&&(this.dragElement.style.display="none",mxUtils.setOpacity(a,50))};b.mouseMove=function(m){null!=this.dragElement&&"none"==this.dragElement.style.display&&null!=n&&(Math.abs(n.x-mxEvent.getClientX(m))>k||Math.abs(n.y-mxEvent.getClientY(m))>