j4k0xb / webcrack

Deobfuscate obfuscator.io, unminify and unpack bundled javascript
https://webcrack.netlify.app
MIT License
1.07k stars 129 forks source link

Error when deobfuscating some files #105

Open nicepot opened 3 months ago

nicepot commented 3 months ago

Describe the bug

Error: Unexpected constant violation (VariableDeclarator): [c,l]

Expected Behaviour

Deobfuscated

Code

https://hastebin.skyra.pw/nokiremeze.wren

Logs

editorWorkerService.js:455 Uncaught (in promise) TypeError: i.findSectionHeaders is not a function
    at editorWorkerService.js:455:26
DeobfuscateContext.tsx:66 Error: Unexpected constant violation (VariableDeclarator): [c,l]
    at webcrack.worker-B-cQ_jqz.js:67:207813
    at Array.forEach (<anonymous>)
    at Pi (webcrack.worker-B-cQ_jqz.js:67:207269)
    at Object.exit (webcrack.worker-B-cQ_jqz.js:72:10939)
    at Object.n (webcrack.worker-B-cQ_jqz.js:15:164609)
    at Ch.i [as _call] (webcrack.worker-B-cQ_jqz.js:67:17749)
    at Ch.r [as call] (webcrack.worker-B-cQ_jqz.js:67:17587)
    at Ch.s [as visit] (webcrack.worker-B-cQ_jqz.js:67:18761)
    at i.visitQueue (webcrack.worker-B-cQ_jqz.js:67:42931)
    at i.visitMultiple (webcrack.worker-B-cQ_jqz.js:67:42544)
worker.onmessage @ DeobfuscateContext.tsx:66
blob:https://webcrack.netlify.app/fa76df58-bbf3-4c87-8cf6-b3b55aeb48a7:1 Not allowed to load local resource: blob:https://webcrack.netlify.app/fa76df58-bbf3-4c87-8cf6-b3b55aeb48a7
j4k0xb commented 3 months ago

gonna look into it but the deobfuscation works fine, it only errors when mangle is active

edit: it also has some weird code like this

var n = __DECODE_0__;
var n = config[e(764) + n(1192)][a];
if (n[e(1249)]) {

that is incorrectly deobfuscated into:

var n = config.ReactionRoles[a];
if (__DECODE_0__.useButtons) {