PicWish v1.6.8版本的 MD5 值为:7e8bab240f03cf6dad8952f8374c4ed1

以下内容为反编译后的 a2.java 源代码,内容仅作参考


package l6;

import android.content.Context;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
import android.content.res.Resources;
import android.os.Bundle;
import android.text.TextUtils;
import androidx.annotation.WorkerThread;
import androidx.constraintlayout.core.motion.utils.TypedValues;
import com.apowersoft.plugin.asm.privacy.AsmPrivacyHookHelper;
import java.math.BigInteger;
import java.util.Arrays;
import java.util.List;
import java.util.Locale;
import java.util.Objects;
import org.checkerframework.checker.nullness.qual.EnsuresNonNull;
public final class a2 extends n2 {
    public String A;
    public String f10188n;
    public String f10189o;
    public int p;
    public String f10190q;
    public long f10191r;
    public final long f10192s;
    public List f10193t;
    public String f10194u;
    public int f10195v;
    public String f10196w;
    public String f10197x;
    public String f10198y;
    public long f10199z;

    public a2(p3 p3Var, long j10) {
        super(p3Var);
        this.f10199z = 0L;
        this.A = null;
        this.f10192s = j10;
    }

    @Override
    public final boolean l() {
        return true;
    }

    @EnsuresNonNull({"appId", "appStore", "appName", "gmpAppId", "gaAppId"})
    @WorkerThread
    public final void m() {
        String str;
        boolean z10;
        int n10;
        List<String> list;
        Bundle t10;
        Integer valueOf;
        String M;
        String str2;
        String packageName = ((p3) this.f10277l).f10545l.getPackageName();
        PackageManager packageManager = ((p3) this.f10277l).f10545l.getPackageManager();
        String str3 = "unknown";
        String str4 = "Unknown";
        int i10 = Integer.MIN_VALUE;
        if (packageManager == null) {
            ((p3) this.f10277l).b().f10375q.b("PackageManager is null, app identity information might be inaccurate. appId", i2.u(packageName));
        } else {
            try {
                str3 = AsmPrivacyHookHelper.getInstallerPackageName(packageManager, packageName);
            } catch (IllegalArgumentException unused) {
                ((p3) this.f10277l).b().f10375q.b("Error retrieving app installer package name. appId", i2.u(packageName));
            }
            if (str3 == null) {
                str3 = "manual_install";
            } else if ("com.android.vending".equals(str3)) {
                str3 = "";
            }
            try {
                PackageInfo packageInfo = packageManager.getPackageInfo(((p3) this.f10277l).f10545l.getPackageName(), 0);
                if (packageInfo != null) {
                    CharSequence applicationLabel = packageManager.getApplicationLabel(packageInfo.applicationInfo);
                    String obj = !TextUtils.isEmpty(applicationLabel) ? applicationLabel.toString() : "Unknown";
                    try {
                        str4 = packageInfo.versionName;
                        i10 = packageInfo.versionCode;
                    } catch (PackageManager.NameNotFoundException unused2) {
                        str = str4;
                        str4 = obj;
                        ((p3) this.f10277l).b().f10375q.c("Error retrieving package info. appId, appName", i2.u(packageName), str4);
                        str4 = str;
                        this.f10188n = packageName;
                        this.f10190q = str3;
                        this.f10189o = str4;
                        this.p = i10;
                        this.f10191r = 0L;
                        if (TextUtils.isEmpty(((p3) this.f10277l).f10546m)) {
                        }
                        n10 = ((p3) this.f10277l).n();
                        switch (n10) {
                        }
                        this.f10196w = "";
                        this.f10197x = "";
                        Objects.requireNonNull((p3) this.f10277l);
                        if (z10) {
                        }
                        list = null;
                        g4 g4Var = this.f10277l;
                        M = m3.c.M(((p3) g4Var).f10545l, ((p3) g4Var).D);
                        this.f10196w = true != TextUtils.isEmpty(M) ? M : "";
                        if (!TextUtils.isEmpty(M)) {
                        }
                        if (n10 == 0) {
                        }
                        this.f10193t = null;
                        Objects.requireNonNull((p3) this.f10277l);
                        e eVar = ((p3) this.f10277l).f10550r;
                        Objects.requireNonNull(eVar);
                        h5.l.f("analytics.safelisted_events");
                        t10 = eVar.t();
                        if (t10 != null) {
                        }
                        valueOf = null;
                        if (valueOf != null) {
                        }
                        if (list != null) {
                        }
                        this.f10193t = list;
                        if (packageManager == null) {
                        }
                    }
                }
            } catch (PackageManager.NameNotFoundException unused3) {
                str = "Unknown";
            }
        }
        this.f10188n = packageName;
        this.f10190q = str3;
        this.f10189o = str4;
        this.p = i10;
        this.f10191r = 0L;
        z10 = TextUtils.isEmpty(((p3) this.f10277l).f10546m) && "am".equals(((p3) this.f10277l).f10547n);
        n10 = ((p3) this.f10277l).n();
        switch (n10) {
            case 0:
                ((p3) this.f10277l).b().f10383y.a("App measurement collection enabled");
                break;
            case 1:
                ((p3) this.f10277l).b().f10381w.a("App measurement deactivated via the manifest");
                break;
            case 2:
                ((p3) this.f10277l).b().f10383y.a("App measurement deactivated via the init parameters");
                break;
            case 3:
                ((p3) this.f10277l).b().f10381w.a("App measurement disabled by setAnalyticsCollectionEnabled(false)");
                break;
            case 4:
                ((p3) this.f10277l).b().f10381w.a("App measurement disabled via the manifest");
                break;
            case 5:
                ((p3) this.f10277l).b().f10383y.a("App measurement disabled via the init parameters");
                break;
            case 6:
                ((p3) this.f10277l).b().f10380v.a("App measurement deactivated via resources. This method is being deprecated. Please refer to https://firebase.google.com/support/guides/disable-analytics");
                break;
            case 7:
                ((p3) this.f10277l).b().f10381w.a("App measurement disabled via the global data collection setting");
                break;
            default:
                ((p3) this.f10277l).b().f10381w.a("App measurement disabled due to denied storage consent");
                break;
        }
        this.f10196w = "";
        this.f10197x = "";
        Objects.requireNonNull((p3) this.f10277l);
        if (z10) {
            this.f10197x = ((p3) this.f10277l).f10546m;
        }
        list = null;
        try {
            g4 g4Var2 = this.f10277l;
            M = m3.c.M(((p3) g4Var2).f10545l, ((p3) g4Var2).D);
            this.f10196w = true != TextUtils.isEmpty(M) ? M : "";
            if (!TextUtils.isEmpty(M)) {
                g4 g4Var3 = this.f10277l;
                Context context = ((p3) g4Var3).f10545l;
                String str5 = ((p3) g4Var3).D;
                h5.l.i(context);
                Resources resources = context.getResources();
                if (TextUtils.isEmpty(str5)) {
                    str5 = i3.a(context);
                }
                int identifier = resources.getIdentifier("admob_app_id", TypedValues.Custom.S_STRING, str5);
                if (identifier != 0) {
                    try {
                        str2 = resources.getString(identifier);
                    } catch (Resources.NotFoundException unused4) {
                        str2 = null;
                    }
                    this.f10197x = str2;
                }
                str2 = null;
                this.f10197x = str2;
            }
            if (n10 == 0) {
                ((p3) this.f10277l).b().f10383y.c("App measurement enabled for app package, google app id", this.f10188n, TextUtils.isEmpty(this.f10196w) ? this.f10197x : this.f10196w);
            }
        } catch (IllegalStateException e10) {
            ((p3) this.f10277l).b().f10375q.c("Fetching Google App Id failed with exception. appId", i2.u(packageName), e10);
        }
        this.f10193t = null;
        Objects.requireNonNull((p3) this.f10277l);
        e eVar2 = ((p3) this.f10277l).f10550r;
        Objects.requireNonNull(eVar2);
        h5.l.f("analytics.safelisted_events");
        t10 = eVar2.t();
        if (t10 != null) {
            ((p3) eVar2.f10277l).b().f10375q.a("Failed to load metadata: Metadata bundle is null");
        } else if (t10.containsKey("analytics.safelisted_events")) {
            valueOf = Integer.valueOf(t10.getInt("analytics.safelisted_events"));
            if (valueOf != null) {
                try {
                    String[] stringArray = ((p3) eVar2.f10277l).f10545l.getResources().getStringArray(valueOf.intValue());
                    if (stringArray != null) {
                        list = Arrays.asList(stringArray);
                    }
                } catch (Resources.NotFoundException e11) {
                    ((p3) eVar2.f10277l).b().f10375q.b("Failed to load string array from metadata: resource not found", e11);
                }
            }
            if (list != null) {
                if (list.isEmpty()) {
                    ((p3) this.f10277l).b().f10380v.a("Safelisted event list is empty. Ignoring");
                } else {
                    for (String str6 : list) {
                        if (!((p3) this.f10277l).B().Q("safelisted event", str6)) {
                        }
                    }
                }
                if (packageManager == null) {
                    this.f10195v = r5.a.a(((p3) this.f10277l).f10545l) ? 1 : 0;
                    return;
                } else {
                    this.f10195v = 0;
                    return;
                }
            }
            this.f10193t = list;
            if (packageManager == null) {
            }
        }
        valueOf = null;
        if (valueOf != null) {
        }
        if (list != null) {
        }
        this.f10193t = list;
        if (packageManager == null) {
        }
    }

    @WorkerThread
    public final String n() {
        j();
        h5.l.i(this.f10188n);
        return this.f10188n;
    }

    @WorkerThread
    public final String o() {
        i();
        j();
        h5.l.i(this.f10196w);
        return this.f10196w;
    }

    @WorkerThread
    public final void p() {
        String format;
        i();
        if (((p3) this.f10277l).u().q().f(f.ANALYTICS_STORAGE)) {
            byte[] bArr = new byte[16];
            ((p3) this.f10277l).B().u().nextBytes(bArr);
            format = String.format(Locale.US, "%032x", new BigInteger(1, bArr));
        } else {
            ((p3) this.f10277l).b().f10382x.a("Analytics Storage consent is not granted");
            format = null;
        }
        g2 g2Var = ((p3) this.f10277l).b().f10382x;
        Object[] objArr = new Object[1];
        objArr[0] = format == null ? "null" : "not null";
        g2Var.a(String.format("Resetting session stitching token to %s", objArr));
        this.f10198y = format;
        Objects.requireNonNull(((p3) this.f10277l).f10557y);
        this.f10199z = System.currentTimeMillis();
    }
}