正在查看: Minits v4.9.3.32 应用的 XoneBroadcastReceiver.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: Minits v4.9.3.32 应用的 XoneBroadcastReceiver.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.xone.android.framework.receivers;
import C8.D;
import android.app.NotificationChannel;
import android.app.NotificationManager;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Build;
import android.os.Bundle;
import android.os.Handler;
import android.service.notification.StatusBarNotification;
import android.text.TextUtils;
import com.xone.android.framework.AbstractC0568j;
import com.xone.android.framework.activities.MainListCollectionActivity;
import com.xone.android.framework.activities.XoneBaseActivity;
import com.xone.android.framework.mainEntry;
import com.xone.android.framework.xoneApp;
import com.xone.android.utils.Utils;
import com.xone.interfaces.IXoneCollection;
import fb.AbstractC0692e;
import ha.AbstractC0751f;
import ha.t;
import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
import java.util.concurrent.TimeUnit;
import o8.C0873a;
import q3.i;
import t8.C0990a;
import t8.C0991b;
import z0.r;
import z0.u;
public final class XoneBroadcastReceiver extends BroadcastReceiver {
public static xoneApp i() {
return xoneApp.Z0();
}
public static NotificationManager j() {
NotificationManager notificationManager = (NotificationManager) i().getSystemService("notification");
if (notificationManager != null) {
return notificationManager;
}
throw new NullPointerException("Cannot obtain NotificationManager service");
}
public static u k() {
u e = u.e(i());
if (e != null) {
return e;
}
throw new NullPointerException("Cannot obtain NotificationManagerCompat service");
}
public final void b(CharSequence charSequence) {
if (TextUtils.isEmpty(charSequence)) {
return;
}
Utils.k("XoneBroadcastReceiver", charSequence);
}
public final void c() {
if (Build.VERSION.SDK_INT < 26) {
return;
}
u k = k();
if (k.g("XOneFrameworkSecureProvisioningNotificationChannel") != null) {
return;
}
NotificationChannel a = i.a("XOneFrameworkSecureProvisioningNotificationChannel", "XOneFramework secure provisioning notification channel", 4);
a.enableLights(true);
a.enableVibration(true);
k.d(a);
}
public final void d(Bundle bundle) {
String string = bundle.getString("command");
if (TextUtils.isEmpty(string)) {
return;
}
string.getClass();
if (string.equals("closedatabaseconnections")) {
xoneApp.Z0().R0(bundle.getString("connectionstring"));
return;
}
if (!string.equals("exitframework")) {
Utils.l("XOneAndroidFramework", "Unknown command: " + string);
return;
}
Utils.l("XOneAndroidFramework", "Closing framework. bForce = " + bundle.getBoolean("bForce", true));
mainEntry S = xoneApp.Z0().S();
if (S != null) {
S.E0(true);
}
}
public final void e(Bundle bundle) {
String string = bundle.getString("appname");
ArrayList parcelableArrayList = bundle.getParcelableArrayList("resultData");
if (TextUtils.isEmpty(string)) {
throw new IllegalArgumentException("Invalid argument, the app name cannot be null");
}
if (parcelableArrayList == null) {
throw new IllegalArgumentException("Invalid argument, resultData == null");
}
new C0990a(string, parcelableArrayList).runSeriallyAsyncTask();
}
public final void f(Bundle bundle) {
String j = AbstractC0692e.j(bundle, "sourcePackageName", "");
String packageName = i().getPackageName();
if (TextUtils.isEmpty(j)) {
b("Empty source package name, this intent comes from an old replicator client. Ignoring.");
return;
}
if (j.equals(packageName)) {
ArrayList<String> stringArrayList = bundle.getStringArrayList("tables");
if (stringArrayList != null) {
m(stringArrayList);
}
String string = bundle.getString("appname");
if (TextUtils.isEmpty(string)) {
throw new NullPointerException("doReplicaOk(): Malformed intent received, the app name cannot be null");
}
new C0991b(string, stringArrayList).runSeriallyAsyncTask();
return;
}
b("Source package name (" + j + ") does not match current proccess package name(" + packageName + "). Ignoring.");
}
public final void g(Bundle bundle) {
boolean z = bundle.getBoolean("locked");
SharedPreferences.Editor edit = xoneApp.Z0().getSharedPreferences("com.xone.live.SET_FRAMEWORK_LOCKED_BY_SECURE_PROVISIONING", 0).edit();
edit.putBoolean("locked", z);
edit.commit();
}
public final void h(Context context, Bundle bundle) {
int i = bundle.getInt("code");
String string = bundle.getString("message");
String string2 = bundle.getString("database-path");
String string3 = bundle.getString("live-receiver");
String string4 = bundle.getString("live-package-name");
String string5 = bundle.getString("app-name");
String string6 = bundle.getString("id-task");
D d = new D(i, string, string2, string4, string3, string5, string6);
if (xoneApp.c1() == null && d.d() == 1003) {
new C0873a(context, 100L, string2, string4, string3, string5, string6).b();
return;
}
if (d.c() || d.d() != 1003) {
if (d.c()) {
d.runSeriallyAsyncTask();
}
} else {
long millis = TimeUnit.SECONDS.toMillis(30L);
n(context, millis);
new C0873a(context, millis, string2, string4, string3, string5, string6).b();
}
}
public final boolean l() {
StatusBarNotification[] activeNotifications;
if (Build.VERSION.SDK_INT < 23) {
return false;
}
try {
activeNotifications = j().getActiveNotifications();
if (activeNotifications == null) {
return false;
}
for (StatusBarNotification statusBarNotification : activeNotifications) {
if (statusBarNotification != null && statusBarNotification.getId() == 652201) {
return true;
}
}
return false;
} catch (Exception e) {
e.printStackTrace();
return false;
}
}
public final void m(List list) {
IXoneCollection B1;
xoneApp Z0 = xoneApp.Z0();
Object I0 = Z0.I0();
if (I0 instanceof MainListCollectionActivity) {
MainListCollectionActivity mainListCollectionActivity = (MainListCollectionActivity) I0;
String N6 = mainListCollectionActivity.N6();
if (!TextUtils.isEmpty(N6) || Z0.G0() == null || (B1 = XoneBaseActivity.B1(N6)) == null) {
return;
}
String fixedUpdateObjectName = B1.getFixedUpdateObjectName();
if (TextUtils.isEmpty(fixedUpdateObjectName) || !list.contains(fixedUpdateObjectName.toLowerCase(Locale.US))) {
return;
}
try {
mainListCollectionActivity.j7();
} catch (Exception e) {
throw AbstractC0751f.e(e);
}
}
}
public final void n(Context context, long j) {
Context applicationContext = context.getApplicationContext();
c();
if (l()) {
return;
}
r.e A = new r.e(applicationContext, "XOneFrameworkSecureProvisioningNotificationChannel").n(-1).y(t.a).F(System.currentTimeMillis()).C(true).D(new long[]{100, 100, 100}).m(applicationContext.getString(AbstractC0568j.y0)).l(applicationContext.getString(AbstractC0568j.l0)).A(new r.c().h(applicationContext.getString(AbstractC0568j.l0)));
final u k = k();
k.h(652201, A.c());
new Handler().postDelayed(new Runnable() {
@Override
public final void run() {
k.b(652201);
}
}, j);
}
@Override
public void onReceive(Context context, Intent intent) {
char c;
if (intent == null) {
b("Invoked with null intent parameter, ignoring");
return;
}
String action = intent.getAction();
if (TextUtils.isEmpty(action)) {
b("Invoked with no action set, ignoring");
return;
}
Bundle extras = intent.getExtras();
if (extras == null) {
b("Invoked with no extras set, ignoring");
return;
}
try {
switch (action.hashCode()) {
case -1488569771:
if (action.equals("com.xone.live.SET_FRAMEWORK_LOCKED_BY_SECURE_PROVISIONING")) {
c = 3;
break;
}
c = 65535;
break;
case -1454077611:
if (action.equals("com.xone.framework.systemmessage")) {
c = 2;
break;
}
c = 65535;
break;
case -1067881760:
if (action.equals("XONESPECIALCOMMAND")) {
c = 4;
break;
}
c = 65535;
break;
case -142676457:
if (action.equals("com.xone.replicator.replicafilesok")) {
c = 1;
break;
}
c = 65535;
break;
case 1093764056:
if (action.equals("com.xone.replicator.replicaok")) {
c = 0;
break;
}
c = 65535;
break;
default:
c = 65535;
break;
}
if (c == 0) {
f(extras);
return;
}
if (c == 1) {
e(extras);
return;
}
if (c == 2) {
h(context, extras);
return;
}
if (c == 3) {
g(extras);
return;
}
if (c == 4) {
d(extras);
return;
}
b("Unknown action " + action);
} catch (Exception e) {
e.printStackTrace();
}
}
}