- New option:
deadCodeInjection
. With this option random blocks of dead code will add to the obfuscated code. - New option:
deadCodeInjectionThreshold
allows to set percentage of nodes that will affected bydeadCodeInjection
. - New option:
mangle
enables mangling of variable names. escapeUnicodeSequence
option now disabled by default.controlFlowFlattening
now affects string literal nodes.- increased runtime performance with
rc4
stringArrayEncoding
.
- Removed coverage dir from npm package
- Fixed javascript-obfuscator#37
- Breaking change: dropped
[email protected]
and[email protected]
support. - New option:
controlFlowFlattening
allows to enable/disable Control Flow flattening. Control flow flattening is a structure transformation of the source code that hinders program comprehension. - New option:
controlFlowFlatteningThreshold
allows to set percentage of nodes that will affected bycontrolFlowFlattening
. - Significantly increased obfuscation performance.
- Huge internal refactoring.
- Better
es2015
support: correct obfuscation ofTemplateLiteral
,ArrayPattern
,AssignmentPattern
nodes. - Switched from
npm
toyarn
internally. - Various bug fixes.
- Increased performance
- Fixed very rare
Cannot read property 'type' of undefined
error, whenRandomGeneratorUtils.getMathRandom()
returned incorrect value1
.
- Increased performance
- Breaking change: dropped
[email protected]
and[email protected]
support. - Switched from
npm
toyarn
internally.
- Transformers refactoring
- New option:
controlFlowFlattening
allows to enable/disable Control Flow flattening. Control flow flattening is a structure transformation of the source code that hinders program comprehension. - New option:
controlFlowFlatteningThreshold
allows to set percentage of nodes that will affected bycontrolFlowFlattening
. - Better
es2015
support: correct obfuscation ofTemplateLiteral
,ArrayPattern
,AssignmentPattern
nodes. - Obfuscation performance boost.
- Huge internal refactoring.
- Various bug fixes.
- additional fixes for javascript-obfuscator#29
- fixed javascript-obfuscator#29
selfDefending
option now disabled by default.
- New option
seed
sets seed for random generator. This is useful for creating repeatable results. - IE8 runtime error fix.
disableConsoleOutput
option now replacesconsole.xxx
functions on empty function instead of infinity loop.
- Breaking options change:
unicodeArray
option has been renamed tostringArray
. - Breaking options change:
unicodeArrayThreshold
option has been renamed tostringArrayThreshold
. - Breaking options change:
encodeUnicodeArray
option has been renamed tostringArrayEncoding
and now accepts following values:true|false|'base64'|'rc4'
. - Breaking change: option
wrapUnicodeArrayCalls
was removed and now all calls tostringArray
are always wrapped by special wrapper function. - New option
unicodeEscapeSequence
allows to enable/disable strings conversion to unicode escape sequence. - New option
domainLock
locks the obfuscated source code so it only runs on specific domains and/or sub-domains. - New option
sourceMapBaseUrl
sets base url to the source map import url whensourceMapMode: 'separate'
. - Custom nodes like
selfDefendingNode
orconsoleOutputNode
now inserted into deepest stack trace function call. - Fixed obfuscation of global variables and function names in some cases.
- Fixed wrong obfuscation of labels.
- Rewrite of many custom nodes.
- CLI missing polyfill fix #17
- IE error fix #14
- Obfuscator now returns an empty string instead of obfuscated code if source code is empty
- Fix of incorrect
Utils.decToHex
method
- Breaking API change: now
obfuscate(sourceCode, options)
returnsObfuscationResult
object insteadstring
.ObfuscationResult
object contains two public methods:getObfuscatedCode()
andgetSourceMap()
. - CLI. Now any code can be obfuscated through CLI
javascript-obfuscator
command. SeeREADME.md
for available options. - New option
sourceMap
enables source map generation for obfuscated code. - New option
sourceMapMode
specifies source map generation mode.