BobA
February 21, 2022, 8:29pm
1
I added
"identifier-names-generator":"mangled",
to my obfuscator settings, but my function names are not being mangled at all. Is there a different way to do this? For example, I have selected js-obfuscator-low and have the following under obfuscatorSettings:
{
"compact": true,
"controlFlowFlattening": false,
"controlFlowFlatteningThreshold": 0.75,
"debugProtection": false,
"debugProtectionInterval": false,
"disableConsoleOutput": false,
"identifier-names-generator":"mangled",
"reservedNames": [],
"rotateStringArray": true,
"seed": 0,
"selfDefending": false,
"sourceMap": false,
"sourceMapBaseUrl": "",
"sourceMapFileName": "",
"sourceMapMode": "separate",
"stringArray": true,
"stringArrayEncoding": false,
"stringArrayThreshold": 0.8,
"unicodeEscapeSequence": true
}
Regards,
Bob
ghenne
February 22, 2022, 2:05pm
2
If you want to override the js-obfuscator-low
settings with your own settings, set obfuscation to js-obfuscator-custom
. Put your new set of parameters into obfuscatorSettings .
BobA
February 22, 2022, 3:03pm
3
Thanks. I did try that, along with all of the other settings, and the function names were never mangled.
Am I using the wrong choice?
Bob
ghenne
February 22, 2022, 6:33pm
4
I don’t claim to know everything about this library. The documentation for the library isn’t much help here.
I tried pasting some code into this online tool which uses the same library. It didn’t mangle my function names either.
You may need to do some more digging and experimentation.
BobA
February 22, 2022, 11:03pm
5
Perfect! Thanks!
It’s always good to get confirmation that it isn’t just me
Regards,
Bob