UNPKG

javascript-obfuscator

Version:
24 lines (21 loc) 487 kB
/*! Copyright (C) 2016-2020 Timofey Kachalov <sanex3339@yandex.ru> Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ require("source-map-support").install(),module.exports=function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(o,n,function(t){return e[t]}.bind(null,n));return o},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=308)}([function(e,t){e.exports=require("inversify")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ServiceIdentifiers=void 0,function(e){e.Factory__ICalleeDataExtractor="Factory<ICalleeDataExtractor>",e.Factory__ICodeTransformer="Factory<ICodeTransformer[]>",e.Factory__IControlFlowCustomNode="Factory<IControlFlowCustomNode>",e.Factory__IControlFlowReplacer="Factory<IControlFlowReplacer>",e.Factory__ICustomCodeHelper="Factory<ICustomCodeHelper>",e.Factory__ICustomCodeHelperGroup="Factory<ICustomCodeHelperGroup>",e.Factory__IDeadCodeInjectionCustomNode="Factory<IDeadCodeInjectionCustomNode>",e.Factory__IIdentifierNamesGenerator="Factory<IIdentifierNamesGenerator>",e.Factory__INodeGuard="Factory<INodeGuard>",e.Factory__INodeTransformer="Factory<INodeTransformer[]>",e.Factory__IObfuscatedCode="Factory<IObfuscatedCode>",e.Factory__IObjectExpressionKeysTransformerCustomNode="Factory<IObjectExpressionKeysTransformerCustomNode>",e.Factory__IObjectExpressionExtractor="Factory<IObjectExpressionExtractor>",e.Factory__IStringArrayCustomNode="Factory<IStringArrayCustomNode>",e.Factory__TControlFlowStorage="Factory<TControlFlowStorage>",e.IArrayUtils="IArrayUtils",e.ICalleeDataExtractor="ICalleeDataExtractor",e.ICallsGraphAnalyzer="ICallsGraphAnalyzer",e.ICodeTransformer="ICodeTransformer",e.ICodeTransformerNamesGroupsBuilder="ICodeTransformerNamesGroupsBuilder",e.ICodeTransformersRunner="ICodeTransformersRunner",e.ICryptUtils="ICryptUtils",e.ICryptUtilsSwappedAlphabet="ICryptUtilsSwappedAlphabet",e.ICustomCodeHelper="ICustomCodeHelper",e.ICustomCodeHelperGroup="ICustomCodeHelperGroup",e.IControlFlowReplacer="IControlFlowReplacer",e.ICustomCodeHelperFormatter="ICustomCodeHelperFormatter",e.ICustomCodeHelperObfuscator="ICustomCodeHelperObfuscator",e.IEscapeSequenceEncoder="IEscapeSequenceEncoder",e.IIdentifierNamesGenerator="IIdentifierNamesGenerator",e.IIdentifierReplacer="IIdentifierReplacer",e.IJavaScriptObfuscator="IJavaScriptObfuscator",e.ILevelledTopologicalSorter="ILevelledTopologicalSorter",e.ILiteralNodesCacheStorage="ILiteralNodesCacheStorage",e.ILogger="ILogger",e.INodeGuard="INodeGuard",e.INodeTransformer="INodeTransformer",e.INodeTransformerNamesGroupsBuilder="INodeTransformerNamesGroupsBuilder",e.INodeTransformersRunner="INodeTransformersRunner",e.INumberNumericalExpressionAnalyzer="INumberNumericalExpressionAnalyzer",e.IObfuscationEventEmitter="IObfuscationEventEmitter",e.IObfuscatedCode="IObfuscatedCode",e.IOptions="IOptions",e.IOptionsNormalizer="IOptionsNormalizer",e.IPrevailingKindOfVariablesAnalyzer="IPrevailingKindOfVariablesAnalyzer",e.IObjectExpressionExtractor="IObjectExpressionExtractor",e.IRandomGenerator="IRandomGenerator",e.IRenamePropertiesReplacer="IRenamePropertiesReplacer",e.IScopeIdentifiersTraverser="IScopeIdentifiersTraverser",e.ISourceCode="ISourceCode",e.IScopeAnalyzer="IScopeAnalyzer",e.IStringArrayScopeCallsWrapperLexicalScopeDataStorage="IStringArrayScopeCallsWrapperLexicalScopeDataStorage",e.IStringArrayScopeCallsWrapperNamesDataStorage="IStringArrayScopeCallsWrapperNamesDataStorage",e.IStringArrayStorage="IStringArrayStorage",e.IStringArrayStorageAnalyzer="IStringArrayStorageAnalyzer",e.IVisitedLexicalScopeNodesStackStorage="IVisitedLexicalScopeNodesStackStorage",e.Newable__ICustomNode="Newable<ICustomNode>",e.Newable__TControlFlowStorage="Newable<TControlFlowStorage>",e.TCustomNodeGroupStorage="TCustomNodeGroupStorage",e.TInputOptions="TInputOptions"}(t.ServiceIdentifiers||(t.ServiceIdentifiers={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeGuards=void 0;const o=r(46);class n{static isArrayPatternNode(e){return e.type===o.NodeType.ArrayPattern}static isArrowFunctionExpressionNode(e){return e.type===o.NodeType.ArrowFunctionExpression}static isAssignmentExpressionNode(e){return e.type===o.NodeType.AssignmentExpression}static isAssignmentPatternNode(e){return e.type===o.NodeType.AssignmentPattern}static isAwaitExpressionNode(e){return e.type===o.NodeType.AwaitExpression}static isBigIntLiteralNode(e){return n.isLiteralNode(e)&&!!e.bigint}static isBlockStatementNode(e){return e.type===o.NodeType.BlockStatement}static isBreakStatementNode(e){return e.type===o.NodeType.BreakStatement}static isCallExpressionNode(e){return e.type===o.NodeType.CallExpression}static isClassDeclarationNode(e){return e.type===o.NodeType.ClassDeclaration&&null!==e.id}static isContinueStatementNode(e){return e.type===o.NodeType.ContinueStatement}static isDirectiveNode(e){return e.type===o.NodeType.ExpressionStatement&&"directive"in e}static isExportAllDeclarationNode(e){return e.type===o.NodeType.ExportAllDeclaration}static isExportNamedDeclarationNode(e){return e.type===o.NodeType.ExportNamedDeclaration}static isExpressionStatementNode(e){return e.type===o.NodeType.ExpressionStatement&&!("directive"in e)}static isForOfStatementNode(e){return e.type===o.NodeType.ForOfStatement}static isFunctionNode(e){return n.isFunctionDeclarationNode(e)||n.isFunctionExpressionNode(e)||n.isArrowFunctionExpressionNode(e)}static isFunctionDeclarationNode(e){return e.type===o.NodeType.FunctionDeclaration&&null!==e.id}static isFunctionExpressionNode(e){return e.type===o.NodeType.FunctionExpression}static isIdentifierNode(e){return e.type===o.NodeType.Identifier}static isIfStatementNode(e){return e.type===o.NodeType.IfStatement}static isImportDeclarationNode(e){return e.type===o.NodeType.ImportDeclaration}static isImportSpecifierNode(e){return e.type===o.NodeType.ImportSpecifier}static isLabelIdentifierNode(e,t){const r=n.isLabeledStatementNode(t)&&t.label===e,o=n.isContinueStatementNode(t)&&t.label===e,i=n.isBreakStatementNode(t)&&t.label===e;return r||o||i}static isLabeledStatementNode(e){return e.type===o.NodeType.LabeledStatement}static isLiteralNode(e){return e.type===o.NodeType.Literal}static isMemberExpressionNode(e){return e.type===o.NodeType.MemberExpression}static isMethodDefinitionNode(e){return e.type===o.NodeType.MethodDefinition}static isNode(e){return e&&void 0!==!e.type}static isNodeWithLexicalScope(e){return n.isProgramNode(e)||n.isFunctionNode(e)}static isNodeWithBlockLexicalScope(e){return n.isNodeWithLexicalScope(e)||n.isBlockStatementNode(e)}static isNodeWithLexicalScopeStatements(e,t){return n.isProgramNode(e)||n.isBlockStatementNode(e)&&n.nodesWithLexicalStatements.includes(t.type)}static isNodeWithStatements(e){return n.isProgramNode(e)||n.isBlockStatementNode(e)||n.isSwitchCaseNode(e)}static isNodeWithComments(e){return Boolean(e.leadingComments)||Boolean(e.trailingComments)}static isObjectPatternNode(e){return e.type===o.NodeType.ObjectPattern}static isObjectExpressionNode(e){return e.type===o.NodeType.ObjectExpression}static isProgramNode(e){return e.type===o.NodeType.Program}static isPropertyNode(e){return e.type===o.NodeType.Property}static isRestElementNode(e){return e.type===o.NodeType.RestElement}static isReturnStatementNode(e){return e.type===o.NodeType.ReturnStatement}static isSequenceExpressionNode(e){return e.type===o.NodeType.SequenceExpression}static isSuperNode(e){return e.type===o.NodeType.Super}static isSwitchCaseNode(e){return e.type===o.NodeType.SwitchCase}static isTaggedTemplateExpressionNode(e){return e.type===o.NodeType.TaggedTemplateExpression}static isTemplateLiteralNode(e){return e.type===o.NodeType.TemplateLiteral}static isUnaryExpressionNode(e){return e.type===o.NodeType.UnaryExpression}static isUseStrictOperator(e){return n.isDirectiveNode(e)&&"use strict"===e.directive}static isVariableDeclarationNode(e){return e.type===o.NodeType.VariableDeclaration}static isVariableDeclaratorNode(e){return e.type===o.NodeType.VariableDeclarator}static isWhileStatementNode(e){return e.type===o.NodeType.WhileStatement}static isYieldExpressionNode(e){return e.type===o.NodeType.YieldExpression}}t.NodeGuards=n,n.nodesWithLexicalStatements=[o.NodeType.ArrowFunctionExpression,o.NodeType.FunctionDeclaration,o.NodeType.FunctionExpression,o.NodeType.MethodDefinition]},function(e,t,r){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,r,o){void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,o){void 0===o&&(o=r),e[o]=t[r]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&o(t,e,r);return n(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.NodeUtils=void 0;const a=i(r(52)),s=i(r(13)),c=r(50),l=r(67),d=r(4),u=r(20);class f{static addXVerbatimPropertyTo(e){return e["x-verbatim-property"]={content:e.raw,precedence:a.Precedence.Primary},e}static clone(e){return f.parentizeAst(f.cloneRecursive(e))}static convertCodeToStructure(e){const t=l.ASTParserFacade.parse(e,{ecmaVersion:c.ecmaVersion,sourceType:"script"});return s.replace(t,{enter:(e,t)=>(f.parentizeNode(e,t),d.NodeGuards.isLiteralNode(e)&&f.addXVerbatimPropertyTo(e),u.NodeMetadata.set(e,{ignoredNode:!1}),e)}),t.body}static convertStructureToCode(e){return e.reduce((e,t)=>e+a.generate(t,{sourceMapWithCode:!0}).code,"")}static getUnaryExpressionArgumentNode(e){return d.NodeGuards.isUnaryExpressionNode(e.argument)?f.getUnaryExpressionArgumentNode(e.argument):e.argument}static parentizeAst(e){var t;const r=null!==(t=e.parentNode)&&void 0!==t?t:null;return s.replace(e,{enter:f.parentizeNode}),r&&(e.parentNode=r),e}static parentizeNode(e,t){return e.parentNode=null!=t?t:e,e}static cloneRecursive(e){if(null===e)return e;const t={};return Object.keys(e).forEach(r=>{var o;if("parentNode"===r)return;const n=null!==(o=e[r])&&void 0!==o?o:null;let i;i=null===n||n instanceof RegExp?n:n instanceof Array?n.map(f.cloneRecursive):"object"==typeof n?f.cloneRecursive(n):n,t[r]=i}),t}}t.NodeUtils=f},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,r,o){void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,o){void 0===o&&(o=r),e[o]=t[r]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&o(t,e,r);return n(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.NodeFactory=void 0;const a=i(r(52)),s=r(46);class c{static programNode(e=[]){return{type:s.NodeType.Program,body:e,sourceType:"script",metadata:{ignoredNode:!1}}}static arrayExpressionNode(e=[]){return{type:s.NodeType.ArrayExpression,elements:e,metadata:{ignoredNode:!1}}}static arrowFunctionExpressionNode(e,t,r){return{type:s.NodeType.ArrowFunctionExpression,params:e,expression:t,body:r}}static assignmentExpressionNode(e,t,r){return{type:s.NodeType.AssignmentExpression,operator:e,left:t,right:r,metadata:{ignoredNode:!1}}}static binaryExpressionNode(e,t,r){return{type:s.NodeType.BinaryExpression,operator:e,left:t,right:r,metadata:{ignoredNode:!1}}}static blockStatementNode(e=[]){return{type:s.NodeType.BlockStatement,body:e,metadata:{ignoredNode:!1}}}static breakStatement(e){return{type:s.NodeType.BreakStatement,label:e,metadata:{ignoredNode:!1}}}static callExpressionNode(e,t=[],r=!1){return{type:s.NodeType.CallExpression,callee:e,optional:r,arguments:t,metadata:{ignoredNode:!1}}}static conditionalExpressionNode(e,t,r){return{type:s.NodeType.ConditionalExpression,test:e,consequent:t,alternate:r,metadata:{ignoredNode:!1}}}static continueStatement(e){return{type:s.NodeType.ContinueStatement,label:e,metadata:{ignoredNode:!1}}}static directiveNode(e,t){return{type:s.NodeType.ExpressionStatement,expression:e,directive:t,metadata:{ignoredNode:!1}}}static exportAllDeclarationNode(e){return{type:s.NodeType.ExportAllDeclaration,source:e,metadata:{ignoredNode:!1}}}static exportNamedDeclarationNode(e,t){return{type:s.NodeType.ExportNamedDeclaration,specifiers:e,source:t,metadata:{ignoredNode:!1}}}static expressionStatementNode(e){return{type:s.NodeType.ExpressionStatement,expression:e,metadata:{ignoredNode:!1}}}static functionDeclarationNode(e,t,r){return{type:s.NodeType.FunctionDeclaration,id:c.identifierNode(e),params:t,body:r,generator:!1,metadata:{ignoredNode:!1}}}static functionExpressionNode(e,t){return{type:s.NodeType.FunctionExpression,params:e,body:t,generator:!1,metadata:{ignoredNode:!1}}}static ifStatementNode(e,t,r){return Object.assign(Object.assign({type:s.NodeType.IfStatement,test:e,consequent:t},r&&{alternate:r}),{metadata:{ignoredNode:!1}})}static identifierNode(e){return{type:s.NodeType.Identifier,name:e,metadata:{ignoredNode:!1}}}static importDeclarationNode(e,t){return{type:s.NodeType.ImportDeclaration,specifiers:e,source:t,metadata:{ignoredNode:!1}}}static literalNode(e,t){return t=void 0!==t?t:`'${e}'`,{type:s.NodeType.Literal,value:e,raw:t,"x-verbatim-property":{content:t,precedence:a.Precedence.Primary},metadata:{ignoredNode:!1}}}static logicalExpressionNode(e,t,r){return{type:s.NodeType.LogicalExpression,operator:e,left:t,right:r,metadata:{ignoredNode:!1}}}static memberExpressionNode(e,t,r=!1,o=!1){return{type:s.NodeType.MemberExpression,computed:r,object:e,optional:o,property:t,metadata:{ignoredNode:!1}}}static objectExpressionNode(e){return{type:s.NodeType.ObjectExpression,properties:e,metadata:{ignoredNode:!1}}}static propertyNode(e,t,r=!1){return{type:s.NodeType.Property,key:e,value:t,kind:"init",method:!1,shorthand:!1,computed:r,metadata:{ignoredNode:!1}}}static returnStatementNode(e){return{type:s.NodeType.ReturnStatement,argument:e,metadata:{ignoredNode:!1}}}static sequenceExpressionNode(e){return{type:s.NodeType.SequenceExpression,expressions:e,metadata:{ignoredNode:!1}}}static switchStatementNode(e,t){return{type:s.NodeType.SwitchStatement,discriminant:e,cases:t,metadata:{ignoredNode:!1}}}static switchCaseNode(e,t){return{type:s.NodeType.SwitchCase,test:e,consequent:t,metadata:{ignoredNode:!1}}}static unaryExpressionNode(e,t,r=!0){return{type:s.NodeType.UnaryExpression,operator:e,argument:t,prefix:r,metadata:{ignoredNode:!1}}}static updateExpressionNode(e,t){return{type:s.NodeType.UpdateExpression,operator:e,argument:t,prefix:!1,metadata:{ignoredNode:!1}}}static templateElement(e,t){return{type:s.NodeType.TemplateElement,value:e,tail:t,metadata:{ignoredNode:!1}}}static templateLiteral(e,t){return{type:s.NodeType.TemplateLiteral,expressions:e,quasis:t,metadata:{ignoredNode:!1}}}static variableDeclarationNode(e=[],t="var"){return{type:s.NodeType.VariableDeclaration,declarations:e,kind:t,metadata:{ignoredNode:!1}}}static variableDeclaratorNode(e,t){return{type:s.NodeType.VariableDeclarator,id:e,init:t,metadata:{ignoredNode:!1}}}static whileStatementNode(e,t){return{type:s.NodeType.WhileStatement,test:e,body:t,metadata:{ignoredNode:!1}}}}t.NodeFactory=c},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeTransformationStage=void 0,function(e){e.ControlFlowFlattening="ControlFlowFlattening",e.Converting="Converting",e.DeadCodeInjection="DeadCodeInjection",e.Finalizing="Finalizing",e.Initializing="Initializing",e.Preparing="Preparing",e.RenameIdentifiers="RenameIdentifiers",e.RenameProperties="RenameProperties",e.Simplifying="Simplifying",e.StringArray="StringArray"}(t.NodeTransformationStage||(t.NodeTransformationStage={}))},function(e,t,r){"use strict";var o,n,i=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},s=this&&this.__param||function(e,t){return function(r,o){t(r,o,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractNodeTransformer=void 0;const c=r(0),l=r(1),d=r(2),u=r(3);let f=class{constructor(e,t){this.randomGenerator=e,this.options=t}};f=i([c.injectable(),s(0,c.inject(l.ServiceIdentifiers.IRandomGenerator)),s(1,c.inject(l.ServiceIdentifiers.IOptions)),a("design:paramtypes",["function"==typeof(o=void 0!==u.IRandomGenerator&&u.IRandomGenerator)?o:Object,"function"==typeof(n=void 0!==d.IOptions&&d.IOptions)?n:Object])],f),t.AbstractNodeTransformer=f},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.initializable=void 0;const o={configurable:!0,enumerable:!0};function n(e,t,r){Reflect.hasMetadata(e,r)||Reflect.defineMetadata(e,t,r)}t.initializable=function(e="initialize"){const t=Object.keys(this)[0];return(r,i)=>{const a=r[e];if(!a||"function"!=typeof a)throw new Error(`\`${e}\` method with initialization logic not `+`found. \`@${t}\` decorator requires \`${e}\` method`);return n("_initialized",!1,r),n("_initializablePropertiesSet",new Set,r),n("_wrappedMethodsSet",new Set,r),function(e,t){const r=Object.getOwnPropertyNames(e),n=[t,"constructor"];r.forEach(r=>{var i;const a=Reflect.getMetadata("_initializablePropertiesSet",e),s=Reflect.getMetadata("_wrappedMethodsSet",e);if(n.includes(r)||a.has(r)||s.has(r))return;if("function"!=typeof e[r])return;const c=null!==(i=Object.getOwnPropertyDescriptor(e,r))&&void 0!==i?i:o,l=c.value;Object.defineProperty(e,r,Object.assign(Object.assign({},c),{value(){if(!Reflect.getMetadata("_initialized",this))throw new Error(`Class should be initialized with \`${t}()\` method`);return l.apply(this,arguments)}})),s.add(r)})}(r,e),function(e,t,r){var n;const i=null!==(n=Object.getOwnPropertyDescriptor(e,t))&&void 0!==n?n:o,a=i.value;Object.defineProperty(e,t,Object.assign(Object.assign({},i),{value:function(){Reflect.defineMetadata("_initialized",!0,this);const e=a.apply(this,arguments);return this[r],e}}))}(r,e,i),function(e,t){var r;Reflect.getMetadata("_initializablePropertiesSet",e).add(t);const n=`_${t.toString()}`,i=null!==(r=Object.getOwnPropertyDescriptor(e,n))&&void 0!==r?r:o;return Object.defineProperty(e,t,Object.assign(Object.assign({},i),{get:function(){if(void 0===this[n])throw new Error(`Property \`${t.toString()}\` is not initialized! Initialize it first!`);return this[n]},set:function(e){this[n]=e}})),i}(r,i)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeTransformer=void 0,function(e){e.BooleanLiteralTransformer="BooleanLiteralTransformer",e.BlockStatementControlFlowTransformer="BlockStatementControlFlowTransformer",e.BlockStatementSimplifyTransformer="BlockStatementSimplifyTransformer",e.CommentsTransformer="CommentsTransformer",e.CustomCodeHelpersTransformer="CustomCodeHelpersTransformer",e.DeadCodeInjectionTransformer="DeadCodeInjectionTransformer",e.EscapeSequenceTransformer="EscapeSequenceTransformer",e.EvalCallExpressionTransformer="EvalCallExpressionTransformer",e.ExpressionStatementsMergeTransformer="ExpressionStatementsMergeTransformer",e.FunctionControlFlowTransformer="FunctionControlFlowTransformer",e.IfStatementSimplifyTransformer="IfStatementSimplifyTransformer",e.LabeledStatementTransformer="LabeledStatementTransformer",e.MemberExpressionTransformer="MemberExpressionTransformer",e.MetadataTransformer="MetadataTransformer",e.MethodDefinitionTransformer="MethodDefinitionTransformer",e.NumberLiteralTransformer="NumberLiteralTransformer",e.NumberToNumericalExpressionTransformer="NumberToNumericalExpressionTransformer",e.ObfuscatingGuardsTransformer="ObfuscatingGuardsTransformer",e.ObjectExpressionKeysTransformer="ObjectExpressionKeysTransformer",e.ObjectExpressionTransformer="ObjectExpressionTransformer",e.ObjectPatternPropertiesTransformer="ObjectPatternPropertiesTransformer",e.ParentificationTransformer="ParentificationTransformer",e.RenamePropertiesTransformer="RenamePropertiesTransformer",e.ScopeIdentifiersTransformer="ScopeIdentifiersTransformer",e.ScopeThroughIdentifiersTransformer="ScopeThroughIdentifiersTransformer",e.SplitStringTransformer="SplitStringTransformer",e.StringArrayTransformer="StringArrayTransformer",e.StringArrayScopeCallsWrapperTransformer="StringArrayScopeCallsWrapperTransformer",e.TemplateLiteralTransformer="TemplateLiteralTransformer",e.VariableDeclarationsMergeTransformer="VariableDeclarationsMergeTransformer",e.VariablePreserveTransformer="VariablePreserveTransformer"}(t.NodeTransformer||(t.NodeTransformer={}))},function(e,t){e.exports=require("estraverse")},function(e,t,r){"use strict";var o,n,i,a,s=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a},c=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},l=this&&this.__param||function(e,t){return function(r,o){t(r,o,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractCustomNode=void 0;const d=r(0),u=r(1),f=r(6),p=r(11),m=r(2),g=r(3);let S=class{constructor(e,t,r,o){this.cachedNode=null,this.identifierNamesGenerator=e(o),this.customCodeHelperFormatter=t,this.randomGenerator=r,this.options=o}getNode(){return this.cachedNode||(this.cachedNode=this.customCodeHelperFormatter.formatStructure(this.getNodeStructure())),this.cachedNode}};S=s([d.injectable(),l(0,d.inject(u.ServiceIdentifiers.Factory__IIdentifierNamesGenerator)),l(1,d.inject(u.ServiceIdentifiers.ICustomCodeHelperFormatter)),l(2,d.inject(u.ServiceIdentifiers.IRandomGenerator)),l(3,d.inject(u.ServiceIdentifiers.IOptions)),c("design:paramtypes",["function"==typeof(o=void 0!==f.TIdentifierNamesGeneratorFactory&&f.TIdentifierNamesGeneratorFactory)?o:Object,"function"==typeof(n=void 0!==p.ICustomCodeHelperFormatter&&p.ICustomCodeHelperFormatter)?n:Object,"function"==typeof(i=void 0!==g.IRandomGenerator&&g.IRandomGenerator)?i:Object,"function"==typeof(a=void 0!==m.IOptions&&m.IOptions)?a:Object])],S),t.AbstractCustomNode=S},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeStatementUtils=void 0;const o=r(4);class n{static getParentNodeWithStatements(e){return n.getParentNodesWithStatementsRecursive(e,1)[0]}static getParentNodesWithStatements(e){return n.getParentNodesWithStatementsRecursive(e)}static getNextSiblingStatement(e){return n.getSiblingStatementByOffset(e,1)}static getPreviousSiblingStatement(e){return n.getSiblingStatementByOffset(e,-1)}static getRootStatementOfNode(e){if(o.NodeGuards.isProgramNode(e))throw new Error("Unable to find root statement for `Program` node");const t=e.parentNode;if(!t)throw new ReferenceError("`parentNode` property of given node is `undefined`");return o.NodeGuards.isNodeWithStatements(t)?e:n.getRootStatementOfNode(t)}static getScopeOfNode(e){const t=e.parentNode;if(!t)throw new ReferenceError("`parentNode` property of given node is `undefined`");return o.NodeGuards.isNodeWithStatements(t)?t:n.getScopeOfNode(t)}static getParentNodesWithStatementsRecursive(e,t=1/0,r=[],i=0){if(r.length>=t)return r;const a=e.parentNode;if(!a)throw new ReferenceError("`parentNode` property of given node is `undefined`");return(o.NodeGuards.isProgramNode(e)||o.NodeGuards.isNodeWithLexicalScopeStatements(e,a)&&i>0)&&r.push(e),e!==a?n.getParentNodesWithStatementsRecursive(a,t,r,++i):r}static getSiblingStatementByOffset(e,t){const r=n.getScopeOfNode(e),i=o.NodeGuards.isSwitchCaseNode(r)?r.consequent:r.body,a=i.indexOf(e);return i[a+t]||null}}t.NodeStatementUtils=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StringArrayEncoding=void 0;const o=r(27);t.StringArrayEncoding=o.MakeEnum({None:"none",Base64:"base64",Rc4:"rc4"})},function(e,t,r){"use strict";var o,n,i,a,s,c,l=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a},d=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},u=this&&this.__param||function(e,t){return function(r,o){t(r,o,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractCustomCodeHelper=void 0;const f=r(0),p=r(1),m=r(6),g=r(11),S=r(16),N=r(2),_=r(3),y=r(149),h=r(150);let b=o=class{constructor(e,t,r,o,n){this.cachedNode=null,this.identifierNamesGenerator=e(n),this.customCodeHelperFormatter=t,this.customCodeHelperObfuscator=r,this.randomGenerator=o,this.options=n}getNode(){if(!this.cachedNode){const e=this.getCodeHelperTemplate();this.cachedNode=this.customCodeHelperFormatter.formatStructure(this.getNodeStructure(e))}return this.cachedNode}getGlobalVariableTemplate(){return this.randomGenerator.getRandomGenerator().pickone(o.globalVariableTemplateFunctions)}getCodeHelperTemplate(){return""}};b.globalVariableTemplateFunctions=[y.GlobalVariableTemplate1(),h.GlobalVariableTemplate2()],b=o=l([f.injectable(),u(0,f.inject(p.ServiceIdentifiers.Factory__IIdentifierNamesGenerator)),u(1,f.inject(p.ServiceIdentifiers.ICustomCodeHelperFormatter)),u(2,f.inject(p.ServiceIdentifiers.ICustomCodeHelperObfuscator)),u(3,f.inject(p.ServiceIdentifiers.IRandomGenerator)),u(4,f.inject(p.ServiceIdentifiers.IOptions)),d("design:paramtypes",["function"==typeof(n=void 0!==m.TIdentifierNamesGeneratorFactory&&m.TIdentifierNamesGeneratorFactory)?n:Object,"function"==typeof(i=void 0!==g.ICustomCodeHelperFormatter&&g.ICustomCodeHelperFormatter)?i:Object,"function"==typeof(a=void 0!==S.ICustomCodeHelperObfuscator&&S.ICustomCodeHelperObfuscator)?a:Object,"function"==typeof(s=void 0!==_.IRandomGenerator&&_.IRandomGenerator)?s:Object,"function"==typeof(c=void 0!==N.IOptions&&N.IOptions)?c:Object])],b),t.AbstractCustomCodeHelper=b},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InversifyContainerFacade=void 0;const o=r(0),n=r(1),i=r(98),a=r(109),s=r(114),c=r(124),l=r(141),d=r(183),u=r(199),f=r(202),p=r(204),m=r(208),g=r(210),S=r(213),N=r(215),_=r(238),y=r(252),h=r(257),b=r(262),O=r(267),I=r(278),E=r(283),C=r(292),v=r(294),T=r(95),R=r(299),A=r(302),M=r(304),j=r(305);t.InversifyContainerFacade=class{constructor(){this.container=new o.Container}static getFactory(e){return t=>r=>t.container.getNamed(e,r)}static getCacheFactory(e){return t=>{const r=new Map;return o=>{if(r.has(o))return r.get(o);const n=t.container.getNamed(e,o);return r.set(o,n),n}}}static getConstructorFactory(e,...t){return r=>{const o=new Map,n=[];return i=>{if(t.forEach((e,t)=>{n[t]||(n[t]=r.container.get(e))}),o.has(i))return new(o.get(i))(...n);const a=r.container.getNamed(e,i);return o.set(i,a),new a(...n)}}}get(e){return this.container.get(e)}getNamed(e,t){return this.container.getNamed(e,t)}load(e,t,r){this.container.bind(n.ServiceIdentifiers.ISourceCode).toDynamicValue(()=>new j.SourceCode(e,t)).inSingletonScope(),this.container.bind(n.ServiceIdentifiers.TInputOptions).toDynamicValue(()=>r).inSingletonScope(),this.container.bind(n.ServiceIdentifiers.ILogger).to(T.Logger).inSingletonScope(),this.container.bind(n.ServiceIdentifiers.IJavaScriptObfuscator).to(v.JavaScriptObfuscator).inSingletonScope(),this.container.bind(n.ServiceIdentifiers.ICodeTransformersRunner).to(C.CodeTransformersRunner).inSingletonScope(),this.container.bind(n.ServiceIdentifiers.INodeTransformersRunner).to(R.NodeTransformersRunner).inSingletonScope(),this.container.bind(n.ServiceIdentifiers.IObfuscatedCode).to(M.ObfuscatedCode),this.container.bind(n.ServiceIdentifiers.Factory__IObfuscatedCode).toFactory(e=>(t,r)=>{const o=e.container.get(n.ServiceIdentifiers.IObfuscatedCode);return o.initialize(t,r),o}),this.container.bind(n.ServiceIdentifiers.IObfuscationEventEmitter).to(A.ObfuscationEventEmitter).inSingletonScope(),this.container.load(i.analyzersModule),this.container.load(a.codeTransformersModule),this.container.load(s.controlFlowTransformersModule),this.container.load(c.convertingTransformersModule),this.container.load(l.customCodeHelpersModule),this.container.load(d.customNodesModule),this.container.load(u.deadCodeInjectionTransformersModule),this.container.load(f.finalizingTransformersModule),this.container.load(p.generatorsModule),this.container.load(m.initializingTransformersModule),this.container.load(g.nodeModule),this.container.load(S.nodeTransformersModule),this.container.load(N.optionsModule),this.container.load(_.preparingTransformersModule),this.container.load(y.renameIdentifiersTransformersModule),this.container.load(h.renamePropertiesTransformersModule),this.container.load(b.simplifyingTransformersModule),this.container.load(O.storagesModule),this.container.load(I.stringArrayTransformersModule),this.container.load(E.utilsModule)}unload(){this.container.unbindAll()}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeMetadata=void 0;class o{static set(e,t){var r;e.metadata=Object.assign(null!==(r=e.metadata)&&void 0!==r?r:{},t)}static get(e,t){return void 0!==e.metadata?e.metadata[t]:void 0}static isForceTransformNode(e){return!0===o.get(e,"forceTransformNode")}static isIgnoredNode(e){return!0===o.get(e,"ignoredNode")}static isReplacedLiteral(e){return!0===o.get(e,"replacedLiteral")}}t.NodeMetadata=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeAppender=void 0;const o=r(4);class n{static append(e,t){t=n.parentizeScopeStatementsBeforeAppend(e,t),n.setScopeStatements(e,[...n.getScopeStatements(e),...t])}static appendToOptimalBlockScope(e,t,r,o=0){const i=e.length?n.getOptimalBlockScope(e,o):t;n.prepend(i,r)}static getOptimalBlockScope(e,t,r=1/0){const o=e[t];if(r<=0)throw new Error("Invalid `deep` argument value. Value should be bigger then 0.");return r>1&&o.callsGraph.length?n.getOptimalBlockScope(o.callsGraph,0,--r):o.callee}static insertBefore(e,t,r){const o=n.getScopeStatements(e).indexOf(r);n.insertAtIndex(e,t,o)}static insertAfter(e,t,r){const o=n.getScopeStatements(e).indexOf(r);n.insertAtIndex(e,t,o+1)}static insertAtIndex(e,t,r){t=n.parentizeScopeStatementsBeforeAppend(e,t),n.setScopeStatements(e,[...n.getScopeStatements(e).slice(0,r),...t,...n.getScopeStatements(e).slice(r)])}static prepend(e,t){t=n.parentizeScopeStatementsBeforeAppend(e,t),n.setScopeStatements(e,[...t,...n.getScopeStatements(e)])}static getScopeStatements(e){return o.NodeGuards.isSwitchCaseNode(e)?e.consequent:e.body}static parentizeScopeStatementsBeforeAppend(e,t){return t.forEach(t=>{t.parentNode=e}),t}static setScopeStatements(e,t){o.NodeGuards.isSwitchCaseNode(e)?e.consequent=t:e.body=t}}t.NodeAppender=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeLexicalScopeUtils=void 0;const o=r(4);class n{static getLexicalScope(e){return n.getLexicalScopesRecursive(e,1)[0]}static getLexicalScopes(e){return n.getLexicalScopesRecursive(e)}static getLexicalScopesRecursive(e,t=1/0,r=[],i=0){if(r.length>=t)return r;const a=e.parentNode;if(!a)throw new ReferenceError("`parentNode` property of given node is `undefined`");return o.NodeGuards.isNodeWithLexicalScope(e)&&r.push(e),e!==a?n.getLexicalScopesRecursive(a,t,r,++i):r}}t.NodeLexicalScopeUtils=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ControlFlowCustomNode=void 0,function(e){e.BinaryExpressionFunctionNode="BinaryExpressionFunctionNode",e.BlockStatementControlFlowFlatteningNode="BlockStatementControlFlowFlatteningNode",e.CallExpressionControlFlowStorageCallNode="CallExpressionControlFlowStorageCallNode",e.CallExpressionFunctionNode="CallExpressionFunctionNode",e.ControlFlowStorageNode="ControlFlowStorageNode",e.ExpressionWithOperatorControlFlowStorageCallNode="ExpressionWithOperatorControlFlowStorageCallNode",e.LogicalExpressionFunctionNode="LogicalExpressionFunctionNode",e.StringLiteralControlFlowStorageCallNode="StringLiteralControlFlowStorageCallNode",e.StringLiteralNode="StringLiteralNode"}(t.ControlFlowCustomNode||(t.ControlFlowCustomNode={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ObfuscationTarget=void 0;const o=r(27);t.ObfuscationTarget=o.MakeEnum({Browser:"browser",BrowserNoEval:"browser-no-eval",Node:"node"})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ObfuscationEvent=void 0,function(e){e.AfterObfuscation="afterObfuscation",e.BeforeObfuscation="beforeObfuscation"}(t.ObfuscationEvent||(t.ObfuscationEvent={}))},function(e,t){e.exports=require("@gradecam/tsenum")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Utils=void 0;class o{static buildVersionMessage(e,t){if(!e||!t)return"unknown";return`${e}_${new Date(parseInt(t,10)).toISOString()}`}static extractDomainFrom(e){let t;return t=e.includes("://")||0===e.indexOf("//")?e.split("/")[2]:e.split("/")[0],t=t.split(":")[0],t}static getIdentifiersPrefixForMultipleSources(e,t){return`${e||o.baseMultipleSourcesIdentifiersPrefix}${t}`}}t.Utils=o,o.baseMultipleSourcesIdentifiersPrefix="a",o.hexadecimalPrefix="0x"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StringArrayWrappersType=void 0;const o=r(27);t.StringArrayWrappersType=o.MakeEnum({Variable:"variable",Function:"function"})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NumberUtils=void 0;const o=r(28);t.NumberUtils=class{static toHex(e){const t="number"==typeof e?e.toString(16):`${e.toString(16)}n`;return`${o.Utils.hexadecimalPrefix}${t}`}static isCeil(e){return"number"!=typeof e||e%1==0}static isPositive(e){if(isNaN(e))throw new Error("Given value is NaN");return e>0||!(e<0)&&1/e===Number.POSITIVE_INFINITY}static isUnsafeNumber(e){if(isNaN(e))throw new Error("Given value is NaN");return e<Number.MIN_SAFE_INTEGER||e>Number.MAX_SAFE_INTEGER}static getFactors(e){if(0===e)throw new Error("Invalid number. Allowed only non-zero number");if(1===(e=Math.abs(e)))return[-e,e];const t=[],r=Math.sqrt(e),o=e%2==0?1:2;for(let n=1;n<=r;n+=o){if(e%n!=0)continue;t.push(-n,n);const r=e/n;r!==n&&t.push(-r,r)}return t.sort((e,t)=>e-t)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CustomCodeHelper=void 0,function(e){e.CallsControllerFunction="CallsControllerFunction",e.ConsoleOutputDisable="ConsoleOutputDisable",e.DebugProtectionFunctionCall="DebugProtectionFunctionCall",e.DebugProtectionFunctionInterval="DebugProtectionFunctionInterval",e.DebugProtectionFunction="DebugProtectionFunction",e.DomainLock="DomainLock",e.SelfDefendingUnicode="SelfDefendingUnicode",e.StringArray="StringArray",e.StringArrayCallsWrapper="StringArrayCallsWrapper",e.StringArrayCallsWrapperBase64="StringArrayCallsWrapperBase64",e.StringArrayCallsWrapperRc4="StringArrayCallsWrapperRc4",e.StringArrayRotateFunction="StringArrayRotateFunction"}(t.CustomCodeHelper||(t.CustomCodeHelper={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.alphabetString=void 0,t.alphabetString="abcdefghijklmnopqrstuvwxyz"},function(e,t,r){"use strict";var o,n,i,a=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a},s=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},c=this&&this.__param||function(e,t){return function(r,o){t(r,o,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.MapStorage=void 0;const l=r(0),d=r(1),u=r(2),f=r(3),p=r(10);let m=class{constructor(e,t){this.randomGenerator=e,this.options=t}initialize(){this.storage=new Map,this.storageId=this.randomGenerator.getRandomString(6)}get(e){return this.storage.get(e)}getOrThrow(e){const t=this.get(e);if(!t)throw new Error(`No value found in map storage with key \`${e}\``);return t}getKeyOf(e){for(const[t,r]of this.storage)if(e===r)return t;return null}getLength(){return this.storage.size}getStorage(){return this.storage}getStorageId(){return this.storageId}has(e){return this.storage.has(e)}mergeWith(e,t=!1){this.storage=new Map([...this.storage,...e.getStorage()]),t&&(this.storageId=e.getStorageId())}set(e,t){this.storage.set(e,t)}};a([p.initializable(),s("design:type",String)],m.prototype,"storageId",void 0),a([p.initializable(),s("design:type","function"==typeof(o="undefined"!=typeof Map&&Map)?o:Object)],m.prototype,"storage",void 0),a([l.postConstruct(),s("design:type",Function),s("design:paramtypes",[]),s("design:returntype",void 0)],m.prototype,"initialize",null),m=a([l.injectable(),c(0,l.inject(d.ServiceIdentifiers.IRandomGenerator)),c(1,l.inject(d.ServiceIdentifiers.IOptions)),s("design:paramtypes",["function"==typeof(n=void 0!==f.IRandomGenerator&&f.IRandomGenerator)?n:Object,"function"==typeof(i=void 0!==u.IOptions&&u.IOptions)?i:Object])],m),t.MapStorage=m},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OptionsPreset=void 0;const o=r(27);t.OptionsPreset=o.MakeEnum({Default:"default",LowObfuscation:"low-obfuscation",MediumObfuscation:"medium-obfuscation",HighObfuscation:"high-obfuscation"})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeLiteralUtils=void 0;const o=r(4);t.NodeLiteralUtils=class{static isStringLiteralNode(e){return"string"==typeof e.value}static isProhibitedLiteralNode(e,t){return!(!o.NodeGuards.isPropertyNode(t)||t.computed||t.key!==e)||(!!o.NodeGuards.isImportDeclarationNode(t)||!(!o.NodeGuards.isExportAllDeclarationNode(t)&&!o.NodeGuards.isExportNamedDeclarationNode(t)))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";var o,n,i,a=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a},s=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},c=this&&this.__param||function(e,t){return function(r,o){t(r,o,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractCustomCodeHelperGroup=void 0;const l=r(0),d=r(1),u=r(6),f=r(2),p=r(3);let m=class{constructor(e,t,r){this.identifierNamesGenerator=e(r),this.randomGenerator=t,this.options=r}getAppendEvent(){return this.appendEvent}getCustomCodeHelpers(){return this.customCodeHelpers}appendCustomNodeIfExist(e,t){const r=this.customCodeHelpers.get(e);r&&t(r)}getRandomCallsGraphIndex(e){return this.randomGenerator.getRandomInteger(0,Math.max(0,Math.round(e-1)))}};m=a([l.injectable(),c(0,l.inject(d.ServiceIdentifiers.Factory__IIdentifierNamesGenerator)),c(1,l.inject(d.ServiceIdentifiers.IRandomGenerator)),c(2,l.inject(d.ServiceIdentifiers.IOptions)),s("design:paramtypes",["function"==typeof(o=void 0!==u.TIdentifierNamesGeneratorFactory&&u.TIdentifierNamesGeneratorFactory)?o:Object,"function"==typeof(n=void 0!==p.IRandomGenerator&&p.IRandomGenerator)?n:Object,"function"==typeof(i=void 0!==f.IOptions&&f.IOptions)?i:Object])],m),t.AbstractCustomCodeHelperGroup=m},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.alphabetStringUppercase=void 0;const o=r(33);t.alphabetStringUppercase=o.alphabetString.toUpperCase()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StringSeparator=void 0,function(e){e.Comma=",",e.Dot=".",e.VerticalLine="|"}(t.StringSeparator||(t.StringSeparator={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ObfuscatingGuardResult=void 0,function(e){e.ForceTransform="ForceTransform",e.Ignore="Ignore",e.Transform="Transform"}(t.ObfuscatingGuardResult||(t.ObfuscatingGuardResult={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IdentifierNamesGenerator=void 0;const o=r(27);t.IdentifierNamesGenerator=o.MakeEnum({DictionaryIdentifierNamesGenerator:"dictionary",HexadecimalIdentifierNamesGenerator:"hexadecimal",MangledIdentifierNamesGenerator:"mangled",MangledShuffledIdentifierNamesGenerator:"mangled-shuffled"})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SourceMapMode=void 0;const o=r(27);t.SourceMapMode=o.MakeEnum({Inline:"inline",Separate:"separate"})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PRESET=void 0;const o=r(43),n=r(25),i=r(35),a=r(44),s=r(17),c=r(29);t.DEFAULT_PRESET=Object.freeze({compact:!0,config:"",controlFlowFlattening:!1,controlFlowFlatteningThreshold:.75,deadCodeInjection:!1,deadCodeInjectionThreshold:.4,debugProtection:!1,debugProtectionInterval:!1,disableConsoleOutput:!1,domainLock:[],exclude:[],forceTransformStrings:[],identifierNamesGenerator:o.IdentifierNamesGenerator.HexadecimalIdentifierNamesGenerator,identifiersPrefix:"",identifiersDictionary:[],inputFileName:"",log:!1,numbersToExpressions:!1,optionsPreset:i.OptionsPreset.Default,renameGlobals:!1,renameProperties:!1,reservedNames:[],reservedStrings:[],rotateStringArray:!0,seed:0,selfDefending:!1,shuffleStringArray:!0,simplify:!0,sourceMap:!1,sourceMapBaseUrl:"",sourceMapFileName:"",sourceMapMode:a.SourceMapMode.Separate,splitStrings:!1,splitStringsChunkLength:10,stringArray:!0,stringArrayEncoding:[s.StringArrayEncoding.None],stringArrayWrappersChainedCalls:!0,stringArrayWrappersCount:1,stringArrayWrappersType:c.StringArrayWrappersType.Variable,stringArrayThreshold:.75,target:n.ObfuscationTarget.Browser,transformObjectKeys:!1,unicodeEscapeSequence:!1})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeType=void 0,function(e){e.ArrayExpression="ArrayExpression",e.ArrayPattern="ArrayPattern",e.ArrowFunctionExpression="ArrowFunctionExpression",e.AssignmentExpression="AssignmentExpression",e.AssignmentPattern="AssignmentPattern",e.AwaitExpression="AwaitExpression",e.BinaryExpression="BinaryExpression",e.BlockStatement="BlockStatement",e.BreakStatement="BreakStatement",e.CallExpression="CallExpression",e.CatchClause="CatchClause",e.ChainExpression="ChainExpression",e.ClassDeclaration="ClassDeclaration",e.ConditionalExpression="ConditionalExpression",e.ContinueStatement="ContinueStatement",e.ExportAllDeclaration="ExportAllDeclaration",e.ExportNamedDeclaration="ExportNamedDeclaration",e.ExpressionStatement="ExpressionStatement",e.ForStatement="ForStatement",e.ForInStatement="ForInStatement",e.ForOfStatement="ForOfStatement",e.FunctionDeclaration="FunctionDeclaration",e.FunctionExpression="FunctionExpression",e.Identifier="Identifier",e.IfStatement="IfStatement",e.ImportDeclaration="ImportDeclaration",e.ImportDefaultSpecifier="ImportDefaultSpecifier",e.ImportNamespaceSpecifier="ImportNamespaceSpecifier",e.ImportSpecifier="ImportSpecifier",e.LabeledStatement="LabeledStatement",e.Literal="Literal",e.LogicalExpression="LogicalExpression",e.MemberExpression="MemberExpression",e.MethodDefinition="MethodDefinition",e.ObjectExpression="ObjectExpression",e.ObjectPattern="ObjectPattern",e.Program="Program",e.Property="Property",e.RestElement="RestElement",e.ReturnStatement="ReturnStatement",e.SequenceExpression="SequenceExpression",e.Super="Super",e.SwitchCase="SwitchCase",e.SwitchStatement="SwitchStatement",e.TaggedTemplateExpression="TaggedTemplateExpression",e.TemplateElement="TemplateElement",e.TemplateLiteral="TemplateLiteral",e.ThrowStatement="ThrowStatement",e.TryStatement="TryStatement",e.UnaryExpression="UnaryExpression",e.UpdateExpression="UpdateExpression",e.VariableDeclaration="VariableDeclaration",e.VariableDeclarator="VariableDeclarator",e.WhileStatement="WhileStatement",e.YieldExpression="YieldExpression"}(t.NodeType||(t.NodeType={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.numbersString=void 0,t.numbersString="0123456789"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,r){"use strict";var o=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a};Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractCalleeDataExtractor=void 0;let n=class{};n=o([r(0).injectable()],n),t.AbstractCalleeDataExtractor=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ecmaVersion=void 0,t.ecmaVersion=11},function(e,t,r){"use strict";var o,n,i,a,s=this&&this.__decorate||function(e,t,r,o){var n,i=arguments.length,a=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,r):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,o);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(i<3?n(a):i>3?n(t,r,a):n(t,r))||a);return i>3&&a&&Object.defineProperty(t,r,a),a},c=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},l=this&&this.__param||function(e,t){return function(r,o){t(r,o,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractControlFlowReplacer=void 0;const d=r(0),u=r(1),f=r(23),p=r(2),m=r(3);let g=o=class{constructor(e,t,r){this.replacerDataByControlFlowStorageId=new Map,this.controlFlowCustomNodeFactory=e,this.randomGenerator=t,this.options=r}static getStorageKeysByIdForCurrentStorage(e,t){let r;return r=e.has(t)?e.get(t):new Map,r}insertCustomNodeToControlFlowStorage(e,t,r,n){const i=t.getStorageId(),a=o.getStorageKeysByIdForCurrentStorage(this.replacerDataByControlFlowStorageId,i),s=a.get(r);if(this.randomGenerator.getMathRandom()<n&&s&&s.length)return this.randomGenerator.getRandomGenerator().pickone(s);const c=e=>{const r=this.randomGenerator.getRandomString(e);return t.getStorage().has(r)?c(e):r},l=c(5);return a.set(r,[l]),this.replacerDataByControlFlowStorageId.set(i,a),t.set(l,e),l}};g=o=s([d.injectable(),l(0,d.inject(u.ServiceIdentifiers.Factory__IControlFlowCustomNode)),l(1,d.inject(u.ServiceIdentifiers.IRandomGenerator)),l(2,d.inject(u.ServiceIdentifiers.IOptions)),c("design:paramtypes",["function"==typeof(n=void 0!==f.TControlFlowCustomNodeFactory&&f.TControlFlowCustomNodeFactory)?n:Object,"fun