From da91543f741c276c3569aedf1f488e2d410b3444 Mon Sep 17 00:00:00 2001 From: sanex3339 Date: Sun, 18 Dec 2016 18:11:25 +0300 Subject: [PATCH] fixed error when string array variable name and string array calls wrapper name was the same --- .../string-array-nodes/group/StringArrayCustomNodeGroup.ts | 2 +- .../node-obfuscators/replacers/StringLiteralReplacer.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/custom-nodes/string-array-nodes/group/StringArrayCustomNodeGroup.ts b/src/custom-nodes/string-array-nodes/group/StringArrayCustomNodeGroup.ts index f924d4e8..a00ddb3f 100644 --- a/src/custom-nodes/string-array-nodes/group/StringArrayCustomNodeGroup.ts +++ b/src/custom-nodes/string-array-nodes/group/StringArrayCustomNodeGroup.ts @@ -109,7 +109,7 @@ export class StringArrayCustomNodeGroup extends AbstractCustomNodeGroup { const reversedStorageId = Array.from(stringArrayStorageId).reverse().join(''); const stringArrayName: string = `_${Utils.hexadecimalPrefix}${stringArrayStorageId}`; - const stringArrayCallsWrapperName: string = `_${Utils.hexadecimalPrefix}${reversedStorageId}`; + const stringArrayCallsWrapperName: string = `_${Utils.hexadecimalPrefix}${reversedStorageId}a`; let stringArrayRotateValue: number; diff --git a/src/node-transformers/node-obfuscators/replacers/StringLiteralReplacer.ts b/src/node-transformers/node-obfuscators/replacers/StringLiteralReplacer.ts index 47e9cf36..4fc0029b 100644 --- a/src/node-transformers/node-obfuscators/replacers/StringLiteralReplacer.ts +++ b/src/node-transformers/node-obfuscators/replacers/StringLiteralReplacer.ts @@ -104,7 +104,7 @@ export class StringLiteralReplacer extends AbstractReplacer { } const reversedStringArrayId: string = Array.from(this.stringArrayStorage.getStorageId()).reverse().join(''); - const stringArrayStorageCallsWrapperName: string = `_${Utils.hexadecimalPrefix}${reversedStringArrayId}`; + const stringArrayStorageCallsWrapperName: string = `_${Utils.hexadecimalPrefix}${reversedStringArrayId}a`; const hexadecimalIndex: string = `${Utils.hexadecimalPrefix}${Utils.decToHex(indexOfValue)}`; if (this.options.stringArrayEncoding === StringArrayEncoding.rc4) {