Last active
March 8, 2019 18:15
-
-
Save pich4ya/8a9eb78bdd604a43f982b7a38054956c to your computer and use it in GitHub Desktop.
For educational purposes only. - https://www.blognone.com/node/108546 - [SHA-256: 8e686a74c47fb1733ed201b76f0a7cfaeed66140599b7b1043f905a7ad9b6044 - app-nbtc.apk / 1552060769 ]
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.) BackgroundServiceNew will be triggered through JobInfo.Builder(..) in: | |
com/electronicshell/nbtcconsult/QuestionActivity.java | |
34:import com.electronicshell.nbtcconsult.BackGroundUse.BackgroundServiceNew; | |
122: JobInfo jobInfo = new JobInfo.Builder(123, new ComponentName(context, BackgroundServiceNew.class)).setRequiresCharging(true).setRequiredNetworkType(1).setPersisted(true).setPeriodic(900000L).build(); | |
com/electronicshell/nbtcconsult/BackGroundUse/BootDeviceReceiver.java | |
35:import com.electronicshell.nbtcconsult.BackGroundUse.BackgroundServiceNew; | |
91: JobInfo jobInfo = new JobInfo.Builder(123, new ComponentName(context, BackgroundServiceNew.class)).setRequiresCharging(true).setRequiredNetworkType(1).setPersisted(true).setPeriodic(900000L).build(); | |
com/electronicshell/nbtcconsult/NewMenuActivity.java | |
105:import com.electronicshell.nbtcconsult.BackGroundUse.BackgroundServiceNew; | |
1390: JobInfo jobInfo = new JobInfo.Builder(123, new ComponentName(context, BackgroundServiceNew.class)).setRequiresCharging(true).setRequiredNetworkType(1).setPersisted(true).setPeriodic(900000L).build(); | |
com/electronicshell/nbtcconsult/BackGroundUse/BackgroundServiceNew.java | |
83:public class BackgroundServiceNew | |
87: private static final String TAG = "BackgroundServiceNew"; | |
210: Log.e((String)BackgroundServiceNew.TAG, (String)stringBuilder.toString()); | |
212: if (BackgroundServiceNew.this.jobState) { | |
223: Log.e((String)BackgroundServiceNew.TAG, (String)"Background End"); | |
224: BackgroundServiceNew.this.jobFinished(jobParameters, false); | |
252: super(BackgroundServiceNew.this.getApplicationContext()); | |
270: super(BackgroundServiceNew.this.getApplicationContext()); | |
300: UsageCollector usageCollector = new UsageCollector(BackgroundServiceNew.this.getApplicationContext()); | |
369: Log.e((String)BackgroundServiceNew.TAG, (String)"Job Timeout"); | |
370: BackgroundServiceNew.this.CountDownJobBG.start(); | |
375: BackgroundServiceNew.this.doBackgroundWork(jobParameters); | |
377: UserLocation.mylocation(BackgroundServiceNew.this.getApplicationContext()); | |
378: BackgroundServiceNew.this.getGroupsFromServer(); | |
379: BackgroundServiceNew.this.collectData(); | |
380: BackgroundServiceNew.this.fetchData(); | |
440: ((StringBuilder)charSequence).append(BackgroundServiceNew.convertSecondsToHMmSs(list.get(i).getTotalTimeInForeground())); | |
com/electronicshell/nbtcconsult/TabView/TabActivity.java | |
39:import com.electronicshell.nbtcconsult.BackGroundUse.BackgroundServiceNew; | |
201: JobInfo jobInfo = new JobInfo.Builder(123, new ComponentName(context, BackgroundServiceNew.class)).setRequiresCharging(true).setRequiredNetworkType(1).setPersisted(true).setPeriodic(900000L).build(); | |
com/electronicshell/nbtcconsult/Setting/PrivacyActivity.java | |
46:import com.electronicshell.nbtcconsult.BackGroundUse.BackgroundServiceNew; | |
193: JobInfo jobInfo = new JobInfo.Builder(123, new ComponentName(context, BackgroundServiceNew.class)).setRequiresCharging(true).setRequiredNetworkType(1).setPersisted(true).setPeriodic(900000L).build(); | |
2.) BackgroundServiceNew -> fetchData() -> fetchAllSchedAndSync() | |
File: /com/electronicshell/nbtcconsult/BackGroundUse/BackgroundServiceNew.java | |
public void fetchData() { | |
new AsyncTask<Void, Void, Void>(){ | |
protected /* varargs */ Void doInBackground(Void ... object) { | |
try { | |
Log.i((String)"wtf", (String)"Fetch data in background"); | |
super(BackgroundServiceNew.this.getApplicationContext()); | |
((UsageSyncToServerFetcher)object).fetchAllSchedAndSync(); | |
[...] | |
3.) BackgroundServiceNew -> fetchData() -> fetchAllSchedAndSync() -> postUsageInfo() | |
File: /com/electronicshell/nbtcconsult/BackGroundUse/usages/UsageSyncToServerFetcher.java | |
public void fetchAllSchedAndSync() { | |
AppDatabase appDatabase = AppDatabase.getAppDatabase(this.context); | |
Object object = appDatabase.jobSchdDao().findAllByStatus(JobSchdStatus.PENDING); | |
ApiRequest apiRequest = new ApiRequest(); | |
if (object != null) { | |
object = object.iterator(); | |
while (object.hasNext()) { | |
Object object2 = (JobSchd)object.next(); | |
try { | |
String string2 = apiRequest.postUsageInfo((JobSchd)object2); | |
[...] | |
4.) BackgroundServiceNew -> fetchData() -> fetchAllSchedAndSync() -> postUsageInfo() -> api/raws.json | |
File: /com/electronicshell/nbtcconsult/BackGroundUse/api/ApiRequest.java | |
private String baseUrl = "https://www.uteleme.com/"; | |
[...] | |
private String postJsonString(String object, String object2) throws Exception { | |
block5 : { | |
Object object3 = new StringBuilder(); | |
((StringBuilder)object3).append(this.baseUrl); | |
[...] | |
public String postUsageInfo(JobSchd object) throws Exception { | |
this.adjustTrustCerts(); | |
object = this.postJsonString("api/raws.json", ((JobSchd)object).jsonPayload); | |
[...] | |
5.) "ในขณะที่ข้อมูลที่ส่งเข้าสู่ระบบจะเป็นผลรวมของกลุ่มตัวอย่างทั้งหมดโดยไม่แสดงรายปัจเจกบุคคล" | |
POST /api/raws.json HTTP/1.1 | |
Host: www.uteleme.com | |
[...] | |
{"data":{"appUsageStats":[],"callUsageStats":[],"dailyTopAppUsageStats":[],"hourlyUsageStats":[{[...]"2019-03-07T22:00:00+0000","wifiDownloadBytes":0,"wifiUploadBytes":0},{"endTime":"2019-03-07T23:59:59+0000","hour":23,"mobileDownloadBytes":0,"mobileUploadBytes":0,"queryTime":"2019-03-08T18:11:34+0000","startTime":"2019-03-07T23:00:00+0000","wifiDownloadBytes":0,"wifiUploadBytes":0}],"locations":[],"mmsUsageStats":[],"smsUsageStats":[]},"imei":"555133713371337","telephone_no":"15513371337"} | |
มีการส่ง imei กับเบอร์โทรศัพท์ไปพร้อมกับข้อมูล |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment