How to decrypt lua char tonumber on Android

时间:2018-05-14 17:33:23

标签: encryption lua

So I have this script that I'd like to clean up and word things a bit differently but I can't read it and I don't know how to do it nor the tools I'd need. I don't have a PC so hopefully it can be done on Android. Thanks in advance.

function encrypt(key,code)
  return (code:gsub('..', function (h) 
return string.char((tonumber(h,16)+256-13 - key + 999999*256)%256) end))
end

pcall(encrypt(v_value[1],'BUNCHOFENENCRYPTEDCODE'))

1 个答案:

答案 0 :(得分:3)

这看起来像是对代码进行轻微混淆的典型尝试。逆向工程应该很容易。

pcall更改为print并重新运行该脚本。这将导致脚本解除混淆并将其自身转储到输出。然后,您可以获取输出并对其进行处理。