|
|
@@ -1,41 +1,7 @@
|
|
|
-const mcc = '{{mcc}}'
|
|
|
-const mnc = '{{mnc}}'
|
|
|
-const simOperator = '{{simOperator}}'
|
|
|
-const networkOperator = '{{networkOperator}}'
|
|
|
-const simSerialNumber = '{{simSerialNumber}}'
|
|
|
-const iccId = '{{iccId}}'
|
|
|
-const number = '{{number}}'
|
|
|
-const imei = '{{imei}}'
|
|
|
-const imsi = '{{imsi}}'
|
|
|
-const countryIso = '{{countryIso}}'
|
|
|
-const subId = '{{subId}}'
|
|
|
-const androidId = '{{androidId}}'
|
|
|
-const serialNumber = '{{serialNumber}}'
|
|
|
-
|
|
|
function trace(tag) {
|
|
|
Log.e((tag || '') + Java.use('android.util.Log').getStackTraceString(Java.use('java.lang.Throwable').$new()))
|
|
|
}
|
|
|
|
|
|
-function dump(obj) {
|
|
|
- try {
|
|
|
- const gson = Java.use('com.google.gson.Gson').$new()
|
|
|
- const json = gson.toJson(obj)
|
|
|
- return json
|
|
|
- } catch (error) {
|
|
|
- return ''
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-function dumpJson(obj) {
|
|
|
- try {
|
|
|
- const gson = Java.use('com.google.gson.Gson').$new()
|
|
|
- const json = gson.toJson(obj)
|
|
|
- return JSON.parse(json)
|
|
|
- } catch (error) {
|
|
|
- return ''
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
class Log {
|
|
|
static TAG = '[GMS]'
|
|
|
static Debug = false
|
|
|
@@ -67,311 +33,6 @@ class Log {
|
|
|
}
|
|
|
|
|
|
Java.perform(function () {
|
|
|
- try {
|
|
|
- const GsonClass = Java.openClassFile('/sdcard/Android/data/com.google.android.gms/gson.dex')
|
|
|
- GsonClass.load()
|
|
|
- Log.s('gson class loaded')
|
|
|
- } catch (error) {
|
|
|
- Log.e('load gson error', error)
|
|
|
- }
|
|
|
-
|
|
|
- const SmsManager = Java.use('android.telephony.SmsManager')
|
|
|
- SmsManager.getSmsManagerForSubscriptionId.overload('int').implementation = function (i) {
|
|
|
- const _smsManager = this.getSmsManagerForSubscriptionId(i)
|
|
|
- Log.i(`SmsManager.getSmsManagerForSubscriptionId: ${i}`)
|
|
|
- return _smsManager
|
|
|
- }
|
|
|
-
|
|
|
- SmsManager.getDefault.overload().implementation = function () {
|
|
|
- const _smsManager = this.getDefault(i)
|
|
|
- Log.i(`SmsManager.getDefault`)
|
|
|
- return _smsManager
|
|
|
- }
|
|
|
-
|
|
|
- // SmsManager.getDefaultSmsSubscriptionId.overload().implementation =
|
|
|
- // function () {
|
|
|
- // const _subId = this.getDefaultSmsSubscriptionId()
|
|
|
- // Log.i(
|
|
|
- // `spoof SmsManager.getDefaultSmsSubscriptionId: ${_subId} -> ${subId}`
|
|
|
- // )
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
-
|
|
|
- // SmsManager.getSubscriptionId.overload().implementation = function () {
|
|
|
- // const _subId = this.getSubscriptionId()
|
|
|
- // Log.i(`SmsManager.getSubscriptionId: ${_subId} -> ${subId}`)
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
- SmsManager.getCarrierConfigValues.overload().implementation = function () {
|
|
|
- const _config = this.getCarrierConfigValues()
|
|
|
- Log.i(`SmsManager.getCarrierConfigValues: ${_config}`)
|
|
|
- return _config
|
|
|
- }
|
|
|
-
|
|
|
- const CarrierConfigManager = Java.use('android.telephony.CarrierConfigManager')
|
|
|
- CarrierConfigManager.getConfigForSubId.overload('int').implementation = function (i) {
|
|
|
- const _config = this.getConfigForSubId(i)
|
|
|
- Log.i(`CarrierConfigManager.getConfigForSubId: ${i}`)
|
|
|
- return _config
|
|
|
- }
|
|
|
-
|
|
|
- const SubscriptionManager = Java.use('android.telephony.SubscriptionManager')
|
|
|
- SubscriptionManager.getActiveSubscriptionInfoCount.overload().implementation = function () {
|
|
|
- const _count = this.getActiveSubscriptionInfoCount()
|
|
|
- Log.i(`SubscriptionManager.getActiveSubscriptionInfoCount: ${_count}`)
|
|
|
- return _count
|
|
|
- }
|
|
|
- // SubscriptionManager.getDefaultSubscriptionId.overload().implementation =
|
|
|
- // function () {
|
|
|
- // const _subId = this.getDefaultSubscriptionId()
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.getDefaultSubscriptionId: ${_subId} -> ${subId}`
|
|
|
- // )
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
- // SubscriptionManager.getDefaultSmsSubscriptionId.overload().implementation =
|
|
|
- // function () {
|
|
|
- // const _subId = this.getDefaultSmsSubscriptionId()
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.getDefaultSmsSubscriptionId: ${_subId} -> ${subId}`
|
|
|
- // )
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
- // SubscriptionManager.getDefaultVoiceSubscriptionId.overload().implementation =
|
|
|
- // function () {
|
|
|
- // const _subId = this.getDefaultVoiceSubscriptionId()
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.getDefaultVoiceSubscriptionId: ${_subId} -> ${subId}`
|
|
|
- // )
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
- // SubscriptionManager.getActiveDataSubscriptionId.overload().implementation =
|
|
|
- // function () {
|
|
|
- // const _subId = this.getActiveDataSubscriptionId()
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.getActiveDataSubscriptionId: ${_subId} -> ${subId}`
|
|
|
- // )
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
- // SubscriptionManager.getSlotIndex.overload("int").implementation = function (
|
|
|
- // i
|
|
|
- // ) {
|
|
|
- // const _slotIndex = this.getSlotIndex(i)
|
|
|
- // Log.i(`spoof SubscriptionManager.getSlotIndex: ${_slotIndex} -> 0`)
|
|
|
- // return 0
|
|
|
- // }
|
|
|
- // SubscriptionManager.isUsableSubscriptionId.overload("int").implementation =
|
|
|
- // function (i) {
|
|
|
- // const _isUsable = this.isUsableSubscriptionId(i)
|
|
|
- // Log.i(`SubscriptionManager.isUsableSubscriptionId: ${_isUsable}`)
|
|
|
- // return _isUsable
|
|
|
- // }
|
|
|
- // SubscriptionManager.isValidSubscriptionId.overload("int").implementation =
|
|
|
- // function (i) {
|
|
|
- // const _isValid = this.isValidSubscriptionId(i)
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.isValidSubscriptionId(${i}): ${_isValid} -> true`
|
|
|
- // )
|
|
|
- // return true
|
|
|
- // }
|
|
|
- SubscriptionManager.getPhoneNumber.overload('int').implementation = function (i) {
|
|
|
- Log.i(`spoof SubscriptionManager.getPhoneNumber(${i}): -> ${number}`)
|
|
|
- return number
|
|
|
- }
|
|
|
- SubscriptionManager.getPhoneNumber.overload('int', 'int').implementation = function (i, i2) {
|
|
|
- Log.i(`spoof SubscriptionManager.getPhoneNumber(${i},${i2}): -> ${number}`)
|
|
|
- return number
|
|
|
- }
|
|
|
- SubscriptionManager.getActiveSubscriptionInfoList.overload().implementation = function () {
|
|
|
- const _list = this.getActiveSubscriptionInfoList()
|
|
|
- Log.i(`SubscriptionManager.getActiveSubscriptionInfoList ${_list.size()}`)
|
|
|
- return _list
|
|
|
- }
|
|
|
- // SubscriptionManager.getActiveSubscriptionInfoForSimSlotIndex.overload(
|
|
|
- // "int"
|
|
|
- // ).implementation = function (i) {
|
|
|
- // const _info = this.getActiveSubscriptionInfoForSimSlotIndex(i)
|
|
|
- // Log.i(
|
|
|
- // `SubscriptionManager.getActiveSubscriptionInfoForSimSlotIndex(${i}): ${
|
|
|
- // _info ? "ok" : "null"
|
|
|
- // }`
|
|
|
- // )
|
|
|
- // return _info
|
|
|
- // }
|
|
|
- // SubscriptionManager.getActiveSubscriptionIdList.overload().implementation =
|
|
|
- // function () {
|
|
|
- // const _list = this.getActiveSubscriptionIdList()
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.getActiveSubscriptionIdList ${_list} -> ${subId}`
|
|
|
- // )
|
|
|
- // return [parseInt(subId)]
|
|
|
- // }
|
|
|
- // SubscriptionManager.getActiveSubscriptionInfo.overload(
|
|
|
- // "int"
|
|
|
- // ).implementation = function (i) {
|
|
|
- // const _info = this.getActiveSubscriptionInfo(i)
|
|
|
-
|
|
|
- // const simCount = this.getActiveSubscriptionInfoCountMax()
|
|
|
-
|
|
|
- // let subInfo = null
|
|
|
- // try {
|
|
|
- // for (let i = 0; i < simCount; i++) {
|
|
|
- // subInfo = this.getActiveSubscriptionInfoForSimSlotIndex(i)
|
|
|
- // if (subInfo) {
|
|
|
- // break
|
|
|
- // }
|
|
|
- // }
|
|
|
- // Log.i(`spoof SubscriptionManager.getActiveSubscriptionInfo(${i})`)
|
|
|
- // } catch (error) {
|
|
|
- // console.error(
|
|
|
- // `spoof error SubscriptionManager.getActiveSubscriptionInfo(${i})`
|
|
|
- // )
|
|
|
- // error.printStackTrace()
|
|
|
- // }
|
|
|
- // return subInfo
|
|
|
- // }
|
|
|
- // SubscriptionManager.getActiveSubscriptionInfoForSimSlotIndex.overload(
|
|
|
- // "int"
|
|
|
- // ).implementation = function (i) {
|
|
|
- // const _info = this.getActiveSubscriptionInfoForSimSlotIndex(i)
|
|
|
- // Log.i(
|
|
|
- // `SubscriptionManager.getActiveSubscriptionInfoForSimSlotIndex: ${_info}`
|
|
|
- // )
|
|
|
- // return _info
|
|
|
- // }
|
|
|
- // SubscriptionManager.isActiveSubscriptionId.overload("int").implementation =
|
|
|
- // function (i) {
|
|
|
- // const _isActive = this.isActiveSubscriptionId(i)
|
|
|
- // Log.i(
|
|
|
- // `spoof SubscriptionManager.isActiveSubscriptionId(${i}): ${_isActive} -> true`
|
|
|
- // )
|
|
|
- // return true
|
|
|
- // }
|
|
|
-
|
|
|
- const SubscriptionInfo = Java.use('android.telephony.SubscriptionInfo')
|
|
|
- SubscriptionInfo.getMcc.overload().implementation = function () {
|
|
|
- const _mcc = this.getMcc()
|
|
|
- Log.i(`spoof SubscriptionInfo.getMcc: ${_mcc} -> ${mcc}`)
|
|
|
- return parseInt(mcc)
|
|
|
- }
|
|
|
-
|
|
|
- SubscriptionInfo.getMnc.overload().implementation = function () {
|
|
|
- const _mnc = this.getMnc()
|
|
|
- Log.i(`spoof SubscriptionInfo.getMnc: ${_mnc} -> ${mnc}`)
|
|
|
- return parseInt(mnc)
|
|
|
- }
|
|
|
-
|
|
|
- SubscriptionInfo.getMccString.overload().implementation = function () {
|
|
|
- const _mccString = this.getMccString()
|
|
|
- Log.i(`spoof SubscriptionInfo.getMccString: ${_mccString} -> ${mcc}`)
|
|
|
- return mcc
|
|
|
- }
|
|
|
-
|
|
|
- SubscriptionInfo.getMncString.overload().implementation = function () {
|
|
|
- const _mncString = this.getMncString()
|
|
|
- Log.i(`spoof SubscriptionInfo.getMncString: ${_mncString} -> ${mnc}`)
|
|
|
- return mnc
|
|
|
- }
|
|
|
-
|
|
|
- SubscriptionInfo.getNumber.overload().implementation = function () {
|
|
|
- const _number = this.getNumber()
|
|
|
- Log.i(`spoof SubscriptionInfo.getNumber: ${_number} -> ${number}`)
|
|
|
- return number
|
|
|
- }
|
|
|
-
|
|
|
- SubscriptionInfo.getIccId.overload().implementation = function () {
|
|
|
- const _iccId = this.getIccId()
|
|
|
- Log.i(`spoof SubscriptionInfo.getIccId: ${_iccId} -> ${iccId}`)
|
|
|
- return iccId
|
|
|
- }
|
|
|
-
|
|
|
- SubscriptionInfo.getCountryIso.overload().implementation = function () {
|
|
|
- const _countryIso = this.getCountryIso()
|
|
|
- Log.i(`spoof SubscriptionInfo.getCountryIso: ${_countryIso} -> ${countryIso}`)
|
|
|
- return countryIso
|
|
|
- }
|
|
|
-
|
|
|
- // SubscriptionInfo.getSubscriptionId.overload().implementation = function () {
|
|
|
- // const _subId = this.getSubscriptionId()
|
|
|
- // if (!subId) {
|
|
|
- // Log.i(_subId)
|
|
|
- // return _subId
|
|
|
- // }
|
|
|
- // Log.i(`spoof SubscriptionInfo.getSubscriptionId: ${_subId} -> ${subId}`)
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
-
|
|
|
- const TelephonyManager = Java.use('android.telephony.TelephonyManager')
|
|
|
- // TelephonyManager.createForSubscriptionId.overload("int").implementation =
|
|
|
- // function (i) {
|
|
|
- // Log.i(`spoof TelephonyManager.createForSubscriptionId: ${i}`)
|
|
|
- // return this
|
|
|
- // }
|
|
|
-
|
|
|
- TelephonyManager.getLine1Number.overload().implementation = function () {
|
|
|
- const _number = this.getLine1Number()
|
|
|
- Log.i(`spoof TelephonyManager.getLine1Number: ${_number} -> ${number}`)
|
|
|
- return number
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getSimOperator.overload().implementation = function () {
|
|
|
- const _simOperator = this.getSimOperator()
|
|
|
- Log.i(`spoof TelephonyManager.getSimOperator: ${_simOperator} -> ${simOperator}`)
|
|
|
- return simOperator
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getNetworkOperator.overload().implementation = function () {
|
|
|
- const _networkOperator = this.getNetworkOperator()
|
|
|
- Log.i(`spoof TelephonyManager.getNetworkOperator: ${_networkOperator} -> ${networkOperator}`)
|
|
|
- return networkOperator
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getSimSerialNumber.overload().implementation = function () {
|
|
|
- const _simSerialNumber = this.getSimSerialNumber()
|
|
|
- Log.i(`spoof TelephonyManager.getSimSerialNumber: ${_simSerialNumber} -> ${simSerialNumber}`)
|
|
|
- return simSerialNumber
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getSubscriberId.overload().implementation = function () {
|
|
|
- const _imsi = this.getSubscriberId()
|
|
|
- Log.i(`spoof TelephonyManager.getSubscriberId: ${_imsi} -> ${imsi}`)
|
|
|
- return imsi
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getImei.overload().implementation = function () {
|
|
|
- const _imei = this.getImei()
|
|
|
- Log.i(`spoof TelephonyManager.getImei: ${_imei} -> ${imei}`)
|
|
|
- return imei
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getNetworkCountryIso.overload().implementation = function () {
|
|
|
- const _countryIso = this.getNetworkCountryIso()
|
|
|
- Log.i(`spoof TelephonyManager.getNetworkCountryIso: ${_countryIso} -> ${countryIso}`)
|
|
|
- return countryIso
|
|
|
- }
|
|
|
-
|
|
|
- TelephonyManager.getSimCountryIso.overload().implementation = function () {
|
|
|
- const _countryIso = this.getSimCountryIso()
|
|
|
- Log.i(`spoof TelephonyManager.getSimCountryIso: ${_countryIso} -> ${countryIso}`)
|
|
|
- return countryIso
|
|
|
- }
|
|
|
-
|
|
|
- // TelephonyManager.getSubscriptionId.overload().implementation = function () {
|
|
|
- // const _subId = this.getSubscriptionId()
|
|
|
- // if (!subId) {
|
|
|
- // Log.i(_subId)
|
|
|
- // return _subId
|
|
|
- // }
|
|
|
- // Log.i(`spoof TelephonyManager.getSubscriptionId: ${_subId} -> ${subId}`)
|
|
|
- // return parseInt(subId)
|
|
|
- // }
|
|
|
-
|
|
|
- TelephonyManager.getSimState.overload().implementation = function () {
|
|
|
- const _simState = this.getSimState()
|
|
|
- Log.i(`spoof TelephonyManager.getSimState: ${_simState} -> 5`)
|
|
|
- return 5
|
|
|
- }
|
|
|
-
|
|
|
const PhoneNumberVerification = Java.use('com.google.android.gms.constellation.PhoneNumberVerification')
|
|
|
PhoneNumberVerification.$init.overload(
|
|
|
'java.lang.String',
|
|
|
@@ -409,6 +70,7 @@ Java.perform(function () {
|
|
|
).implementation = function (str, j, idTokenRequest, bundle, list, z, i, list2) {
|
|
|
Log.e(`VerifyPhoneNumberRequest.$init(
|
|
|
str=${str}, j=${j}, idTokenRequest=${idTokenRequest}, bundle=${bundle}, list=${list}, z=${z}, i=${i}, list2=${list2})`)
|
|
|
+ trace()
|
|
|
// print bundle
|
|
|
const keySet = bundle.keySet().toArray()
|
|
|
for (let i = 0; i < keySet.length; i++) {
|
|
|
@@ -483,403 +145,9 @@ Java.perform(function () {
|
|
|
return this.$init(i, str, str2)
|
|
|
}
|
|
|
|
|
|
- try {
|
|
|
- const amac = Java.use('amac')
|
|
|
- const amlo = Java.use('amlo')
|
|
|
- const emiy = Java.use('emiy')
|
|
|
- const emiz = Java.use('emiz')
|
|
|
- const emis = Java.use('emis')
|
|
|
- const fiwu = Java.use('fiwu')
|
|
|
- const ambs = Java.use('ambs')
|
|
|
- const emkm = Java.use('emkm')
|
|
|
- const fivh = Java.use('fivh')
|
|
|
- const fivk = Java.use('fivk')
|
|
|
- const fivn = Java.use('fivn')
|
|
|
- const emjr = Java.use('emjr')
|
|
|
- const amag = Java.use('amag')
|
|
|
- const ftha = Java.use('ftha')
|
|
|
- const ftgy = Java.use('ftgy')
|
|
|
- const fuem = Java.use('fuem')
|
|
|
- const fiwt = Java.use('fiwt')
|
|
|
- const TimeUnit = Java.use('java.util.concurrent.TimeUnit')
|
|
|
- const ambi = Java.use('ambi')
|
|
|
- const fivj = Java.use('fivj')
|
|
|
- amac.o.overload('amlu', 'boolean', 'boolean', 'fiwt').implementation = function (amluVar, z, z2, fiwtVar) {
|
|
|
- Log.e(` amac.o(amluVar=${dump(amluVar)}, z=${z}, z2=${z2}, fiwtVar=${dump(fiwtVar)})`)
|
|
|
- try {
|
|
|
- var z3
|
|
|
- var z4
|
|
|
- const eq = fiwtVar.eQ()
|
|
|
- const arr0 = Java.array('java.lang.Object', [this.z(eq)])
|
|
|
- this._a.value.d('SetConsentRequest: %s', arr0)
|
|
|
-
|
|
|
- var amloVar = this._d.value
|
|
|
- var emiyVar = Java.cast(emiz.h.value.eV(), emiy)
|
|
|
-
|
|
|
- if (!emiyVar._b.value.fm()) {
|
|
|
- emiyVar.O()
|
|
|
- }
|
|
|
- var emizVar = Java.cast(emiyVar._b.value, emiz)
|
|
|
- emizVar.b = emkm.a(10)
|
|
|
- Log.i(emizVar, emizVar.b, emizVar.a)
|
|
|
-
|
|
|
- emizVar.a = emizVar.a | 1
|
|
|
- var eV = emis.d.value.eV()
|
|
|
-
|
|
|
- if ((fiwtVar.a.value & 2) != 0) {
|
|
|
- var fivnVar = fiwtVar.e.value
|
|
|
- if (fivnVar == null) {
|
|
|
- fivnVar = fivn.c.value
|
|
|
- }
|
|
|
- var b = fivh.b(fivnVar.a.value)
|
|
|
- if (b == 0) {
|
|
|
- z3 = false
|
|
|
- } else if (b == 3) {
|
|
|
- z3 = true
|
|
|
- } else {
|
|
|
- z3 = false
|
|
|
- }
|
|
|
- if (!eV._b.value.fm()) {
|
|
|
- eV.O()
|
|
|
- }
|
|
|
- var fbzbVar = eV._b.value
|
|
|
- var emisVar = Java.cast(fbzbVar, emis)
|
|
|
- emisVar.a |= 1
|
|
|
- emisVar.b = z3
|
|
|
- var fivnVar2 = fiwtVar.e.value
|
|
|
- if (fivnVar2 == null) {
|
|
|
- fivnVar2 = fivn.c.value
|
|
|
- }
|
|
|
- var a2 = fivk.a(fivnVar2.b.value)
|
|
|
- if (a2 == 0) {
|
|
|
- z4 = false
|
|
|
- } else if (a2 == 3) {
|
|
|
- z4 = true
|
|
|
- } else {
|
|
|
- z4 = false
|
|
|
- }
|
|
|
- if (!fbzbVar.fm()) {
|
|
|
- eV.O()
|
|
|
- }
|
|
|
- var emisVar2 = Java.cast(eV._b.value, emis)
|
|
|
- emisVar2.a |= 2
|
|
|
- emisVar2.c = z4
|
|
|
- }
|
|
|
- if (!emiyVar._b.value.fm()) {
|
|
|
- emiyVar.O()
|
|
|
- }
|
|
|
- var emizVar2 = Java.cast(emiyVar._b.value, emiz)
|
|
|
- var emisVar3 = Java.cast(eV.K(), emis)
|
|
|
- emisVar3.getClass()
|
|
|
- emizVar2.c = emisVar3
|
|
|
- emizVar2.a |= 2
|
|
|
- amloVar.A(amluVar, emjr.b(5), Java.cast(emiyVar.K(), emiz))
|
|
|
-
|
|
|
- var v = this.v()
|
|
|
- var akxiVar = this._c.value
|
|
|
- var j = this._e.value
|
|
|
- if (amag._a.value == null) {
|
|
|
- amag._a.value = ftha.b(
|
|
|
- ftgy._a.value,
|
|
|
- 'google.internal.communications.phonedeviceverification.v1.PhoneDeviceVerification/SetConsent',
|
|
|
- fuem.a(fiwt.k.value),
|
|
|
- fuem.a(fiwu.a.value)
|
|
|
- )
|
|
|
- }
|
|
|
- // const vdg = v.d.value.g(
|
|
|
- // amag._a.value,
|
|
|
- // akxiVar,
|
|
|
- // fiwtVar,
|
|
|
- // Java.use('java.lang.Long').valueOf(j).longValue(),
|
|
|
- // TimeUnit.MILLISECONDS.value,
|
|
|
- // v.e.value
|
|
|
- // )
|
|
|
- // Log.i("aaaaa")
|
|
|
- // const eqres = Java.cast(vdg, fiwu).eQ()
|
|
|
- // Log.i("bbbbb")
|
|
|
- // const res = this.z(eqres)
|
|
|
- // Log.i("SetConsentResponse: ", res)
|
|
|
- // const arr = Java.array("java.lang.Object", [res])
|
|
|
- // this._a.value.d("SetConsentResponse: %s", arr)
|
|
|
- var amloVar2 = this._d.value
|
|
|
- var emiyVar2 = Java.cast(emiz.h.value.eV(), emiy)
|
|
|
- if (!emiyVar2._b.value.fm()) {
|
|
|
- emiyVar2.O()
|
|
|
- }
|
|
|
- var emizVar3 = Java.cast(emiyVar2._b.value, emiz)
|
|
|
-
|
|
|
- emizVar3.b = emkm.a(10)
|
|
|
- emizVar3.a |= 1
|
|
|
- amloVar2.A(amluVar, emjr.b(6), Java.cast(emiyVar2.K(), emiz))
|
|
|
- var a3 = ambi.b().a(this._b.value.getApplicationContext())
|
|
|
- a3.n(z)
|
|
|
- a3.m(Java.use('java.lang.Boolean').valueOf(z2))
|
|
|
- var b2 = fivj.b(fiwtVar.g.value)
|
|
|
- if (b2 == 0) {
|
|
|
- b2 = 1
|
|
|
- }
|
|
|
- var a4 = fivj.a(b2)
|
|
|
- var edit = Java.cast(a3, ambs)._c.value.edit()
|
|
|
- edit.putInt('device_consent_version', a4)
|
|
|
- edit.apply()
|
|
|
- Log.i('oooooooooo')
|
|
|
- } catch (e) {
|
|
|
- Log.i('2222222', e)
|
|
|
- trace()
|
|
|
- }
|
|
|
- // this.o(amluVar, z, z2, fiwtVar)
|
|
|
- }
|
|
|
- } catch (error) {}
|
|
|
-
|
|
|
- const alyx = Java.use('alyx')
|
|
|
- alyx.a.overload('fixf').implementation = function (fixf) {
|
|
|
- const b = this.a(fixf)
|
|
|
- const keySet = b.keySet().toArray()
|
|
|
- for (let i = 0; i < keySet.length; i++) {
|
|
|
- const key = keySet[i]
|
|
|
- Log.w(`alyx.a::key: ${key}, value: ${b.get(key)}`)
|
|
|
- }
|
|
|
- return b
|
|
|
- }
|
|
|
- alyx.m.overload('amlu', 'java.util.List').implementation = function (amlu, list) {
|
|
|
- const a = amlu._a.value // string
|
|
|
- const f = amlu.f.value // string
|
|
|
- const g = amlu.g.value // list
|
|
|
- const h = amlu.h.value // list
|
|
|
- const HashMap = Java.use('java.util.HashMap')
|
|
|
- const d = Java.cast(amlu.d.value, HashMap) // map
|
|
|
- const e = Java.cast(amlu.e.value, HashMap) // map
|
|
|
-
|
|
|
- Log.e(
|
|
|
- `alyx.m(${JSON.stringify({
|
|
|
- a,
|
|
|
- f,
|
|
|
- g: g ? JSON.parse(dump(g)) : null,
|
|
|
- h: h ? JSON.parse(dump(h)) : null,
|
|
|
- d: d ? JSON.parse(dump(d)) : null,
|
|
|
- e: e ? JSON.parse(dump(e)) : null
|
|
|
- })})`
|
|
|
- )
|
|
|
-
|
|
|
- const res = this.m(amlu, list)
|
|
|
- Log.e(`alyx.m res: ${dump(res)}`)
|
|
|
- return res
|
|
|
- }
|
|
|
- alyx.r.overload('amlu', 'java.util.List', 'java.lang.String', 'java.lang.String').implementation = function (
|
|
|
- amlu,
|
|
|
- list,
|
|
|
- str,
|
|
|
- str2
|
|
|
- ) {
|
|
|
- Log.e(
|
|
|
- `alyx.r(${JSON.stringify({
|
|
|
- amlu: dumpJson(amlu),
|
|
|
- list: dumpJson(list),
|
|
|
- str,
|
|
|
- str2
|
|
|
- })})`
|
|
|
- )
|
|
|
- try {
|
|
|
- const res = this.r(amlu, list, str, str2)
|
|
|
- Log.e(`alyx.r res: ${res}`)
|
|
|
- return res
|
|
|
- } catch (error) {
|
|
|
- Log.e(`alyx.r error: ${error}`)
|
|
|
- }
|
|
|
- return false
|
|
|
- }
|
|
|
-
|
|
|
- alyx.x.overload('amlu', 'java.util.List').implementation = function (amlu, list) {
|
|
|
- const res = this.x(amlu, list)
|
|
|
- Log.e(`alyx.x(
|
|
|
- amlu=${dump(amlu)},
|
|
|
- list=${dump(list)})
|
|
|
- => ${dump(res)}`)
|
|
|
- return res
|
|
|
- }
|
|
|
-
|
|
|
- //amlu amluVar, fixf fixfVar, ammt ammtVar
|
|
|
- alyx.e.overload('amlu', 'fixf', 'ammt').implementation = function (amlu, fixf, ammt) {
|
|
|
- const res = this.e(amlu, fixf, ammt)
|
|
|
- Log.e(`alyx.e(
|
|
|
- amlu=${dump(amlu)},
|
|
|
- fixf=${dump(fixf)},
|
|
|
- ammt=${dump(ammt)})
|
|
|
- => ${dump(res)}`)
|
|
|
- return res
|
|
|
- }
|
|
|
-
|
|
|
- // alyx.v.overload("amlu", "java.util.List").implementation = function (
|
|
|
- // amlu,
|
|
|
- // list
|
|
|
- // ) {
|
|
|
- // const res = this.v(amlu, list)
|
|
|
- // Log.e(`alyx.v(
|
|
|
- // amlu=${dump(amlu)},
|
|
|
- // list=${dump(list)})
|
|
|
- // => ${dump(res)}`)
|
|
|
- // trace()
|
|
|
- // return res
|
|
|
- // }
|
|
|
-
|
|
|
- const ftit = Java.use('ftit')
|
|
|
- const ftgv = Java.use('ftgv')
|
|
|
- ftit.h.overload('ftgv').implementation = function (ftgvVar) {
|
|
|
- try {
|
|
|
- Log.e(`ftit.h(
|
|
|
- this=${dump(this)},
|
|
|
- ftgvVar=${dump(ftgvVar)})`)
|
|
|
- return Java.use('ftiu').$new(this, ftgvVar)
|
|
|
- } catch (e) {
|
|
|
- e.printStackTrace()
|
|
|
- Log.e(`ftit.h exception: ${e}`)
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- const Secure = Java.use('android.provider.Settings$Secure')
|
|
|
- Secure.getString.overload('android.content.ContentResolver', 'java.lang.String').implementation = function (
|
|
|
- contentResolver,
|
|
|
- str
|
|
|
- ) {
|
|
|
- const _str = this.getString(contentResolver, str)
|
|
|
- if (str === 'android_id') {
|
|
|
- Log.w(`spoof Secure.getString(android_id): ${_str} -> ${androidId}`)
|
|
|
- return androidId
|
|
|
- }
|
|
|
- return _str
|
|
|
- }
|
|
|
-
|
|
|
- const Build = Java.use('android.os.Build')
|
|
|
- Build.getString.overload('java.lang.String').implementation = function (str) {
|
|
|
- const _str = this.getString(str)
|
|
|
- Log.w(`Build.getString(${str}): ${_str}`)
|
|
|
- return _str
|
|
|
- }
|
|
|
-
|
|
|
- Build.getSerial.overload().implementation = function () {
|
|
|
- const _serial = this.getSerial()
|
|
|
- Log.w(`spoof Build.getSerial: ${_serial} -> ${serialNumber}`)
|
|
|
- return serialNumber
|
|
|
- }
|
|
|
-
|
|
|
- const SystemProperties = Java.use('android.os.SystemProperties')
|
|
|
- const props = []
|
|
|
- SystemProperties.get.overload('java.lang.String').implementation = function (str) {
|
|
|
- const _str = this.get(str)
|
|
|
- Log.w(`SystemProperties.get(${str}): ${_str}`)
|
|
|
- return _str
|
|
|
- }
|
|
|
- SystemProperties.get.overload('java.lang.String', 'java.lang.String').implementation = function (str, str2) {
|
|
|
- const _str = this.get(str, str2)
|
|
|
- if ('ro.boot.vr' === str) return _str
|
|
|
-
|
|
|
- // if ('ro.vendor.build.fingerprint' === str) {
|
|
|
- // Log.w(`spoof SystemProperties.get(${str}, ${str2}): ${_str} -> fingerprint`)
|
|
|
- // return 'google/redfin/redfin:11/RQ3A.210905.001/7511028:user/release-keys'
|
|
|
- // }
|
|
|
- // if ('ro.kernel.qemu' === str) {
|
|
|
- // Log.w(`spoof SystemProperties.get(${str}, ${str2}): ${_str} -> 0`)
|
|
|
- // return '0'
|
|
|
- // }
|
|
|
- // if ('ro.product.device' === str) {
|
|
|
- // Log.w(`spoof SystemProperties.get(${str}, ${str2}): ${_str} -> redfin`)
|
|
|
- // return 'redfin'
|
|
|
- // }
|
|
|
- // if ('ro.board.platform' === str) {
|
|
|
- // Log.w(`spoof SystemProperties.get(${str}, ${str2}): ${_str} -> redfin`)
|
|
|
- // return 'redfin'
|
|
|
- // }
|
|
|
-
|
|
|
- Log.w(`SystemProperties.get(${str}, ${str2}): ${_str}`)
|
|
|
- return _str
|
|
|
- }
|
|
|
- SystemProperties.getInt.overload('java.lang.String', 'int').implementation = function (str, i) {
|
|
|
- const _i = this.getInt(str, i)
|
|
|
- if ('ro.boot.flash.locked' === str) {
|
|
|
- Log.w(`spoof SystemProperties.get(${str}, ${i}): ${_i} -> 1`)
|
|
|
- return 1
|
|
|
- }
|
|
|
- Log.w(`SystemProperties.getInt(${str}, ${i}): ${_i}`)
|
|
|
- return _i
|
|
|
- }
|
|
|
- SystemProperties.getLong.overload('java.lang.String', 'long').implementation = function (str, l) {
|
|
|
- const _l = this.getLong(str, l)
|
|
|
- Log.w(`SystemProperties.getLong(${str}, ${l}): ${_l}`)
|
|
|
- return _l
|
|
|
- }
|
|
|
- SystemProperties.getBoolean.overload('java.lang.String', 'boolean').implementation = function (str, z) {
|
|
|
- const _z = this.getBoolean(str, z)
|
|
|
- Log.w(`SystemProperties.getBoolean(${str}, ${z}): ${_z}`)
|
|
|
- return _z
|
|
|
- }
|
|
|
- // const OSBuild = Java.use('android.os.Build')
|
|
|
- // OSBuild.PRODUCT.value = 'redfin'
|
|
|
- // OSBuild.DEVICE.value = 'redfin'
|
|
|
- // OSBuild.MANUFACTURER.value = 'Google'
|
|
|
- // OSBuild.BOARD.value = 'redfin'
|
|
|
- // OSBuild.BRAND.value = 'google'
|
|
|
- // OSBuild.MODEL.value = 'Pixel 5'
|
|
|
- // OSBuild.FINGERPRINT.value = 'google/redfin/redfin:11/RQ3A.210905.001/7511028:user/release-keys'
|
|
|
- // OSBuild.TYPE.value = 'user'
|
|
|
- // OSBuild.TAGS.value = 'release-keys'
|
|
|
-
|
|
|
- const alzg = Java.use('alzg')
|
|
|
- alzg.d.overload(
|
|
|
- // boolean, map
|
|
|
- 'boolean',
|
|
|
- 'java.util.Map'
|
|
|
- ).implementation = function (z, map) {
|
|
|
- Log.e(`alzg.d(z=${z}, map=${dump(map)})`)
|
|
|
- return this.d(z, map)
|
|
|
- }
|
|
|
-
|
|
|
- // const ammv = Java.use("ammv")
|
|
|
- // ammv.a.overload(
|
|
|
- // // amlu amluVar, fixf fixfVar, ammt ammtVar, ammi ammiVar
|
|
|
- // "amlu",
|
|
|
- // "fixf",
|
|
|
- // "ammt",
|
|
|
- // "ammi"
|
|
|
- // ).implementation = function (amlu, fixf, ammt, ammi) {
|
|
|
- // Log.e(`ammv.a(
|
|
|
- // amlu=${dump(amlu)},
|
|
|
- // fixf=${dump(fixf)},
|
|
|
- // ammt=${dump(ammt)},
|
|
|
- // ammi=${dump(ammi)})`)
|
|
|
- // trace()
|
|
|
- // return this.a(amlu, fixf, ammt, ammi)
|
|
|
- // }
|
|
|
-
|
|
|
- // const amag = Java.use("amag")
|
|
|
- // amag.b.overload(
|
|
|
- // // akxi akxiVar, fiwx fiwxVar, long j
|
|
|
- // "akxi",
|
|
|
- // "fiwx",
|
|
|
- // "long"
|
|
|
- // ).implementation = function (akxi, fiwx, j) {
|
|
|
- // Log.e(`amag.b(
|
|
|
- // akxi=${dump(akxi)},
|
|
|
- // fiwx=${dump(fiwx)},
|
|
|
- // j=${j})`)
|
|
|
- // trace()
|
|
|
- // return this.b(akxi, fiwx, j)
|
|
|
- // }
|
|
|
-
|
|
|
- // const Configuration = Java.use(
|
|
|
- // "com.google.android.ims.provisioning.config.Configuration"
|
|
|
- // )
|
|
|
- // Configuration.k.overload().implementation = function () {
|
|
|
- // Log.e(`Configuration.k() ${dump(this)}`)
|
|
|
- // return this.k()
|
|
|
- // }
|
|
|
-
|
|
|
- const amky = Java.use('amky')
|
|
|
- amky.a.overload('android.content.Context', 'java.lang.String', 'java.lang.String').implementation = function (
|
|
|
- context,
|
|
|
- str,
|
|
|
- str2
|
|
|
- ) {
|
|
|
- Log.e(`amky.a(${str}, ${str2})`)
|
|
|
- return this.a(context, str, str2)
|
|
|
+ const EventManager = Java.use('com.google.android.gms.constellation.EventManager')
|
|
|
+ EventManager.onHandleIntent.overload('android.content.Intent').implementation = function (intent) {
|
|
|
+ Log.i('EventManager.onHandleIntent(intent)')
|
|
|
+ return this.onHandleIntent(intent)
|
|
|
}
|
|
|
})
|