mirror of
https://github.com/javascript-obfuscator/javascript-obfuscator
synced 2026-08-09 12:42:29 +00:00
literal number values to hex convert
This commit is contained in:
@@ -14,6 +14,10 @@ class NodeObfuscator {
|
||||
node.name = namesMap.get(node.name);
|
||||
}
|
||||
}
|
||||
replaceLiteralNumberByHexadecimalValue(nodeValue) {
|
||||
const prefix = '0x';
|
||||
return `${prefix}${Utils_1.Utils.decToHex(nodeValue)}`;
|
||||
}
|
||||
replaceLiteralStringByArrayElement(nodeValue) {
|
||||
let value = Utils_1.Utils.stringToUnicode(nodeValue), unicodeArray = this.nodes.get('unicodeArrayNode').getNodeData(), sameIndex = unicodeArray.indexOf(value), index;
|
||||
if (sameIndex < 0) {
|
||||
|
||||
Reference in New Issue
Block a user