fbpx

首页 » Lua » 正文

微信62数据读取源码

function to_hex(data)
local t = {};
for i = 1, string.len(data),1 do
local code = tonumber(string.byte(data, i, i));
table.insert(t, string.format(“%02x”, code));
end
return table.concat(t, “”);
end

function readsix2()
local bid = ‘com.tencent.xin’
if appDataPath(bid) == ” then
return false
end
if not file_exists(appDataPath(bid) .. ‘/Library/WechatPrivate/wx.dat’) then
return false
end
local ret = io.open(appDataPath(bid) .. ‘/Library/WechatPrivate/wx.dat’, ‘rb’)
if not ret then
return ”
end
local six2 = to_hex(ret:read(‘*a’))
ret:close()
return six2
end

发表评论

Captcha Code