正在查看: FanCode v7.24.0 应用的 AFe1gSDK.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: FanCode v7.24.0 应用的 AFe1gSDK.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.appsflyer.internal;
import android.util.Base64;
import com.appsflyer.AFLogger;
import com.connectsdk.service.webos.lgcast.common.utils.StringUtil;
import com.dream11sportsguru.BuildConfig;
import java.security.MessageDigest;
import java.util.Arrays;
import java.util.List;
import java.util.Locale;
import kotlin.Metadata;
import kotlin.NoWhenBranchMatchedException;
import kotlin.collections.CollectionsKt;
import kotlin.jvm.functions.Function0;
import kotlin.jvm.internal.DefaultConstructorMarker;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.StringCompanionObject;
import kotlin.text.Charsets;
import kotlin.text.Regex;
import kotlin.text.StringsKt;
import org.jetbrains.annotations.NotNull;
@Metadata
public final class AFe1gSDK {
private static AFe1jSDK component4;
@NotNull
public final rl.g AFAdRevenueData;
@NotNull
private final rl.g areAllFieldsValid;
@NotNull
private final AFd1pSDK getCurrencyIso4217Code;
@NotNull
private final AFd1rSDK getMonetizationNetwork;
@NotNull
public static final AFa1tSDK AFa1tSDK = new AFa1tSDK(null);
@NotNull
public static String getMediationNetwork = "https://%scdn-%ssettings.%s/android/v1/%s/settings";
@NotNull
public static String getRevenue = "https://%scdn-%stestsettings.%s/android/v1/%s/settings";
@NotNull
private static final List<String> component2 = CollectionsKt.n(new String[]{"googleplay", BuildConfig.androidChannelName, "googleplaystore"});
@Metadata
public static final class AFa1tSDK {
private AFa1tSDK() {
}
public AFa1tSDK(DefaultConstructorMarker defaultConstructorMarker) {
this();
}
@NotNull
public static List<String> AFAdRevenueData() {
return AFe1gSDK.component2;
}
public static void AFAdRevenueData(AFe1jSDK aFe1jSDK) {
AFe1gSDK.component4 = aFe1jSDK;
}
}
public class AFa1vSDK {
public static final int[] getRevenue;
static {
int[] iArr = new int[AFe1cSDK.values().length];
try {
iArr[AFe1cSDK.DEFAULT.ordinal()] = 1;
} catch (NoSuchFieldError unused) {
}
try {
iArr[AFe1cSDK.API.ordinal()] = 2;
} catch (NoSuchFieldError unused2) {
}
try {
iArr[AFe1cSDK.RC.ordinal()] = 3;
} catch (NoSuchFieldError unused3) {
}
getRevenue = iArr;
}
}
public AFe1gSDK(@NotNull AFd1rSDK aFd1rSDK, @NotNull AFd1pSDK aFd1pSDK) {
Intrinsics.checkNotNullParameter(aFd1rSDK, StringUtil.EMPTY);
Intrinsics.checkNotNullParameter(aFd1pSDK, StringUtil.EMPTY);
this.getMonetizationNetwork = aFd1rSDK;
this.getCurrencyIso4217Code = aFd1pSDK;
this.areAllFieldsValid = rl.h.a(new Function0<String>() {
{
super(0);
}
@NotNull
public final String invoke() {
String str = (String) AFb1rSDK.getRevenue(new Object[]{AFe1gSDK.this.getCurrencyIso4217Code, AFe1gSDK.this.getMonetizationNetwork.areAllFieldsValid()}, 983289703, -983289699, (int) System.currentTimeMillis());
boolean z9 = str == null || StringsKt.v(str);
String str2 = StringUtil.EMPTY;
if (!z9) {
String obj = StringsKt.O0(str).toString();
List<String> AFAdRevenueData = AFa1tSDK.AFAdRevenueData();
Locale locale = Locale.getDefault();
Intrinsics.checkNotNullExpressionValue(locale, StringUtil.EMPTY);
String lowerCase = obj.toLowerCase(locale);
Intrinsics.checkNotNullExpressionValue(lowerCase, StringUtil.EMPTY);
if (AFAdRevenueData.contains(lowerCase)) {
StringCompanionObject stringCompanionObject = StringCompanionObject.INSTANCE;
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, StringUtil.EMPTY);
AFLogger.afWarnLog(format);
str = StringUtil.EMPTY;
} else {
str = "-" + obj;
}
}
if (str != null) {
str2 = str;
}
return StringsKt.O0(str2).toString();
}
});
this.AFAdRevenueData = rl.h.a(new Function0<String>() {
{
super(0);
}
@NotNull
public final String invoke() {
String packageName = AFe1gSDK.this.getMonetizationNetwork.getMonetizationNetwork.getCurrencyIso4217Code.getPackageName();
Intrinsics.checkNotNullExpressionValue(packageName, StringUtil.EMPTY);
return AFe1gSDK.getCurrencyIso4217Code(packageName, AFe1gSDK.getRevenue(AFe1gSDK.this));
}
});
}
public static boolean getMediationNetwork() {
return component4 == null;
}
public static final String getRevenue(AFe1gSDK aFe1gSDK) {
return (String) aFe1gSDK.areAllFieldsValid.getValue();
}
public static final void getRevenue(AFe1jSDK aFe1jSDK) {
AFa1tSDK.AFAdRevenueData(aFe1jSDK);
}
@NotNull
public final String getCurrencyIso4217Code() {
int i9 = AFa1vSDK.getRevenue[(getMediationNetwork() ? AFe1cSDK.DEFAULT : AFe1cSDK.API).ordinal()];
if (i9 == 1) {
return "appsflyersdk.com";
}
if (i9 != 2) {
if (i9 == 3) {
return StringUtil.EMPTY;
}
throw new NoWhenBranchMatchedException();
}
AFe1jSDK aFe1jSDK = component4;
String str = aFe1jSDK != null ? aFe1jSDK.getCurrencyIso4217Code : null;
return str == null ? StringUtil.EMPTY : str;
}
@NotNull
public final String getMonetizationNetwork() {
int i9 = AFa1vSDK.getRevenue[(getMediationNetwork() ? AFe1cSDK.DEFAULT : AFe1cSDK.API).ordinal()];
if (i9 == 1) {
return (String) this.AFAdRevenueData.getValue();
}
if (i9 != 2) {
if (i9 == 3) {
return StringUtil.EMPTY;
}
throw new NoWhenBranchMatchedException();
}
AFe1jSDK aFe1jSDK = component4;
String str = aFe1jSDK != null ? aFe1jSDK.getMonetizationNetwork : null;
return str == null ? StringUtil.EMPTY : str;
}
public static final String getCurrencyIso4217Code(String str, String str2) {
String str3 = str + str2;
Intrinsics.checkNotNullParameter(str3, StringUtil.EMPTY);
MessageDigest messageDigest = MessageDigest.getInstance("SHA-256");
byte[] bytes = str3.getBytes(Charsets.UTF_8);
Intrinsics.checkNotNullExpressionValue(bytes, StringUtil.EMPTY);
byte[] digest = messageDigest.digest(bytes);
Intrinsics.checkNotNullExpressionValue(digest, StringUtil.EMPTY);
String encodeToString = Base64.encodeToString(digest, 2);
Intrinsics.checkNotNullExpressionValue(encodeToString, StringUtil.EMPTY);
String lowerCase = encodeToString.toLowerCase(Locale.ROOT);
Intrinsics.checkNotNullExpressionValue(lowerCase, StringUtil.EMPTY);
String substring = new Regex("[^\\w]+").replace(lowerCase, StringUtil.EMPTY).substring(0, 6);
Intrinsics.checkNotNullExpressionValue(substring, StringUtil.EMPTY);
return substring + "-";
}
}