- Added realracing3-community.apk (71.57 MB) - Removed 32-bit support (armeabi-v7a) - Only includes arm64-v8a libraries - Decompiled source code included - Added README-community.md with analysis
329 lines
13 KiB
Java
329 lines
13 KiB
Java
package com.ironsource;
|
|
|
|
import android.adservices.measurement.MeasurementManager;
|
|
import android.annotation.SuppressLint;
|
|
import android.content.Context;
|
|
import android.net.Uri;
|
|
import android.os.SystemClock;
|
|
import android.view.MotionEvent;
|
|
import com.ironsource.n3;
|
|
import com.ironsource.qf;
|
|
import com.ironsource.sdk.utils.Logger;
|
|
import com.ironsource.v8;
|
|
import java.util.concurrent.Executors;
|
|
import kotlin.NoWhenBranchMatchedException;
|
|
import kotlin.ResultKt;
|
|
import kotlin.Unit;
|
|
import kotlin.coroutines.Continuation;
|
|
import kotlin.coroutines.SafeContinuation;
|
|
import kotlin.coroutines.intrinsics.IntrinsicsKt__IntrinsicsJvmKt;
|
|
import kotlin.coroutines.intrinsics.IntrinsicsKt__IntrinsicsKt;
|
|
import kotlin.coroutines.jvm.internal.DebugMetadata;
|
|
import kotlin.coroutines.jvm.internal.DebugProbesKt;
|
|
import kotlin.coroutines.jvm.internal.SuspendLambda;
|
|
import kotlin.jvm.functions.Function2;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
import kotlin.jvm.internal.Intrinsics;
|
|
import kotlinx.coroutines.BuildersKt__BuildersKt;
|
|
import kotlinx.coroutines.CoroutineScope;
|
|
import org.json.JSONObject;
|
|
|
|
/* loaded from: classes2.dex */
|
|
public final class l3 {
|
|
public static final b a = new b(null);
|
|
private static final String b;
|
|
|
|
public static final class a {
|
|
private final String a;
|
|
private final qf.e b;
|
|
private final String c;
|
|
private final JSONObject d;
|
|
|
|
public a(String name, qf.e productType, String demandSourceName, JSONObject params) {
|
|
Intrinsics.checkNotNullParameter(name, "name");
|
|
Intrinsics.checkNotNullParameter(productType, "productType");
|
|
Intrinsics.checkNotNullParameter(demandSourceName, "demandSourceName");
|
|
Intrinsics.checkNotNullParameter(params, "params");
|
|
this.a = name;
|
|
this.b = productType;
|
|
this.c = demandSourceName;
|
|
this.d = params;
|
|
}
|
|
|
|
public static /* synthetic */ a a(a aVar, String str, qf.e eVar, String str2, JSONObject jSONObject, int i, Object obj) {
|
|
if ((i & 1) != 0) {
|
|
str = aVar.a;
|
|
}
|
|
if ((i & 2) != 0) {
|
|
eVar = aVar.b;
|
|
}
|
|
if ((i & 4) != 0) {
|
|
str2 = aVar.c;
|
|
}
|
|
if ((i & 8) != 0) {
|
|
jSONObject = aVar.d;
|
|
}
|
|
return aVar.a(str, eVar, str2, jSONObject);
|
|
}
|
|
|
|
public final a a(String name, qf.e productType, String demandSourceName, JSONObject params) {
|
|
Intrinsics.checkNotNullParameter(name, "name");
|
|
Intrinsics.checkNotNullParameter(productType, "productType");
|
|
Intrinsics.checkNotNullParameter(demandSourceName, "demandSourceName");
|
|
Intrinsics.checkNotNullParameter(params, "params");
|
|
return new a(name, productType, demandSourceName, params);
|
|
}
|
|
|
|
public final String a() {
|
|
return this.a;
|
|
}
|
|
|
|
public final qf.e b() {
|
|
return this.b;
|
|
}
|
|
|
|
public final String c() {
|
|
return this.c;
|
|
}
|
|
|
|
public final JSONObject d() {
|
|
return this.d;
|
|
}
|
|
|
|
public final String e() {
|
|
return this.c;
|
|
}
|
|
|
|
public boolean equals(Object obj) {
|
|
if (!(obj instanceof a)) {
|
|
return false;
|
|
}
|
|
if (this == obj) {
|
|
return true;
|
|
}
|
|
a aVar = (a) obj;
|
|
return Intrinsics.areEqual(this.a, aVar.a) && this.b == aVar.b && Intrinsics.areEqual(this.c, aVar.c) && Intrinsics.areEqual(this.d.toString(), aVar.d.toString());
|
|
}
|
|
|
|
public final String f() {
|
|
return this.a;
|
|
}
|
|
|
|
public final JSONObject g() {
|
|
return this.d;
|
|
}
|
|
|
|
public final qf.e h() {
|
|
return this.b;
|
|
}
|
|
|
|
public int hashCode() {
|
|
return super.hashCode();
|
|
}
|
|
|
|
public final JSONObject i() {
|
|
JSONObject put = new JSONObject(this.d.toString()).put(v8.h.m, this.b).put("demandSourceName", this.c);
|
|
Intrinsics.checkNotNullExpressionValue(put, "JSONObject(params.toStri…eName\", demandSourceName)");
|
|
return put;
|
|
}
|
|
|
|
public String toString() {
|
|
return "CallbackResult(name=" + this.a + ", productType=" + this.b + ", demandSourceName=" + this.c + ", params=" + this.d + ')';
|
|
}
|
|
}
|
|
|
|
public static final class b {
|
|
private b() {
|
|
}
|
|
|
|
public /* synthetic */ b(DefaultConstructorMarker defaultConstructorMarker) {
|
|
this();
|
|
}
|
|
}
|
|
|
|
@DebugMetadata(c = "com.ironsource.sdk.controller.androidSandbox.AndroidSandboxJSHandler$handleAttributionClick$1", f = "AndroidSandboxJSHandler.kt", l = {80}, m = "invokeSuspend")
|
|
public static final class c extends SuspendLambda implements Function2 {
|
|
int a;
|
|
final /* synthetic */ MeasurementManager c;
|
|
final /* synthetic */ Uri d;
|
|
final /* synthetic */ MotionEvent e;
|
|
|
|
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
|
|
public c(MeasurementManager measurementManager, Uri uri, MotionEvent motionEvent, Continuation continuation) {
|
|
super(2, continuation);
|
|
this.c = measurementManager;
|
|
this.d = uri;
|
|
this.e = motionEvent;
|
|
}
|
|
|
|
@Override // kotlin.jvm.functions.Function2
|
|
/* renamed from: a, reason: merged with bridge method [inline-methods] */
|
|
public final Object invoke(CoroutineScope coroutineScope, Continuation continuation) {
|
|
return ((c) create(coroutineScope, continuation)).invokeSuspend(Unit.INSTANCE);
|
|
}
|
|
|
|
@Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
|
|
public final Continuation create(Object obj, Continuation continuation) {
|
|
return l3.this.new c(this.c, this.d, this.e, continuation);
|
|
}
|
|
|
|
@Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
|
|
public final Object invokeSuspend(Object obj) {
|
|
Object coroutine_suspended;
|
|
coroutine_suspended = IntrinsicsKt__IntrinsicsKt.getCOROUTINE_SUSPENDED();
|
|
int i = this.a;
|
|
if (i == 0) {
|
|
ResultKt.throwOnFailure(obj);
|
|
l3 l3Var = l3.this;
|
|
MeasurementManager measurementManager = this.c;
|
|
Uri uri = this.d;
|
|
Intrinsics.checkNotNullExpressionValue(uri, "uri");
|
|
MotionEvent motionEvent = this.e;
|
|
this.a = 1;
|
|
if (l3Var.a(measurementManager, uri, motionEvent, this) == coroutine_suspended) {
|
|
return coroutine_suspended;
|
|
}
|
|
} else {
|
|
if (i != 1) {
|
|
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
|
|
}
|
|
ResultKt.throwOnFailure(obj);
|
|
}
|
|
return Unit.INSTANCE;
|
|
}
|
|
}
|
|
|
|
@DebugMetadata(c = "com.ironsource.sdk.controller.androidSandbox.AndroidSandboxJSHandler$handleAttributionImpression$1", f = "AndroidSandboxJSHandler.kt", l = {60}, m = "invokeSuspend")
|
|
public static final class d extends SuspendLambda implements Function2 {
|
|
int a;
|
|
final /* synthetic */ MeasurementManager c;
|
|
final /* synthetic */ Uri d;
|
|
|
|
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
|
|
public d(MeasurementManager measurementManager, Uri uri, Continuation continuation) {
|
|
super(2, continuation);
|
|
this.c = measurementManager;
|
|
this.d = uri;
|
|
}
|
|
|
|
@Override // kotlin.jvm.functions.Function2
|
|
/* renamed from: a, reason: merged with bridge method [inline-methods] */
|
|
public final Object invoke(CoroutineScope coroutineScope, Continuation continuation) {
|
|
return ((d) create(coroutineScope, continuation)).invokeSuspend(Unit.INSTANCE);
|
|
}
|
|
|
|
@Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
|
|
public final Continuation create(Object obj, Continuation continuation) {
|
|
return l3.this.new d(this.c, this.d, continuation);
|
|
}
|
|
|
|
@Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
|
|
public final Object invokeSuspend(Object obj) {
|
|
Object coroutine_suspended;
|
|
coroutine_suspended = IntrinsicsKt__IntrinsicsKt.getCOROUTINE_SUSPENDED();
|
|
int i = this.a;
|
|
if (i == 0) {
|
|
ResultKt.throwOnFailure(obj);
|
|
l3 l3Var = l3.this;
|
|
MeasurementManager measurementManager = this.c;
|
|
Uri uri = this.d;
|
|
Intrinsics.checkNotNullExpressionValue(uri, "uri");
|
|
this.a = 1;
|
|
if (l3Var.a(measurementManager, uri, null, this) == coroutine_suspended) {
|
|
return coroutine_suspended;
|
|
}
|
|
} else {
|
|
if (i != 1) {
|
|
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
|
|
}
|
|
ResultKt.throwOnFailure(obj);
|
|
}
|
|
return Unit.INSTANCE;
|
|
}
|
|
}
|
|
|
|
static {
|
|
String name = b.class.getName();
|
|
Intrinsics.checkNotNullExpressionValue(name, "this::class.java.name");
|
|
b = name;
|
|
}
|
|
|
|
private final a a(Context context, n3.a aVar) {
|
|
MeasurementManager a2 = g1.a(context);
|
|
if (a2 == null) {
|
|
Logger.i(b, "could not obtain measurement manager");
|
|
return a(aVar, "could not obtain measurement manager");
|
|
}
|
|
try {
|
|
if (aVar instanceof n3.a.b) {
|
|
return a(aVar, a2);
|
|
}
|
|
if (aVar instanceof n3.a.C0175a) {
|
|
return a((n3.a.C0175a) aVar, a2);
|
|
}
|
|
throw new NoWhenBranchMatchedException();
|
|
} catch (Exception e) {
|
|
i9.d().a(e);
|
|
return a(aVar, "failed to handle attribution, message: " + e.getMessage());
|
|
}
|
|
}
|
|
|
|
private final a a(n3.a.C0175a c0175a, MeasurementManager measurementManager) {
|
|
Uri parse = Uri.parse(c0175a.getUrl());
|
|
long uptimeMillis = SystemClock.uptimeMillis();
|
|
BuildersKt__BuildersKt.runBlocking$default(null, new c(measurementManager, parse, MotionEvent.obtain(uptimeMillis, uptimeMillis, c0175a.m(), c0175a.n().c(), c0175a.n().d(), c0175a.o()), null), 1, null);
|
|
return a(c0175a);
|
|
}
|
|
|
|
private final a a(n3.a aVar) {
|
|
JSONObject params = new JSONObject().put("params", new JSONObject().put("type", aVar instanceof n3.a.C0175a ? "click" : "impression"));
|
|
String c2 = aVar.c();
|
|
qf.e b2 = aVar.b();
|
|
String d2 = aVar.d();
|
|
Intrinsics.checkNotNullExpressionValue(params, "params");
|
|
return new a(c2, b2, d2, params);
|
|
}
|
|
|
|
private final a a(n3.a aVar, MeasurementManager measurementManager) {
|
|
BuildersKt__BuildersKt.runBlocking$default(null, new d(measurementManager, Uri.parse(aVar.getUrl()), null), 1, null);
|
|
return a(aVar);
|
|
}
|
|
|
|
private final a a(n3 n3Var, String str) {
|
|
JSONObject put = new JSONObject().put("reason", str).put("type", n3Var instanceof n3.a.C0175a ? "click" : "impression");
|
|
String a2 = n3Var.a();
|
|
qf.e b2 = n3Var.b();
|
|
String d2 = n3Var.d();
|
|
JSONObject put2 = new JSONObject().put("params", put);
|
|
Intrinsics.checkNotNullExpressionValue(put2, "JSONObject().put(\"params\", payload)");
|
|
return new a(a2, b2, d2, put2);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: private */
|
|
@SuppressLint({"NewApi"})
|
|
public final Object a(MeasurementManager measurementManager, Uri uri, MotionEvent motionEvent, Continuation continuation) {
|
|
Continuation intercepted;
|
|
Object coroutine_suspended;
|
|
Object coroutine_suspended2;
|
|
intercepted = IntrinsicsKt__IntrinsicsJvmKt.intercepted(continuation);
|
|
SafeContinuation safeContinuation = new SafeContinuation(intercepted);
|
|
measurementManager.registerSource(uri, motionEvent, Executors.newSingleThreadExecutor(), m3.a(safeContinuation));
|
|
Object orThrow = safeContinuation.getOrThrow();
|
|
coroutine_suspended = IntrinsicsKt__IntrinsicsKt.getCOROUTINE_SUSPENDED();
|
|
if (orThrow == coroutine_suspended) {
|
|
DebugProbesKt.probeCoroutineSuspended(continuation);
|
|
}
|
|
coroutine_suspended2 = IntrinsicsKt__IntrinsicsKt.getCOROUTINE_SUSPENDED();
|
|
return orThrow == coroutine_suspended2 ? orThrow : Unit.INSTANCE;
|
|
}
|
|
|
|
public final a a(Context context, n3 message) {
|
|
Intrinsics.checkNotNullParameter(context, "context");
|
|
Intrinsics.checkNotNullParameter(message, "message");
|
|
if (message instanceof n3.a) {
|
|
return a(context, (n3.a) message);
|
|
}
|
|
throw new NoWhenBranchMatchedException();
|
|
}
|
|
}
|