正在查看: moonshot.企业版 v5.53.33 应用的 C5569.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: moonshot.企业版 v5.53.33 应用的 C5569.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package jnksI9k6J1HFuFo5YzBf.DdEnhsMlZWtEOFIm1zd3.UBVL9U3WwxbAPwDW6rA5.jnksI9k6J1HFuFo5YzBf;
import android.content.Context;
import android.content.SharedPreferences;
import android.content.pm.PackageInfo;
import android.os.Process;
import android.text.TextUtils;
import com.tencent.bugly.crashreport.common.info.PlugInBean;
import com.xiaomi.mipush.sdk.Constants;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.UUID;
public final class C5569 {
private String f22558;
public final String f22560;
public int f22566;
public List<String> f22568;
public final SharedPreferences f22575;
public String f22579;
private String f22583;
public boolean f22585;
public final SharedPreferences f22596;
public String f22599;
public String f22603;
public String f22606;
private final Context f22607;
private String f22609;
public String f22612;
private String f22615;
public final String f22617;
public String f22618;
public String f22621;
public String f22623;
public String f22625;
public boolean f22628;
public String f22630;
private static final Map<String, String> f22555 = new HashMap();
private static C5569 f22554 = null;
public boolean f22584 = true;
public final String f22622 = "com.tencent.bugly";
public String f22561 = "4.1.9.3";
public final String f22586 = "";
@Deprecated
public final String f22590 = "";
public String f22557 = "unknown";
private String f22594 = "unknown";
private String f22608 = "";
public long f22591 = 0;
private String f22562 = null;
private long f22567 = -1;
private long f22588 = -1;
private long f22589 = -1;
private String f22629 = null;
private String f22578 = null;
private Map<String, PlugInBean> f22601 = null;
public boolean f22576 = false;
private String f22602 = null;
private Boolean f22573 = null;
private String f22616 = null;
public String f22577 = null;
public String f22600 = null;
private Map<String, PlugInBean> f22624 = null;
private Map<String, PlugInBean> f22604 = null;
public int f22563 = -1;
public int f22595 = -1;
private final Map<String, String> f22582 = new HashMap();
private final Map<String, String> f22564 = new HashMap();
private final Map<String, String> f22614 = new HashMap();
public String f22620 = "unknown";
public long f22556 = 0;
public long f22611 = 0;
public long f22574 = 0;
public long f22571 = 0;
public boolean f22569 = false;
public HashMap<String, String> f22598 = new HashMap<>();
public List<String> f22597 = new ArrayList();
public boolean f22572 = false;
public InterfaceC5598 f22565 = null;
public boolean f22570 = true;
public boolean f22627 = true;
public boolean f22593 = false;
private final Object f22610 = new Object();
public final Object f22626 = new Object();
private final Object f22605 = new Object();
private final Object f22613 = new Object();
public final Object f22580 = new Object();
public final Object f22587 = new Object();
private final Object f22559 = new Object();
private final List<Integer> f22619 = new ArrayList();
public final long f22592 = System.currentTimeMillis();
public final byte f22581 = 1;
private C5569(Context context) {
this.f22615 = null;
this.f22612 = null;
this.f22623 = null;
this.f22625 = null;
this.f22603 = null;
this.f22568 = null;
this.f22585 = false;
this.f22599 = null;
this.f22618 = null;
this.f22606 = null;
this.f22621 = "";
this.f22628 = false;
this.f22607 = C5658.m25859(context);
PackageInfo m25740 = C5620.m25740(context);
if (m25740 != null) {
try {
String str = m25740.versionName;
this.f22612 = str;
this.f22599 = str;
this.f22618 = Integer.toString(m25740.versionCode);
} catch (Throwable th) {
if (!C5612.m25717(th)) {
th.printStackTrace();
}
}
}
this.f22630 = C5620.m25739(context);
this.f22560 = C5620.m25745(Process.myPid());
this.f22623 = C5620.m25741(context);
this.f22617 = "Android " + C5641.m25814() + ",level " + C5641.m25828();
Map<String, String> m25743 = C5620.m25743(context);
if (m25743 != null) {
try {
this.f22568 = C5620.m25744(m25743);
String str2 = m25743.get("BUGLY_APPID");
if (str2 != null) {
this.f22625 = str2;
m25543("APP_ID", str2);
}
String str3 = m25743.get("BUGLY_APP_VERSION");
if (str3 != null) {
this.f22612 = str3;
}
String str4 = m25743.get("BUGLY_APP_CHANNEL");
if (str4 != null) {
this.f22603 = str4;
}
String str5 = m25743.get("BUGLY_ENABLE_DEBUG");
if (str5 != null) {
this.f22585 = str5.equalsIgnoreCase("true");
}
String str6 = m25743.get("com.tencent.rdm.uuid");
if (str6 != null) {
this.f22606 = str6;
}
String str7 = m25743.get("BUGLY_APP_BUILD_NO");
if (!TextUtils.isEmpty(str7)) {
this.f22566 = Integer.parseInt(str7);
}
String str8 = m25743.get("BUGLY_AREA");
if (str8 != null) {
this.f22621 = str8;
}
} catch (Throwable th2) {
if (!C5612.m25717(th2)) {
th2.printStackTrace();
}
}
}
try {
if (!context.getDatabasePath("bugly_db_").exists()) {
this.f22628 = true;
C5612.m25713("App is first time to be installed on the device.", new Object[0]);
}
} catch (Throwable th3) {
if (C5660.f22940) {
th3.printStackTrace();
}
}
this.f22596 = C5658.m25831("BUGLY_COMMON_VALUES", context);
this.f22575 = C5658.m25831("BUGLY_RESERVED_VALUES", context);
this.f22615 = C5641.m25808(context);
m25542();
C5612.m25713("com info create end", new Object[0]);
}
public static int m25533() {
return C5641.m25828();
}
private String m25534() {
if (TextUtils.isEmpty(this.f22562)) {
this.f22562 = C5658.m25838("androidid", null);
}
return this.f22562;
}
private static String m25535() {
String uuid = UUID.randomUUID().toString();
return !C5658.m25857(uuid) ? uuid.replaceAll(Constants.ACCEPT_TIME_SEPARATOR_SERVER, "") : uuid;
}
@Deprecated
public static boolean m25536() {
C5612.m25712("Detect if the device hook is unavailable", new Object[0]);
return false;
}
public static synchronized C5569 m25537(Context context) {
C5569 c5569;
synchronized (C5569.class) {
if (f22554 == null) {
f22554 = new C5569(context);
}
c5569 = f22554;
}
return c5569;
}
private void m25538(String str, String str2, boolean z) {
if (C5658.m25857(str)) {
C5612.m25716("key should not be empty %s", str);
return;
}
C5612.m25713("putExtraRequestData key:%s value:%s save:%s", str, str2, Boolean.valueOf(z));
synchronized (this.f22559) {
if (TextUtils.isEmpty(str2)) {
this.f22564.remove(str);
this.f22575.edit().remove(str).apply();
} else {
this.f22564.put(str, str2);
if (z) {
this.f22575.edit().putString(str, str2).apply();
}
}
}
}
@Deprecated
public static boolean m25539() {
C5612.m25712("Detect if the emulator is unavailable", new Object[0]);
return false;
}
public static synchronized C5569 m25540() {
C5569 c5569;
synchronized (C5569.class) {
c5569 = f22554;
}
return c5569;
}
@Deprecated
public static String m25541() {
return "";
}
private void m25542() {
try {
for (Map.Entry<String, ?> entry : this.f22575.getAll().entrySet()) {
C5612.m25713("put reserved request data from sp, key:%s value:%s", entry.getKey(), entry.getValue());
m25538(entry.getKey(), entry.getValue().toString(), false);
}
for (Map.Entry<String, String> entry2 : f22555.entrySet()) {
C5612.m25713("put reserved request data from cache, key:%s value:%s", entry2.getKey(), entry2.getValue());
m25538(entry2.getKey(), entry2.getValue(), true);
}
f22555.clear();
} catch (Throwable th) {
C5612.m25711(th);
}
}
public final void m25543(String str, String str2) {
if (C5658.m25857(str) || C5658.m25857(str2)) {
C5612.m25716("server key&value should not be empty %s %s", String.valueOf(str), String.valueOf(str2));
return;
}
synchronized (this.f22613) {
this.f22614.put(str, str2);
}
}
public final void m25544(String str) {
this.f22609 = str;
if (!TextUtils.isEmpty(str)) {
C5658.m25854("deviceId", str);
}
synchronized (this.f22559) {
this.f22564.put("E8", str);
}
}
public final synchronized void m25545(String str) {
this.f22608 = String.valueOf(str);
}
public final Set<String> m25546() {
Set<String> keySet;
synchronized (this.f22605) {
keySet = this.f22582.keySet();
}
return keySet;
}
public final int m25547() {
int i;
synchronized (this.f22580) {
i = this.f22563;
}
return i;
}
public final long m25548() {
if (this.f22589 <= 0) {
this.f22589 = C5641.m25826();
}
return this.f22589;
}
public final String m25549() {
return !C5658.m25857(this.f22579) ? this.f22579 : this.f22625;
}
public final int m25550() {
int size;
synchronized (this.f22605) {
size = this.f22582.size();
}
return size;
}
public final synchronized Map<String, PlugInBean> m25551() {
Map<String, PlugInBean> map = this.f22601;
if (map != null && map.size() > 0) {
HashMap hashMap = new HashMap(this.f22601.size());
hashMap.putAll(this.f22601);
return hashMap;
}
return null;
}
public final synchronized String m25552() {
return this.f22608;
}
public final Boolean m25553() {
if (this.f22573 == null) {
this.f22573 = Boolean.valueOf(C5641.m25811());
}
return this.f22573;
}
public final String m25554() {
String str = this.f22609;
if (str != null) {
return str;
}
String m25838 = C5658.m25838("deviceId", null);
this.f22609 = m25838;
if (m25838 != null) {
return m25838;
}
String m25534 = m25534();
this.f22609 = m25534;
if (TextUtils.isEmpty(m25534)) {
this.f22609 = m25535();
}
String str2 = this.f22609;
if (str2 == null) {
return "";
}
C5658.m25854("deviceId", str2);
return this.f22609;
}
public final Map<String, String> m25555() {
synchronized (this.f22613) {
if (this.f22614.size() <= 0) {
return null;
}
return new HashMap(this.f22614);
}
}
public final boolean m25556() {
boolean z = this.f22619.size() > 0;
C5612.m25713("isAppForeground:%s", Boolean.valueOf(z));
return z;
}
public final void m25557(String str, String str2) {
if (C5658.m25857(str) || C5658.m25857(str2)) {
C5612.m25716("key&value should not be empty %s %s", String.valueOf(str), String.valueOf(str2));
return;
}
synchronized (this.f22605) {
this.f22582.put(str, str2);
}
}
public final void m25558(String str) {
if (TextUtils.isEmpty(str)) {
return;
}
this.f22578 = str.trim();
}
public final String m25559() {
String str;
synchronized (this.f22587) {
str = this.f22557;
}
return str;
}
public final String m25560() {
String str;
synchronized (this.f22610) {
if (this.f22558 == null) {
m25561();
}
str = this.f22558;
}
return str;
}
public final void m25561() {
synchronized (this.f22610) {
this.f22558 = UUID.randomUUID().toString();
}
}
public final Map<String, String> m25562() {
synchronized (this.f22559) {
if (this.f22564.size() <= 0) {
return null;
}
return new HashMap(this.f22564);
}
}
public final String m25563() {
if (this.f22616 == null) {
String str = C5641.m25822();
this.f22616 = str;
C5612.m25712("ROM ID: %s", str);
}
return this.f22616;
}
public final synchronized String m25564() {
String str = this.f22583;
if (str != null) {
return str;
}
String m25838 = C5658.m25838("deviceModel", null);
this.f22583 = m25838;
if (m25838 != null) {
C5612.m25713("collect device model from sp:%s", m25838);
return this.f22583;
}
if (!this.f22576) {
C5612.m25713("not allow collect device model", new Object[0]);
return "fail";
}
String m25823 = C5641.m25823();
this.f22583 = m25823;
C5612.m25713("collect device model:%s", m25823);
C5658.m25854("deviceModel", this.f22583);
return this.f22583;
}
public final long m25565() {
if (this.f22567 <= 0) {
this.f22567 = C5641.m25816();
}
return this.f22567;
}
public final String m25566() {
try {
Map<String, ?> all = this.f22607.getSharedPreferences("BuglySdkInfos", 0).getAll();
if (!all.isEmpty()) {
synchronized (this.f22626) {
for (Map.Entry<String, ?> entry : all.entrySet()) {
try {
this.f22598.put(entry.getKey(), entry.getValue().toString());
} catch (Throwable th) {
C5612.m25717(th);
}
}
}
}
} catch (Throwable th2) {
C5612.m25717(th2);
}
if (this.f22598.isEmpty()) {
C5612.m25713("SDK_INFO is empty", new Object[0]);
return null;
}
StringBuilder sb = new StringBuilder();
for (Map.Entry<String, String> entry2 : this.f22598.entrySet()) {
sb.append("[");
sb.append(entry2.getKey());
sb.append(",");
sb.append(entry2.getValue());
sb.append("] ");
}
C5612.m25713("SDK_INFO = %s", sb.toString());
m25543("SDK_INFO", sb.toString());
return sb.toString();
}
public final void m25567() {
synchronized (this.f22605) {
this.f22582.clear();
}
}
public final synchronized Map<String, PlugInBean> m25568() {
Map<String, PlugInBean> map;
map = this.f22624;
Map<String, PlugInBean> map2 = this.f22604;
if (map2 != null) {
map.putAll(map2);
}
return map;
}
public final synchronized void m25569(String str) {
this.f22594 = String.valueOf(str);
}
public final void m25570(String str) {
C5612.m25712("change deviceModel,old:%s new:%s", this.f22583, str);
this.f22583 = str;
if (TextUtils.isEmpty(str)) {
return;
}
C5658.m25854("deviceModel", str);
}
public final long m25571() {
if (this.f22588 <= 0) {
this.f22588 = C5641.m25819();
}
return this.f22588;
}
public final String m25572(String str) {
String str2;
if (C5658.m25857(str)) {
C5612.m25716("key should not be empty %s", String.valueOf(str));
return null;
}
synchronized (this.f22605) {
str2 = this.f22582.get(str);
}
return str2;
}
public final String m25573() {
if (this.f22602 == null) {
this.f22602 = C5641.m25807();
}
return this.f22602;
}
public final void m25574(int i, boolean z) {
C5612.m25713("setActivityForeState, hash:%s isFore:%s", Integer.valueOf(i), Boolean.valueOf(z));
if (z) {
this.f22619.add(Integer.valueOf(i));
} else {
this.f22619.remove(Integer.valueOf(i));
this.f22619.remove((Object) 0);
}
InterfaceC5598 interfaceC5598 = this.f22565;
if (interfaceC5598 != null) {
interfaceC5598.mo24705(this.f22619.size() > 0);
}
}
public final String m25575() {
if (!TextUtils.isEmpty(this.f22578)) {
C5612.m25713("get cpu type from so:%s", this.f22578);
return this.f22578;
}
if (TextUtils.isEmpty(this.f22615)) {
return "unknown";
}
C5612.m25713("get cpu type from lib dir:%s", this.f22615);
return this.f22615;
}
public final Map<String, String> m25576() {
synchronized (this.f22605) {
if (this.f22582.size() <= 0) {
return null;
}
return new HashMap(this.f22582);
}
}
public final String m25577(String str) {
String remove;
if (C5658.m25857(str)) {
C5612.m25716("key should not be empty %s", String.valueOf(str));
return null;
}
synchronized (this.f22605) {
remove = this.f22582.remove(str);
}
return remove;
}
}