正在查看: 万能钥匙 v1.1.23 应用的 MsgService.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: 万能钥匙 v1.1.23 应用的 MsgService.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.wifi.connect.service;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.os.IBinder;
import android.os.RemoteException;
import android.text.TextUtils;
import com.meituan.robust.ChangeQuickRedirect;
import com.meituan.robust.PatchProxy;
import com.meituan.robust.PatchProxyResult;
import com.sdk.plus.data.manager.RalDataManager;
import com.wifi.connect.service.a;
import f60.f1;
import f60.g1;
import java.util.Calendar;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import os.C0341a;
import os.C0350b;
import os.g;
import os.u5;
import pa.d;
public class MsgService extends Service {
public static ChangeQuickRedirect changeQuickRedirect = null;
public static String e = "wifi.intent.action.STICKY_SERVICE";
public static b f;
public a b;
public boolean c;
public String a = "MsgService_Main";
public boolean d = false;
public class a extends a.AbstractBinderC0088a {
public static ChangeQuickRedirect changeQuickRedirect;
public a() {
}
@Override
public String l() throws RemoteException {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 1478, new Class[0], String.class);
return proxy.isSupported ? (String) proxy.result : MsgService.class.getSimpleName();
}
}
public interface b {
void run();
}
public final void a(Context context, String str, Intent intent) {
JSONObject optJSONObject;
String optString;
if (PatchProxy.proxy(new Object[]{context, str, intent}, this, changeQuickRedirect, false, 1474, new Class[]{Context.class, String.class, Intent.class}, Void.TYPE).isSupported) {
return;
}
JSONObject a2 = C0350b.a("hudiao");
d.a(this.a + ":hudiao|" + a2, new Object[0]);
String stringExtra = intent.getStringExtra("from");
d.a(this.a, new Object[]{intent.toString()});
String stringExtra2 = intent.getStringExtra("launchSource");
if (a2 != null) {
JSONArray optJSONArray = a2.optJSONArray("whiteList_bc");
if (optJSONArray == null) {
try {
optJSONArray = new JSONArray();
} catch (JSONException e2) {
e2.printStackTrace();
}
}
JSONObject jSONObject = new JSONObject();
jSONObject.put("pkg", "com.snda.lantern.wifilocating");
jSONObject.put("action", "com.lantern.hudiao.receive_Lite");
d.a(this.a + ":" + jSONObject.toString(), new Object[0]);
optJSONArray.put(optJSONArray.length(), jSONObject);
if (optJSONArray != null) {
for (int i = 0; i < optJSONArray.length(); i++) {
try {
optJSONObject = optJSONArray.optJSONObject(i);
optString = optJSONObject.optString("pkg");
d.a(optJSONArray.length() + "aaaaaa" + optJSONObject.toString() + "|" + optString + " qqq" + optString.equals(stringExtra) + "bbbb" + stringExtra, new Object[0]);
} catch (Exception e3) {
e3.printStackTrace();
}
if (optString.equals(stringExtra)) {
String optString2 = optJSONObject.optString("action");
Intent intent2 = new Intent();
intent2.putExtra("source", context.getPackageName());
if (stringExtra2 != null) {
intent2.putExtra("launchSource", stringExtra2);
}
intent2.setAction(optString2);
context.sendBroadcast(intent2);
d.a(this.a + ":sendBroadcast:" + optString2 + "||" + context.getPackageName(), new Object[0]);
return;
}
continue;
}
}
}
}
@Override
public IBinder onBind(Intent intent) {
return this.b;
}
@Override
public void onCreate() {
if (PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 1472, new Class[0], Void.TYPE).isSupported) {
return;
}
super.onCreate();
if (!g.r()) {
stopSelf();
return;
}
this.b = new a();
b bVar = f;
if (bVar != null) {
bVar.run();
}
}
@Override
public void onLowMemory() {
if (PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 1476, new Class[0], Void.TYPE).isSupported) {
return;
}
super.onLowMemory();
}
@Override
public int onStartCommand(Intent intent, int i, int i2) {
StringBuilder sb;
int i3;
Object[] objArr = {intent, new Integer(i), new Integer(i2)};
ChangeQuickRedirect changeQuickRedirect2 = changeQuickRedirect;
Class cls = Integer.TYPE;
PatchProxyResult proxy = PatchProxy.proxy(objArr, this, changeQuickRedirect2, false, 1473, new Class[]{Intent.class, cls, cls}, cls);
if (proxy.isSupported) {
return ((Integer) proxy.result).intValue();
}
if (!g.r()) {
return 2;
}
super.onStartCommand(intent, i, i2);
if (intent != null) {
try {
String stringExtra = intent.getStringExtra("source");
String stringExtra2 = intent.getStringExtra(RalDataManager.DB_TYPE);
String stringExtra3 = intent.getStringExtra("from");
String stringExtra4 = intent.getStringExtra("subPkg");
d.a("source %s, from %s", new Object[]{stringExtra, stringExtra3});
if (stringExtra != null) {
if (TextUtils.equals(stringExtra, "dprocess") || stringExtra.startsWith("dprocess2") || stringExtra.startsWith("dprocess3") || stringExtra.startsWith("jobc")) {
if (i2 == 1) {
sb = new StringBuilder();
sb.append("cw01_");
sb.append(stringExtra);
} else {
sb = new StringBuilder();
sb.append("cw11_");
sb.append(stringExtra);
}
String sb2 = sb.toString();
d.a("dprocess %s %s", new Object[]{Boolean.FALSE, sb2});
if (sb2.contains("cw01")) {
tp.a.c("cw01", stringExtra, stringExtra2, stringExtra4);
if (stringExtra3 != null) {
a(this, "cw01_back", intent);
}
} else {
tp.a.c("cw11", stringExtra, stringExtra2, stringExtra4);
if (stringExtra3 != null) {
a(this, "cw11_back", intent);
}
}
} else if (i2 == 1) {
tp.a.c("cw01", stringExtra, stringExtra2, stringExtra4);
if (stringExtra3 != null) {
a(this, "cw01_back", intent);
}
} else if (!TextUtils.equals(stringExtra, "job") && !TextUtils.equals(stringExtra, "sync") && !TextUtils.equals(stringExtra, "dprocess") && !TextUtils.equals(stringExtra, "dprocess2") && !TextUtils.equals(stringExtra, "dprocess3") && !TextUtils.equals(stringExtra, "notifyService") && !TextUtils.equals(stringExtra, "alarm") && !stringExtra.startsWith("jobc") && !stringExtra.startsWith("receiver_") && !stringExtra.startsWith("protect")) {
tp.a.c("cw11", stringExtra, stringExtra2, stringExtra4);
if (stringExtra3 != null) {
a(this, "cw11_back", intent);
}
}
if (!this.d && (i3 = Calendar.getInstance().get(11)) >= 1 && i3 < 23) {
this.d = true;
sendBroadcast(new Intent("android.lantern.download.BORE"));
}
}
if (!this.c && stringExtra.equals("jpush")) {
C0341a.e("jiguang_pushsucc");
d.g("jiguang_pushsucc", new Object[]{"jiguang_pushsucc"});
this.c = true;
}
} catch (Throwable unused) {
}
}
g1 b2 = f1.b(os.g1.a(u5.d()));
if (!(b2 instanceof g1)) {
return 2;
}
b2.da();
return 2;
}
@Override
public void onTrimMemory(int i) {
if (PatchProxy.proxy(new Object[]{new Integer(i)}, this, changeQuickRedirect, false, 1475, new Class[]{Integer.TYPE}, Void.TYPE).isSupported) {
return;
}
super.onTrimMemory(i);
}
}