[ @_insidious ]
---
Then you can change it with another ID from both location I mentioned earlier (or app generated ID on memory): Concept. You can use the code above as templates, don't be lazy.
---
Since I don't have multiple device, I can only test it on Emulator with multiple instances. Here's the working one, choose between Google Play & Google Play Services:
function is_unique(headers, init, ends, pattern)
unique = false
gg.searchNumber(headers, gg.TYPE_BYTE, false, gg.SIGN_EQUAL, 0, -1, 0)
result_count = gg.getResultsCount()
bases = gg.getResults(result_count)
for _ = 1, result_count do
raw_init = const(bases[_].address, init)
raw_end = const(bases[_].address, ends)
deciph = hexdecode(raw_end:gsub(raw_init, ""))
if deciph:match(pattern) then
unique = deciph
break
end
end
return unique
end
function const(addr, buffer)
construct = ""
current = {}
for _ = 1, buffer do
current[_] = {address = (addr - 1) + _, flags = gg.TYPE_BYTE}
end
for k, v in ipairs(gg.getValues(current)) do
construct = construct .. string.format("%02X", v.value & 0xFF)
end
return construct
end
function hexdecode(hex)
return (hex:gsub("%x%x", function(digits) return string.char(tonumber(digits, 16)) end))
end
app = gg.getTargetInfo().packageName
if app == "com.android.vending" then --Google Play Store
--[shared_pref] finsky.xml
print("Ads Unique ID:", is_unique("h 61 64 69 64 2D 63 61 63 68 65 64 2D 76 61 6C 75 65", 64, 99, "^[a-zA-Z0-9-]*$"))
elseif app == "com.google.android.gms" then --Google Play Services
--[database] google_app_measurement.db
print("Instance ID:", is_unique("h 63 6F 6D 2E 67 6F 6F 67 6C 65 2E 61 6E 64 72 6F 69 64 2E 70 6C 61 79 2E 67 61 6D 65 73", 29, 61, "^[a-z0-9]*$"))
end
---
I'm expecting some effort on your part and not just "this don't work, meh". Atleast ask me what parts that you don't understand.