导航菜单

页面标题

页面副标题

MedEd v5.3.6 - AFe1bSDK.java 源代码

正在查看: MedEd v5.3.6 应用的 AFe1bSDK.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package com.appsflyer.internal;

import android.util.Base64;
import com.appsflyer.AFLogger;
import defpackage.InterfaceC0165Xc1;
import defpackage.MW1;
import defpackage.Ob1;
import defpackage.le1;
import defpackage.yI;
import java.security.MessageDigest;
import java.util.Arrays;
import java.util.List;
import java.util.Locale;
import kotlin.Metadata;
import kotlin.jvm.functions.Function0;
import kotlin.jvm.internal.DefaultConstructorMarker;
import kotlin.jvm.internal.Intrinsics;
import kotlin.text.Charsets;
import kotlin.text.Regex;
import okhttp3.HttpUrl;

@Metadata
public final class AFe1bSDK {
    private static AFe1kSDK e;
    private final AFd1sSDK AFKeystoreWrapper;
    private final InterfaceC0165Xc1 unregisterClient;
    private final AFd1pSDK valueOf;
    public final InterfaceC0165Xc1 values;
    public static final AFa1ySDK AFa1ySDK = new AFa1ySDK(null);
    public static String AFInAppEventParameterName = "https://%scdn-%ssettings.%s/android/v1/%s/settings";
    public static String AFInAppEventType = "https://%scdn-%stestsettings.%s/android/v1/%s/settings";
    private static final List<String> registerClient = yI.m("googleplay", "playstore", "googleplaystore");

    @Metadata
    public static final class AnonymousClass2 extends Ob1 implements Function0<String> {
        public AnonymousClass2() {
            super(0);
        }

        @Override
        public final String invoke() {
            String packageName = AFe1bSDK.this.AFKeystoreWrapper.valueOf.AFKeystoreWrapper.getPackageName();
            Intrinsics.checkNotNullExpressionValue(packageName, "");
            return AFe1bSDK.values(packageName, AFe1bSDK.AFInAppEventParameterName(AFe1bSDK.this));
        }
    }

    @Metadata
    public static final class AnonymousClass5 extends Ob1 implements Function0<String> {
        public AnonymousClass5() {
            super(0);
        }

        @Override
        public final String invoke() {
            String AFInAppEventType = AFb1rSDK.AFInAppEventType(AFe1bSDK.this.valueOf, AFe1bSDK.this.AFKeystoreWrapper.AFLogger());
            String str = HttpUrl.FRAGMENT_ENCODE_SET;
            if (AFInAppEventType != null && !kotlin.text.j.E(AFInAppEventType)) {
                String obj = kotlin.text.j.b0(AFInAppEventType).toString();
                List<String> values = AFa1ySDK.values();
                Locale locale = Locale.getDefault();
                Intrinsics.checkNotNullExpressionValue(locale, "");
                String lowerCase = obj.toLowerCase(locale);
                Intrinsics.checkNotNullExpressionValue(lowerCase, "");
                if (values.contains(lowerCase)) {
                    String format = String.format("AF detected using redundant Google-Play channel for attribution - %s. Using without channel postfix.", Arrays.copyOf(new Object[]{obj}, 1));
                    Intrinsics.checkNotNullExpressionValue(format, "");
                    AFLogger.afWarnLog(format);
                    AFInAppEventType = HttpUrl.FRAGMENT_ENCODE_SET;
                } else {
                    AFInAppEventType = "-".concat(obj);
                }
            }
            if (AFInAppEventType != null) {
                str = AFInAppEventType;
            }
            return kotlin.text.j.b0(str).toString();
        }
    }

    public class AFa1tSDK {
        public static final int[] valueOf;

        static {
            int[] iArr = new int[AFe1cSDK.values().length];
            iArr[AFe1cSDK.DEFAULT.ordinal()] = 1;
            iArr[AFe1cSDK.API.ordinal()] = 2;
            iArr[AFe1cSDK.RC.ordinal()] = 3;
            valueOf = iArr;
        }
    }

    @Metadata
    public static final class AFa1ySDK {
        private AFa1ySDK() {
        }

        public AFa1ySDK(DefaultConstructorMarker defaultConstructorMarker) {
            this();
        }

        public static void AFInAppEventType(AFe1kSDK aFe1kSDK) {
            AFe1bSDK.e = aFe1kSDK;
        }

        public static List<String> values() {
            return AFe1bSDK.registerClient;
        }
    }

    public AFe1bSDK(AFd1sSDK aFd1sSDK, AFd1pSDK aFd1pSDK) {
        Intrinsics.checkNotNullParameter(aFd1sSDK, "");
        Intrinsics.checkNotNullParameter(aFd1pSDK, "");
        this.AFKeystoreWrapper = aFd1sSDK;
        this.valueOf = aFd1pSDK;
        this.unregisterClient = le1.b(new AnonymousClass5());
        this.values = le1.b(new AnonymousClass2());
    }

    public static final String AFInAppEventParameterName(AFe1bSDK aFe1bSDK) {
        return (String) aFe1bSDK.unregisterClient.getValue();
    }

    public static final void valueOf(AFe1kSDK aFe1kSDK) {
        AFa1ySDK.AFInAppEventType(aFe1kSDK);
    }

    public static final String values(String str, String str2) {
        StringBuilder sb = new StringBuilder();
        StringBuilder sb2 = new StringBuilder();
        sb2.append(str);
        sb2.append(str2);
        String obj = sb2.toString();
        Intrinsics.checkNotNullParameter(obj, "");
        MessageDigest messageDigest = MessageDigest.getInstance("SHA-256");
        byte[] bytes = obj.getBytes(Charsets.UTF_8);
        Intrinsics.checkNotNullExpressionValue(bytes, "");
        byte[] digest = messageDigest.digest(bytes);
        Intrinsics.checkNotNullExpressionValue(digest, "");
        String encodeToString = Base64.encodeToString(digest, 2);
        Intrinsics.checkNotNullExpressionValue(encodeToString, "");
        String lowerCase = encodeToString.toLowerCase(Locale.ROOT);
        Intrinsics.checkNotNullExpressionValue(lowerCase, "");
        String substring = new Regex("[^\\w]+").replace(lowerCase, HttpUrl.FRAGMENT_ENCODE_SET).substring(0, 6);
        Intrinsics.checkNotNullExpressionValue(substring, "");
        sb.append(substring);
        sb.append('-');
        return sb.toString();
    }

    public final String AFInAppEventType() {
        int i = AFa1tSDK.valueOf[(valueOf() ? AFe1cSDK.DEFAULT : AFe1cSDK.API).ordinal()];
        if (i == 1) {
            return "appsflyersdk.com";
        }
        if (i != 2) {
            if (i == 3) {
                return HttpUrl.FRAGMENT_ENCODE_SET;
            }
            throw new MW1();
        }
        AFe1kSDK aFe1kSDK = e;
        String str = aFe1kSDK != null ? aFe1kSDK.values : null;
        return str == null ? HttpUrl.FRAGMENT_ENCODE_SET : str;
    }

    public final String AFKeystoreWrapper() {
        int i = AFa1tSDK.valueOf[(valueOf() ? AFe1cSDK.DEFAULT : AFe1cSDK.API).ordinal()];
        if (i == 1) {
            return (String) this.values.getValue();
        }
        if (i != 2) {
            if (i == 3) {
                return HttpUrl.FRAGMENT_ENCODE_SET;
            }
            throw new MW1();
        }
        AFe1kSDK aFe1kSDK = e;
        String str = aFe1kSDK != null ? aFe1kSDK.AFInAppEventType : null;
        return str == null ? HttpUrl.FRAGMENT_ENCODE_SET : str;
    }

    public static boolean valueOf() {
        return e == null;
    }
}