Language: JavaScript
Label: vulnerable
CWE: CWE-78 \u2014 Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.

Code:
"https://app.diagrams.net/";var y=c.editor.getEditBlankUrl;this.editor.getEditBlankUrl=function(B){B=null!=B?B:"";"1"==urlParams.dev&&(B+=(0<B.length?"&":"?")+"dev=1");return y.apply(this,arguments)};var A=e.addClickHandler;e.addClickHandler=function(B,H,g){var x=H;H=function(F,M){if(null==M){var P=mxEvent.getSource(F);"a"==P.nodeName.toLowerCase()&&(M=P.getAttribute("href"))}null!=M&&e.isCustomLink(M)&&(mxEvent.isTouchEvent(F)||!mxEvent.isPopupTrigger(F))&&e.customLinkClicked(M)&&mxEvent.consume(F);
null!=x&&x(F,M)};A.call(this,B,H,g)};u.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(e.view.canvas.ownerSVGElement,null,!0);if(null!=this.menus){var G=Menus.prototype.addPopupMenuItems;this.menus.addPopupMenuItems=function(B,H,g){e.isSelectionEmpty()&&"simple"==Editor.currentTheme&&this.addMenuItems(B,["zoomIn","zoomOut","-"],null,g);G.apply(this,arguments);e.isSelectionEmpty()||null==c.addSelectionToScratchpad||this.addMenuItems(B,["-","addToScratchpad"],null,g);e.isSelectionEmpty()&&