MainEntry.smali

.class public Lcom/keniu/security/MainEntry;
.super Lcom/keniu/security/InsetMainEntry;
.source "MainEntry.java"


# static fields
.field private static final TAG:Ljava/lang/String; = "MainEntry"

.field public static theApp:Lcom/keniu/security/MainEntry;


# instance fields
.field private mMoApp:Lcom/keniu/security/m;

.field private mSubDexsLoaded:Z


# direct methods
.method static constructor <clinit>()V
    .registers 1

    .prologue
    .line 69
    const/4 v0, 0x0

    sput-object v0, Lcom/keniu/security/MainEntry;->theApp:Lcom/keniu/security/MainEntry;

    return-void
.end method

.method public constructor <init>()V
    .registers 2

    .prologue
    .line 73
    invoke-direct {p0}, Lcom/keniu/security/InsetMainEntry;-><init>()V

    .line 70
    const/4 v0, 0x0

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    .line 71
    const/4 v0, 0x0

    iput-boolean v0, p0, Lcom/keniu/security/MainEntry;->mSubDexsLoaded:Z

    .line 74
    sput-object p0, Lcom/keniu/security/MainEntry;->theApp:Lcom/keniu/security/MainEntry;

    .line 75
    return-void
.end method

.method static synthetic access$000(Lcom/keniu/security/MainEntry;)V
    .registers 1

    .prologue
    .line 65
    invoke-direct {p0}, Lcom/keniu/security/MainEntry;->cmPushRegister()V

    return-void
.end method

.method private changeEULAAgreedState()V
    .registers 3

    .prologue
    .line 290
    :try_start_0
    invoke-static {}, Lcom/keniu/security/aj;->c()Z

    move-result v0

    if-eqz v0, :cond_7

    .line 305
    :cond_6
    :goto_6
    return-void

    .line 294
    :cond_7
    const v0, 0x77ce42dd

    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/Commons;->getChannelId()I

    move-result v1

    if-eq v0, v1, :cond_6

    const v0, 0x186a8

    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/Commons;->getChannelId()I

    move-result v1

    if-eq v0, v1, :cond_6

    .line 298
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/configmanager/UIConfigManager;->getInstanse(Landroid/content/Context;)Lcom/cleanmaster/hpsharelib/configmanager/UIConfigManager;

    move-result-object v0

    invoke-virtual {v0}, Lcom/cleanmaster/hpsharelib/configmanager/UIConfigManager;->isEULAAgreed()Z

    move-result v0

    if-nez v0, :cond_6

    .line 299
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/configmanager/UIConfigManager;->getInstanse(Landroid/content/Context;)Lcom/cleanmaster/hpsharelib/configmanager/UIConfigManager;

    move-result-object v0

    const/4 v1, 0x1

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/configmanager/UIConfigManager;->setUserAllowEULA(Z)V

    .line 300
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstanse(Landroid/content/Context;)Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;

    move-result-object v0

    const/4 v1, 0x1

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->setAllowEULA(Z)V
    :try_end_3f
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_3f} :catch_40

    goto :goto_6

    .line 302
    :catch_40
    move-exception v0

    .line 303
    invoke-virtual {v0}, Ljava/lang/Throwable;->printStackTrace()V

    goto :goto_6
.end method

.method private checkAutoStartPermissionState()V
    .registers 5

    .prologue
    .line 359
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->IsUIProcess()Z

    move-result v0

    if-nez v0, :cond_7

    .line 374
    :goto_6
    return-void

    .line 364
    :cond_7
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstanse(Landroid/content/Context;)Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;

    move-result-object v0

    invoke-virtual {v0}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getServiceAliveLastTimeStamp()J

    move-result-wide v0

    .line 365
    const-wide/16 v2, 0x0

    cmp-long v2, v0, v2

    if-nez v2, :cond_1d

    .line 366
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v0

    .line 368
    :cond_1d
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v2

    .line 369
    sub-long v0, v2, v0

    const-wide/32 v2, 0x493e0

    cmp-long v0, v0, v2

    if-lez v0, :cond_37

    .line 370
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstanse(Landroid/content/Context;)Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;

    move-result-object v0

    const/4 v1, 0x0

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->setAutoStartPermissionOpen(Z)V

    goto :goto_6

    .line 372
    :cond_37
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstanse(Landroid/content/Context;)Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;

    move-result-object v0

    const/4 v1, 0x1

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->setAutoStartPermissionOpen(Z)V

    goto :goto_6
.end method

.method private cmPushRegister()V
    .registers 4

    .prologue
    .line 242
    const/4 v0, 0x0

    invoke-static {v0}, Lcom/cmcm/sdk/push/api/CMPushSDK;->setDebug(Z)V

    .line 243
    const/4 v0, 0x1

    invoke-static {v0}, Lcom/cmcm/sdk/push/api/CMPushSDK;->setSupportMultiProcess(Z)V

    .line 245
    new-instance v0, Ljava/util/HashMap;

    invoke-direct {v0}, Ljava/util/HashMap;-><init>()V

    .line 247
    sget-object v1, Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;->XIAOMI:Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;

    sget-object v2, Lcom/cmcm/sdk/push/api/CMPushSDK$State;->ON:Lcom/cmcm/sdk/push/api/CMPushSDK$State;

    invoke-interface {v0, v1, v2}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    .line 249
    sget-object v1, Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;->HUAWEI:Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;

    sget-object v2, Lcom/cmcm/sdk/push/api/CMPushSDK$State;->AUTO:Lcom/cmcm/sdk/push/api/CMPushSDK$State;

    invoke-interface {v0, v1, v2}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    .line 251
    sget-object v1, Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;->OPPO:Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;

    sget-object v2, Lcom/cmcm/sdk/push/api/CMPushSDK$State;->AUTO:Lcom/cmcm/sdk/push/api/CMPushSDK$State;

    invoke-interface {v0, v1, v2}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    .line 252
    sget-object v1, Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;->VIVO:Lcom/cmcm/sdk/push/api/CMPushSDK$Platform;

    sget-object v2, Lcom/cmcm/sdk/push/api/CMPushSDK$State;->AUTO:Lcom/cmcm/sdk/push/api/CMPushSDK$State;

    invoke-interface {v0, v1, v2}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    .line 256
    invoke-direct {p0}, Lcom/keniu/security/MainEntry;->shouldRegister()Z

    move-result v1

    if-eqz v1, :cond_5c

    .line 258
    const-string v1, "com.keniu.security.update.push.mi.XiaomiPushMessageReceiver"

    invoke-static {v1}, Lcom/cmcm/sdk/push/api/CMPushSDK;->setBroadcastReceiverClassName(Ljava/lang/String;)V

    .line 259
    sget-object v1, Lcom/keniu/security/MainEntry;->theApp:Lcom/keniu/security/MainEntry;

    if-eqz v1, :cond_5b

    .line 260
    invoke-static {p0}, Lcom/cmcm/sdk/push/api/CMPushSDK;->getReportData(Landroid/content/Context;)Lcom/cmcm/sdk/push/bean/c;

    move-result-object v1

    .line 261
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/Commons;->getChannelId()I

    move-result v2

    invoke-static {v2}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Lcom/cmcm/sdk/push/bean/c;->a(Ljava/lang/String;)V

    .line 262
    invoke-static {}, Lcom/cm/reminder/b;->c()Z

    move-result v2

    if-eqz v2, :cond_54

    .line 263
    invoke-static {}, Lcom/cm/reminder/b;->d()Ljava/util/HashMap;

    move-result-object v2

    invoke-virtual {v1, v2}, Lcom/cmcm/sdk/push/bean/c;->a(Ljava/util/HashMap;)V

    .line 265
    :cond_54
    sget-object v1, Lcom/keniu/security/MainEntry;->theApp:Lcom/keniu/security/MainEntry;

    sget-object v2, Lcom/cmcm/sdk/push/api/CMPushSDK$Server;->DOMESTIC:Lcom/cmcm/sdk/push/api/CMPushSDK$Server;

    invoke-static {v1, v0, v2}, Lcom/cmcm/sdk/push/api/CMPushSDK;->register(Landroid/app/Application;Ljava/util/Map;Lcom/cmcm/sdk/push/api/CMPushSDK$Server;)V

    .line 270
    :cond_5b
    :goto_5b
    return-void

    .line 268
    :cond_5c
    invoke-virtual {p0}, Lcom/keniu/security/MainEntry;->getApplicationContext()Landroid/content/Context;

    move-result-object v1

    sget-object v2, Lcom/cmcm/sdk/push/api/CMPushSDK$Server;->DOMESTIC:Lcom/cmcm/sdk/push/api/CMPushSDK$Server;

    invoke-static {v1, v0, v2}, Lcom/cmcm/sdk/push/api/CMPushSDK;->addRegisteInfo(Landroid/content/Context;Ljava/util/Map;Lcom/cmcm/sdk/push/api/CMPushSDK$Server;)V

    goto :goto_5b
.end method

.method private initJacoco()V
    .registers 1

    .prologue
    .line 411
    return-void
.end method

.method private initMMKV(Landroid/content/Context;)V
    .registers 5

    .prologue
    .line 191
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {p1}, Landroid/content/Context;->getFilesDir()Ljava/io/File;

    move-result-object v1

    invoke-virtual {v1}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    const-string v1, "/mmkv"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    .line 192
    new-instance v1, Lcom/keniu/security/k;

    invoke-direct {v1, p0, p1}, Lcom/keniu/security/k;-><init>(Lcom/keniu/security/MainEntry;Landroid/content/Context;)V

    sget-object v2, Lcom/tencent/mmkv/MMKVLogLevel;->LevelInfo:Lcom/tencent/mmkv/MMKVLogLevel;

    invoke-static {v0, v1, v2}, Lcom/tencent/mmkv/MMKV;->initialize(Ljava/lang/String;Lcom/tencent/mmkv/MMKV$LibLoader;Lcom/tencent/mmkv/MMKVLogLevel;)Ljava/lang/String;

    .line 198
    return-void
.end method

.method private initStrictMode()V
    .registers 1

    .prologue
    .line 274
    return-void
.end method

.method private shouldRegister()Z
    .registers 2

    .prologue
    .line 377
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isUIProcess()Z

    move-result v0

    return v0
.end method


# virtual methods
.method protected attachBaseContext(Landroid/content/Context;)V
    .registers 5

    .prologue
    .line 79
    const-string v0, "MainEntry attachBaseContext"

    invoke-static {v0}, Landroid/os/Trace;->beginSection(Ljava/lang/String;)V

    .line 81
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/data/AppBootData;->setAppStartTime()V

    .line 85
    invoke-static {p1}, Lcom/cleanmaster/hpsharelib/crash/ProbeCrash;->Probe(Landroid/content/Context;)V

    .line 87
    invoke-super {p0, p1}, Lcom/keniu/security/InsetMainEntry;->attachBaseContext(Landroid/content/Context;)V

    .line 92
    invoke-virtual {p0, p1}, Lcom/keniu/security/MainEntry;->getProcessName(Landroid/content/Context;)Ljava/lang/String;

    move-result-object v0

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mProcName:Ljava/lang/String;

    .line 93
    const-string v0, "MainEntry"

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "new process "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    iget-object v2, p0, Lcom/keniu/security/MainEntry;->mProcName:Ljava/lang/String;

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    const-string v2, " created"

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-static {v0, v1}, Landroid/util/Log;->v(Ljava/lang/String;Ljava/lang/String;)I

    .line 95
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mProcName:Ljava/lang/String;

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->Init(Ljava/lang/String;)V

    .line 96
    invoke-virtual {p0, p1}, Lcom/keniu/security/MainEntry;->initCrashReport(Landroid/content/Context;)V

    .line 98
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/data/AppBootData;->setLoadSubdexStartTime()V

    .line 99
    invoke-static {p1}, Lcom/bytedance/boost_multidex/BoostMultiDex;->install(Landroid/content/Context;)Lcom/bytedance/boost_multidex/Result;

    .line 100
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/data/AppBootData;->setLoadSubdexEndTime()V

    .line 101
    invoke-direct {p0, p1}, Lcom/keniu/security/MainEntry;->initMMKV(Landroid/content/Context;)V

    .line 103
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mProcName:Ljava/lang/String;

    invoke-static {v0}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->init(Ljava/lang/String;)V

    .line 104
    invoke-direct {p0}, Lcom/keniu/security/MainEntry;->initStrictMode()V

    .line 106
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/ipc/ServiceManager;->getInstance()Lcom/cleanmaster/hpsharelib/base/ipc/ServiceManager;

    move-result-object v0

    sget-object v1, Lcom/cleanmaster/service/ax;->a:[Lcom/cleanmaster/hpsharelib/base/ipc/data/ServiceClassInfo;

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/base/ipc/ServiceManager;->registerServices([Lcom/cleanmaster/hpsharelib/base/ipc/data/ServiceClassInfo;)V

    .line 109
    :try_start_59
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isUIProcess()Z

    move-result v0

    if-eqz v0, :cond_84

    .line 110
    const-class v0, Lcom/keniu/security/ae;

    invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/keniu/security/m;

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;
    :try_end_71
    .catch Ljava/lang/ClassNotFoundException; {:try_start_59 .. :try_end_71} :catch_9d
    .catch Ljava/lang/InstantiationException; {:try_start_59 .. :try_end_71} :catch_bb
    .catch Ljava/lang/IllegalAccessException; {:try_start_59 .. :try_end_71} :catch_d9

    .line 130
    :goto_71
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    if-nez v0, :cond_10c

    .line 132
    const-string v0, "MainEntry"

    const-string v1, "CRITICAL EXCEPTION!! UNABLE INSTANCE MoSecurityApplication."

    invoke-static {v0, v1}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)I

    .line 133
    invoke-static {}, Landroid/os/Process;->myPid()I

    move-result v0

    invoke-static {v0}, Landroid/os/Process;->killProcess(I)V

    .line 175
    :goto_83
    return-void

    .line 111
    :cond_84
    :try_start_84
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isServiceProcess()Z

    move-result v0

    if-eqz v0, :cond_a2

    .line 112
    const-class v0, Lcom/keniu/security/z;

    invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/keniu/security/m;

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;
    :try_end_9c
    .catch Ljava/lang/ClassNotFoundException; {:try_start_84 .. :try_end_9c} :catch_9d
    .catch Ljava/lang/InstantiationException; {:try_start_84 .. :try_end_9c} :catch_bb
    .catch Ljava/lang/IllegalAccessException; {:try_start_84 .. :try_end_9c} :catch_d9

    goto :goto_71

    .line 122
    :catch_9d
    move-exception v0

    .line 123
    invoke-virtual {v0}, Ljava/lang/ClassNotFoundException;->printStackTrace()V

    goto :goto_71

    .line 113
    :cond_a2
    :try_start_a2
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isWorkerProcess()Z

    move-result v0

    if-eqz v0, :cond_c0

    .line 114
    const-class v0, Lcom/keniu/security/ak;

    invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/keniu/security/m;

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;
    :try_end_ba
    .catch Ljava/lang/ClassNotFoundException; {:try_start_a2 .. :try_end_ba} :catch_9d
    .catch Ljava/lang/InstantiationException; {:try_start_a2 .. :try_end_ba} :catch_bb
    .catch Ljava/lang/IllegalAccessException; {:try_start_a2 .. :try_end_ba} :catch_d9

    goto :goto_71

    .line 124
    :catch_bb
    move-exception v0

    .line 125
    invoke-virtual {v0}, Ljava/lang/InstantiationException;->printStackTrace()V

    goto :goto_71

    .line 115
    :cond_c0
    :try_start_c0
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isCrashProcess()Z

    move-result v0

    if-eqz v0, :cond_de

    .line 116
    const-class v0, Lcom/keniu/security/c;

    invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/keniu/security/m;

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;
    :try_end_d8
    .catch Ljava/lang/ClassNotFoundException; {:try_start_c0 .. :try_end_d8} :catch_9d
    .catch Ljava/lang/InstantiationException; {:try_start_c0 .. :try_end_d8} :catch_bb
    .catch Ljava/lang/IllegalAccessException; {:try_start_c0 .. :try_end_d8} :catch_d9

    goto :goto_71

    .line 126
    :catch_d9
    move-exception v0

    .line 127
    invoke-virtual {v0}, Ljava/lang/IllegalAccessException;->printStackTrace()V

    goto :goto_71

    .line 117
    :cond_de
    :try_start_de
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isDeamonProcess()Z

    move-result v0

    if-eqz v0, :cond_f8

    .line 118
    const-class v0, Lcom/keniu/security/e;

    invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/keniu/security/m;

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    goto/16 :goto_71

    .line 120
    :cond_f8
    const-class v0, Lcom/keniu/security/v;

    invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/keniu/security/m;

    iput-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;
    :try_end_10a
    .catch Ljava/lang/ClassNotFoundException; {:try_start_de .. :try_end_10a} :catch_9d
    .catch Ljava/lang/InstantiationException; {:try_start_de .. :try_end_10a} :catch_bb
    .catch Ljava/lang/IllegalAccessException; {:try_start_de .. :try_end_10a} :catch_d9

    goto/16 :goto_71

    .line 141
    :cond_10c
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-virtual {v0, p1}, Lcom/keniu/security/m;->b(Landroid/content/Context;)V

    .line 142
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    iget-object v1, p0, Lcom/keniu/security/MainEntry;->mProcName:Ljava/lang/String;

    invoke-virtual {v0, v1}, Lcom/keniu/security/m;->a(Ljava/lang/String;)V

    .line 144
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-virtual {v0, p0}, Lcom/keniu/security/m;->a(Landroid/app/Application;)V

    .line 146
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-static {v0}, Lorg/acdd/framework/ActivityRecorder;->registerActivityRecorder(Lorg/acdd/android/compat/IActivityRecorder;)V

    .line 147
    invoke-static {}, Lcom/cleanmaster/base/plugin/gv;->a()V

    .line 151
    :try_start_125
    sget-boolean v0, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->s_bIsReported:Z

    if-eqz v0, :cond_14f

    .line 152
    invoke-static {}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstance()Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;

    move-result-object v0

    invoke-virtual {v0}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstallReport()Z

    move-result v0

    if-nez v0, :cond_14f

    .line 153
    invoke-static {}, Lcom/keniu/security/aj;->c()Z

    move-result v0

    if-eqz v0, :cond_14f

    .line 154
    invoke-static {}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->getInstance()Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;

    move-result-object v0

    const/4 v1, 0x1

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/configmanager/ServiceConfigManager;->setInstallReport(Z)V

    .line 155
    new-instance v0, Lcom/cleanmaster/hpsharelib/report/cm_cn_install;

    invoke-direct {v0}, Lcom/cleanmaster/hpsharelib/report/cm_cn_install;-><init>()V

    sget-byte v1, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->nProcessReport:B

    invoke-virtual {v0, v1}, Lcom/cleanmaster/hpsharelib/report/cm_cn_install;->setProcess(B)Lcom/cleanmaster/hpsharelib/report/cm_cn_install;

    move-result-object v0

    invoke-virtual {v0}, Lcom/cleanmaster/hpsharelib/report/cm_cn_install;->report()V
    :try_end_14f
    .catch Ljava/lang/Error; {:try_start_125 .. :try_end_14f} :catch_17b

    .line 161
    :cond_14f
    :goto_14f
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/ijinshan/cloudconfig/init/CloudConfigEnv;->setApplicationContext(Landroid/content/Context;)V

    .line 162
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isServiceProcess()Z

    move-result v0

    if-eqz v0, :cond_169

    .line 167
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isUIProcess()Z

    move-result v1

    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isServiceProcess()Z

    move-result v2

    invoke-virtual {v0, v1, v2}, Lcom/keniu/security/m;->a(ZZ)V

    .line 170
    :cond_169
    invoke-static {}, Lcom/cleanmaster/e/a/a;->a()V

    .line 171
    invoke-static {}, Lcom/keniu/security/m;->d()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/cleanmaster/hpcommonlib/utils/PackageManagerWrapper;->init(Landroid/content/Context;)V

    .line 173
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/data/AppBootData;->setAttachBaseContextEndTime()V

    .line 174
    invoke-static {}, Landroid/os/Trace;->endSection()V

    goto/16 :goto_83

    .line 157
    :catch_17b
    move-exception v0

    goto :goto_14f
.end method

.method public getProcessName(Landroid/content/Context;)Ljava/lang/String;
    .registers 7

    .prologue
    .line 315
    new-instance v0, Ljava/io/File;

    const-string v1, "/proc/self/cmdline"

    invoke-direct {v0, v1}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 317
    invoke-virtual {v0}, Ljava/io/File;->exists()Z

    move-result v1

    if-eqz v1, :cond_41

    invoke-virtual {v0}, Ljava/io/File;->isDirectory()Z

    move-result v1

    if-nez v1, :cond_41

    .line 318
    const/4 v2, 0x0

    .line 320
    :try_start_14
    new-instance v1, Ljava/io/BufferedReader;

    new-instance v3, Ljava/io/InputStreamReader;

    new-instance v4, Ljava/io/FileInputStream;

    invoke-direct {v4, v0}, Ljava/io/FileInputStream;-><init>(Ljava/io/File;)V

    invoke-direct {v3, v4}, Ljava/io/InputStreamReader;-><init>(Ljava/io/InputStream;)V

    invoke-direct {v1, v3}, Ljava/io/BufferedReader;-><init>(Ljava/io/Reader;)V
    :try_end_23
    .catch Ljava/lang/Exception; {:try_start_14 .. :try_end_23} :catch_7b
    .catchall {:try_start_14 .. :try_end_23} :catchall_8b

    .line 321
    :try_start_23
    invoke-virtual {v1}, Ljava/io/BufferedReader;->readLine()Ljava/lang/String;

    move-result-object v0

    .line 323
    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v2

    if-nez v2, :cond_3c

    .line 324
    invoke-virtual {v0}, Ljava/lang/String;->trim()Ljava/lang/String;
    :try_end_30
    .catch Ljava/lang/Exception; {:try_start_23 .. :try_end_30} :catch_a1
    .catchall {:try_start_23 .. :try_end_30} :catchall_9e

    move-result-object v0

    .line 328
    if-eqz v1, :cond_36

    .line 330
    :try_start_33
    invoke-virtual {v1}, Ljava/io/BufferedReader;->close()V
    :try_end_36
    .catch Ljava/lang/Exception; {:try_start_33 .. :try_end_36} :catch_37

    .line 355
    :cond_36
    :goto_36
    return-object v0

    .line 331
    :catch_37
    move-exception v1

    .line 332
    invoke-virtual {v1}, Ljava/lang/Exception;->printStackTrace()V

    goto :goto_36

    .line 328
    :cond_3c
    if-eqz v1, :cond_41

    .line 330
    :try_start_3e
    invoke-virtual {v1}, Ljava/io/BufferedReader;->close()V
    :try_end_41
    .catch Ljava/lang/Exception; {:try_start_3e .. :try_end_41} :catch_76

    .line 338
    :cond_41
    :goto_41
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x15

    if-lt v0, v1, :cond_97

    .line 340
    const-string v0, "activity"

    invoke-virtual {p1, v0}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/app/ActivityManager;

    .line 341
    if-eqz v0, :cond_97

    .line 342
    invoke-virtual {v0}, Landroid/app/ActivityManager;->getRunningAppProcesses()Ljava/util/List;

    move-result-object v0

    .line 343
    if-eqz v0, :cond_97

    .line 344
    invoke-interface {v0}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v1

    :cond_5b
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v0

    if-eqz v0, :cond_97

    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/app/ActivityManager$RunningAppProcessInfo;

    .line 345
    iget v2, v0, Landroid/app/ActivityManager$RunningAppProcessInfo;->pid:I

    invoke-static {}, Landroid/os/Process;->myPid()I

    move-result v3

    if-ne v2, v3, :cond_5b

    .line 346
    iget-object v0, v0, Landroid/app/ActivityManager$RunningAppProcessInfo;->processName:Ljava/lang/String;

    invoke-virtual {v0}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v0

    goto :goto_36

    .line 331
    :catch_76
    move-exception v0

    .line 332
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    goto :goto_41

    .line 325
    :catch_7b
    move-exception v0

    move-object v1, v2

    .line 326
    :goto_7d
    :try_start_7d
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V
    :try_end_80
    .catchall {:try_start_7d .. :try_end_80} :catchall_9e

    .line 328
    if-eqz v1, :cond_41

    .line 330
    :try_start_82
    invoke-virtual {v1}, Ljava/io/BufferedReader;->close()V
    :try_end_85
    .catch Ljava/lang/Exception; {:try_start_82 .. :try_end_85} :catch_86

    goto :goto_41

    .line 331
    :catch_86
    move-exception v0

    .line 332
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    goto :goto_41

    .line 328
    :catchall_8b
    move-exception v0

    :goto_8c
    if-eqz v2, :cond_91

    .line 330
    :try_start_8e
    invoke-virtual {v2}, Ljava/io/BufferedReader;->close()V
    :try_end_91
    .catch Ljava/lang/Exception; {:try_start_8e .. :try_end_91} :catch_92

    .line 333
    :cond_91
    :goto_91
    throw v0

    .line 331
    :catch_92
    move-exception v1

    .line 332
    invoke-virtual {v1}, Ljava/lang/Exception;->printStackTrace()V

    goto :goto_91

    .line 355
    :cond_97
    invoke-virtual {p0}, Lcom/keniu/security/MainEntry;->getApplicationInfo()Landroid/content/pm/ApplicationInfo;

    move-result-object v0

    iget-object v0, v0, Landroid/content/pm/ApplicationInfo;->processName:Ljava/lang/String;

    goto :goto_36

    .line 328
    :catchall_9e
    move-exception v0

    move-object v2, v1

    goto :goto_8c

    .line 325
    :catch_a1
    move-exception v0

    goto :goto_7d
.end method

.method public getResources()Landroid/content/res/Resources;
    .registers 5

    .prologue
    const/high16 v2, 0x3f800000    # 1.0f

    .line 382
    invoke-super {p0}, Lcom/keniu/security/InsetMainEntry;->getResources()Landroid/content/res/Resources;

    move-result-object v0

    .line 383
    if-eqz v0, :cond_21

    invoke-virtual {v0}, Landroid/content/res/Resources;->getConfiguration()Landroid/content/res/Configuration;

    move-result-object v1

    iget v1, v1, Landroid/content/res/Configuration;->fontScale:F

    cmpl-float v1, v1, v2

    if-eqz v1, :cond_21

    .line 384
    invoke-virtual {v0}, Landroid/content/res/Resources;->getConfiguration()Landroid/content/res/Configuration;

    move-result-object v1

    .line 385
    iput v2, v1, Landroid/content/res/Configuration;->fontScale:F

    .line 386
    sget v2, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v3, 0x18

    if-lt v2, v3, :cond_22

    .line 387
    invoke-virtual {p0, v1}, Lcom/keniu/security/MainEntry;->createConfigurationContext(Landroid/content/res/Configuration;)Landroid/content/Context;

    .line 392
    :cond_21
    :goto_21
    return-object v0

    .line 389
    :cond_22
    invoke-virtual {v0}, Landroid/content/res/Resources;->getDisplayMetrics()Landroid/util/DisplayMetrics;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Landroid/content/res/Resources;->updateConfiguration(Landroid/content/res/Configuration;Landroid/util/DisplayMetrics;)V

    goto :goto_21
.end method

.method public initCrashReport(Landroid/content/Context;)V
    .registers 5

    .prologue
    .line 178
    invoke-static {}, Lcom/cleanmaster/base/crash/h;->e()Lcom/cleanmaster/base/crash/h;

    move-result-object v0

    invoke-virtual {v0, p1}, Lcom/cleanmaster/base/crash/h;->a(Landroid/content/Context;)V

    .line 180
    new-instance v0, Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;

    invoke-virtual {p1}, Landroid/content/Context;->getApplicationContext()Landroid/content/Context;

    move-result-object v1

    invoke-direct {v0, v1}, Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;-><init>(Landroid/content/Context;)V

    .line 181
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->isUIProcess()Z

    move-result v1

    invoke-virtual {v0, v1}, Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;->setUploadProcess(Z)Lcom/tencent/bugly/BuglyStrategy;

    .line 182
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/Commons;->getRealChannelId()I

    move-result v1

    invoke-static {v1}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;->setAppChannel(Ljava/lang/String;)Lcom/tencent/bugly/BuglyStrategy;

    .line 183
    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    invoke-static {}, Lcom/keniu/security/h;->c()I

    move-result v2

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v1

    const-string v2, "_"

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    const-string v2, "20200902214928"

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;->setAppVersion(Ljava/lang/String;)Lcom/tencent/bugly/BuglyStrategy;

    .line 184
    invoke-virtual {p1}, Landroid/content/Context;->getPackageName()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;->setAppPackageName(Ljava/lang/String;)Lcom/tencent/bugly/BuglyStrategy;

    .line 186
    invoke-static {p1, v0}, Lcom/tencent/bugly/crashreport/CrashReport;->initCrashReport(Landroid/content/Context;Lcom/tencent/bugly/crashreport/CrashReport$UserStrategy;)V

    .line 187
    invoke-static {p1}, Lcom/cleanmaster/hpsharelib/base/util/CommonUtils;->getAndroidId(Landroid/content/Context;)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Lcom/tencent/bugly/crashreport/CrashReport;->setUserId(Ljava/lang/String;)V

    .line 188
    return-void
.end method

.method public onConfigurationChanged(Landroid/content/res/Configuration;)V
    .registers 4

    .prologue
    .line 397
    iget v0, p1, Landroid/content/res/Configuration;->fontScale:F

    const/high16 v1, 0x3f800000    # 1.0f

    cmpl-float v0, v0, v1

    if-eqz v0, :cond_b

    .line 398
    invoke-virtual {p0}, Lcom/keniu/security/MainEntry;->getResources()Landroid/content/res/Resources;

    .line 400
    :cond_b
    invoke-super {p0, p1}, Lcom/keniu/security/InsetMainEntry;->onConfigurationChanged(Landroid/content/res/Configuration;)V

    .line 401
    return-void
.end method

.method public onCreate()V
    .registers 5

    .prologue
    .line 202
    const-string v0, "MainEntry onCreate"

    invoke-static {v0}, Landroid/os/Trace;->beginSection(Ljava/lang/String;)V

    .line 203
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/data/AppBootData;->setApp_OnCreate_StartTime()V

    .line 206
    invoke-static {}, Lcom/cleanmaster/hpsharelib/base/util/system/RuntimeCheck;->IsRebootProcess()Z

    move-result v0

    if-eqz v0, :cond_15

    .line 208
    invoke-static {p0}, Lcom/plug/e/a;->b(Landroid/content/Context;)V

    .line 209
    invoke-static {}, Lcom/ijinshan/pluginslive/plugin/upgrade/process/g;->b()V

    .line 239
    :goto_14
    return-void

    .line 213
    :cond_15
    invoke-super {p0}, Lcom/keniu/security/InsetMainEntry;->onCreate()V

    .line 214
    invoke-static {p0}, Lcom/keniu/security/a;->a(Landroid/content/Context;)V

    .line 220
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-virtual {v0}, Lcom/keniu/security/m;->h()V

    .line 221
    invoke-virtual {p0}, Lcom/keniu/security/MainEntry;->launchPluginUpdateService()V

    .line 222
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-virtual {v0}, Lcom/keniu/security/m;->a()V

    .line 224
    invoke-direct {p0}, Lcom/keniu/security/MainEntry;->changeEULAAgreedState()V

    .line 226
    invoke-direct {p0}, Lcom/keniu/security/MainEntry;->checkAutoStartPermissionState()V

    .line 227
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/AppBootManager;->checkUIProcessIsStartFromMainActivity()V

    .line 228
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/data/AppBootData;->setApp_OnCreate_EndTime()V

    .line 229
    invoke-static {}, Lcom/cleanmaster/hpsharelib/performance/appboot/AppBootManager;->recordAppBootInfo()V

    .line 230
    new-instance v0, Lcom/keniu/security/l;

    invoke-direct {v0, p0}, Lcom/keniu/security/l;-><init>(Lcom/keniu/security/MainEntry;)V

    sget-object v1, Ljava/util/concurrent/TimeUnit;->MINUTES:Ljava/util/concurrent/TimeUnit;

    const-wide/16 v2, 0x1

    .line 235
    invoke-virtual {v1, v2, v3}, Ljava/util/concurrent/TimeUnit;->toMillis(J)J

    move-result-wide v2

    .line 230
    invoke-static {v0, v2, v3}, Lcom/cleanmaster/base/util/concurrent/BackgroundThread;->postDelayed(Ljava/lang/Runnable;J)V

    .line 237
    invoke-direct {p0}, Lcom/keniu/security/MainEntry;->initJacoco()V

    .line 238
    invoke-static {}, Landroid/os/Trace;->endSection()V

    goto :goto_14
.end method

.method public onTerminate()V
    .registers 2

    .prologue
    .line 309
    invoke-super {p0}, Lcom/keniu/security/InsetMainEntry;->onTerminate()V

    .line 311
    iget-object v0, p0, Lcom/keniu/security/MainEntry;->mMoApp:Lcom/keniu/security/m;

    invoke-virtual {v0}, Lcom/keniu/security/m;->j()V

    .line 312
    return-void
.end method