Complete rewrite of JS-Confuser using Babel! 🎉
Note
Check out the Migration guide on how to properly update from 1.X to 2.0. The obfuscation upgrades in 2.0 are worth the small refactoring.
-
Revamped API Interface
-
- JSConfuser.obfuscate() resolves to an object
Property | Type | Description |
---|---|---|
code |
string |
The obfuscated code. |
-
Renamed
Stack
toVariable Masking
-
Added configurable limits to options:
const options = {
target: "node",
rgf: {
value: 0.5, // = 50% of eligible functions
limit: 10 // Maximum of 10 changes for performance reasons
},
// Original format is still valid (No limit applied)
rgf: 0.5
}
2.0 Changes
-
Added Custom String Encoding and Custom Lock Code options
-
Added
Rename Labels
Learn more here -
Added
Pack
Learn more here -
RGF no longers uses
new Function
instead useseval
-
Improved code transforms!
-
Improved
Control Flow Flattening
-
- Obfuscates the Call Graph
-
- Now supports lexical bindings (
let
,const
,class
)
- Now supports lexical bindings (
-
with () { }
statement obfuscation
-
Improved
Minify
-
- Removes unused variables and functions
-
Improved
Moved Declaration
ability to move variables as unused function parameters -
Improved
String
transforms -
- Template literals are now obfuscated (First converted into equivalent String Literal)
-
- Regular expressions are now obfuscated (First converted into equivalent RegExp() constructor calls)
-
String Compression
now uses LZ-string compression (lz-string)
-
New Comment Syntax
-
/* @js-confuser-var */ "name"
for improved variable mappings, such as eval() calls
// Input
var name = "Internet User";
eval( "console.log(" + /* @js-confuser-var */ "name" + ")" );
// Output
var zC3PLKu = "Internet User";
eval("console.log(" + "zC3PLKu" + ")");
Note: The function __JS_CONFUSER_VAR__
is still supported.
JS-Confuser.com Revamp
A new UI for JS-Confuser.com, featuring an advanced playground and documentation pages.
The previous version will remain available at old--confuser.netlify.com.
Removed features
-
Removed
ES5
option - Use Babel Instead -
Removed
Browser Lock
andOS Lock
- Use Custom Locks instead -
Removed
Shuffle
's Hash option -
Removed
Indent
option