ben-sb / javascript-deobfuscator

General purpose JavaScript deobfuscator
https://deobfuscate.io
Apache License 2.0
795 stars 113 forks source link

Why this error occur ? #62

Open ibnrushud opened 17 hours ago

ibnrushud commented 17 hours ago

I used this library for first time but got this error : image

ibnrushud commented 17 hours ago

C:\Users\user\Downloads>js-deobfuscator -i i.js -o o.js C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1186 throw this.createError(ErrorMessages.INVALID_LHS_IN_ASSIGNMENT); ^

JsError: [1:34]: Invalid left-hand side in assignment at GenericParser.createError (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\tokenizer.js:275:12) at GenericParser.parseAssignmentExpressionOrTarget (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1186:20) at GenericParser.inheritCoverGrammar (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1087:21) at GenericParser.parseGroupExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1992:22) at GenericParser.parsePrimaryExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1782:19) at GenericParser.parseLeftHandSideExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1626:19) at GenericParser.parseUpdateExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1515:24) at GenericParser.parseUnaryExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1488:19) at GenericParser.parseExponentiationExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1459:21) at GenericParser.parseBinaryExpression (C:\Users\user\AppData\Roaming\npm\node_modules\js-deobfuscator\node_modules\shift-parser\src\parser.js:1409:21) { index: 33, line: 1, column: 34, parseErrorLine: 1, parseErrorColumn: 34, description: 'Invalid left-hand side in assignment' }

Node.js v22.9.0

C:\Users\user\Downloads>

ben-sb commented 10 hours ago

Looks like a syntax error or maybe newer syntax. Can you upload the sample you were trying to deobfuscate