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:
{88:F.actions.get("selectChildren"),84:F.actions.get("selectSubtree"),80:F.actions.get("selectParent"),83:F.actions.get("selectSiblings")},O=F.onKeyDown;F.onKeyDown=function(I){try{if(C.isEnabled()&&!C.isEditing()&&n(C.getSelectionCell())&&1==C.getSelectionCount()){var V=null;0<C.getIncomingTreeEdges(C.getSelectionCell()).length&&(9==I.which?V=mxEvent.isShiftDown(I)?g(C.getSelectionCell()):m(C.getSelectionCell()):13==I.which&&(V=f(C.getSelectionCell(),!mxEvent.isShiftDown(I))));if(null!=V&&0<V.length)1==
V.length&&C.model.isEdge(V[0])?C.setSelectionCell(C.model.getTerminal(V[0],!1)):C.setSelectionCell(V[V.length-1]),null!=F.hoverIcons&&F.hoverIcons.update(C.view.getState(C.getSelectionCell())),C.startEditingAtCell(C.getSelectionCell()),mxEvent.consume(I);else if(mxEvent.isAltDown(I)&&mxEvent.isShiftDown(I)){var Q=qa[I.keyCode];null!=Q&&(Q.funct(I),mxEvent.consume(I))}else 37==I.keyCode?(y(C.getSelectionCell(),mxConstants.DIRECTION_WEST),mxEvent.consume(I)):38==I.keyCode?(y(C.getSelectionCell(),mxConstants.DIRECTION_NORTH),
mxEvent.consume(I)):39==I.keyCode?(y(C.getSelectionCell(),mxConstants.DIRECTION_EAST),mxEvent.consume(I)):40==I.keyCode&&(y(C.getSelectionCell(),mxConstants.DIRECTION_SOUTH),mxEvent.consume(I))}}catch(R){F.handleError(R)}mxEvent.isConsumed(I)||O.apply(this,arguments)};var X=C.connectVertex;C.connectVertex=function(I,V,Q,R,fa,la,ra){var u=C.getIncomingTreeEdges(I);if(n(I)){var J=d(I),N=J==mxConstants.DIRECTION_EAST||J==mxConstants.DIRECTION_WEST,W=V==mxConstants.DIRECTION_EAST||V==mxConstants.DIRECTION_WEST;