Primer paso de la investigacion. Se aportan el .apk, las carpetas con el apk extraido y el apk descompilado. El archivo API_DOCUMENTATION.md es un archivo donde se anotaran los descubrimientos del funcionamiento de la API, y los .py son scripts para probar la funcionalidad de la API con los métodos que vayamos encontrando. Finalmente, los archivos .js son scripts de Frida para extraer informacion de la APP durante la ejecucion.
This commit is contained in:
54
apk_decompiled/sources/K0/a.java
Normal file
54
apk_decompiled/sources/K0/a.java
Normal file
@@ -0,0 +1,54 @@
|
||||
package K0;
|
||||
|
||||
import android.os.StatFs;
|
||||
import com.google.firebase.remoteconfig.FirebaseRemoteConfig;
|
||||
import java.io.File;
|
||||
import kotlin.ranges.RangesKt;
|
||||
import kotlinx.coroutines.CoroutineDispatcher;
|
||||
import kotlinx.coroutines.Dispatchers;
|
||||
import r3.n;
|
||||
import r3.u;
|
||||
import r3.z;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class a {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public z f974a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final u f975b = n.f8299a;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public double f976c = 0.02d;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public final long f977d = 10485760;
|
||||
|
||||
/* renamed from: e, reason: collision with root package name */
|
||||
public final long f978e = 262144000;
|
||||
|
||||
/* renamed from: f, reason: collision with root package name */
|
||||
public final CoroutineDispatcher f979f = Dispatchers.getIO();
|
||||
|
||||
public final j a() {
|
||||
long j4;
|
||||
z zVar = this.f974a;
|
||||
if (zVar == null) {
|
||||
throw new IllegalStateException("directory == null");
|
||||
}
|
||||
if (this.f976c > FirebaseRemoteConfig.DEFAULT_VALUE_FOR_DOUBLE) {
|
||||
try {
|
||||
File e4 = zVar.e();
|
||||
e4.mkdir();
|
||||
StatFs statFs = new StatFs(e4.getAbsolutePath());
|
||||
j4 = RangesKt.coerceIn((long) (this.f976c * statFs.getBlockCountLong() * statFs.getBlockSizeLong()), this.f977d, this.f978e);
|
||||
} catch (Exception unused) {
|
||||
j4 = this.f977d;
|
||||
}
|
||||
} else {
|
||||
j4 = 0;
|
||||
}
|
||||
return new j(j4, this.f979f, this.f975b, zVar);
|
||||
}
|
||||
}
|
||||
66
apk_decompiled/sources/K0/b.java
Normal file
66
apk_decompiled/sources/K0/b.java
Normal file
@@ -0,0 +1,66 @@
|
||||
package K0;
|
||||
|
||||
import kotlin.Unit;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
import r3.z;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class b {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final c f980a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public boolean f981b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public final boolean[] f982c;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public final /* synthetic */ g f983d;
|
||||
|
||||
public b(g gVar, c cVar) {
|
||||
this.f983d = gVar;
|
||||
this.f980a = cVar;
|
||||
gVar.getClass();
|
||||
this.f982c = new boolean[2];
|
||||
}
|
||||
|
||||
public final void a(boolean z3) {
|
||||
g gVar = this.f983d;
|
||||
synchronized (gVar) {
|
||||
try {
|
||||
if (this.f981b) {
|
||||
throw new IllegalStateException("editor is closed");
|
||||
}
|
||||
if (Intrinsics.areEqual(this.f980a.f990g, this)) {
|
||||
g.d(gVar, this, z3);
|
||||
}
|
||||
this.f981b = true;
|
||||
Unit unit = Unit.INSTANCE;
|
||||
} catch (Throwable th) {
|
||||
throw th;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public final z b(int i) {
|
||||
z zVar;
|
||||
g gVar = this.f983d;
|
||||
synchronized (gVar) {
|
||||
if (this.f981b) {
|
||||
throw new IllegalStateException("editor is closed");
|
||||
}
|
||||
this.f982c[i] = true;
|
||||
Object obj = this.f980a.f987d.get(i);
|
||||
e eVar = gVar.p;
|
||||
z file = (z) obj;
|
||||
if (!eVar.c(file)) {
|
||||
Intrinsics.checkNotNullParameter(file, "file");
|
||||
W0.f.a(eVar.g(file));
|
||||
}
|
||||
zVar = (z) obj;
|
||||
}
|
||||
return zVar;
|
||||
}
|
||||
}
|
||||
79
apk_decompiled/sources/K0/c.java
Normal file
79
apk_decompiled/sources/K0/c.java
Normal file
@@ -0,0 +1,79 @@
|
||||
package K0;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import r3.z;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class c {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final String f984a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final long[] f985b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public final ArrayList f986c;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public final ArrayList f987d;
|
||||
|
||||
/* renamed from: e, reason: collision with root package name */
|
||||
public boolean f988e;
|
||||
|
||||
/* renamed from: f, reason: collision with root package name */
|
||||
public boolean f989f;
|
||||
|
||||
/* renamed from: g, reason: collision with root package name */
|
||||
public b f990g;
|
||||
public int h;
|
||||
public final /* synthetic */ g i;
|
||||
|
||||
public c(g gVar, String str) {
|
||||
this.i = gVar;
|
||||
this.f984a = str;
|
||||
gVar.getClass();
|
||||
this.f985b = new long[2];
|
||||
gVar.getClass();
|
||||
this.f986c = new ArrayList(2);
|
||||
gVar.getClass();
|
||||
this.f987d = new ArrayList(2);
|
||||
StringBuilder sb = new StringBuilder(str);
|
||||
sb.append('.');
|
||||
int length = sb.length();
|
||||
gVar.getClass();
|
||||
for (int i = 0; i < 2; i++) {
|
||||
sb.append(i);
|
||||
this.f986c.add(this.i.f997a.d(sb.toString()));
|
||||
sb.append(".tmp");
|
||||
this.f987d.add(this.i.f997a.d(sb.toString()));
|
||||
sb.setLength(length);
|
||||
}
|
||||
}
|
||||
|
||||
public final d a() {
|
||||
if (this.f988e && this.f990g == null && !this.f989f) {
|
||||
ArrayList arrayList = this.f986c;
|
||||
int size = arrayList.size();
|
||||
int i = 0;
|
||||
while (true) {
|
||||
g gVar = this.i;
|
||||
if (i >= size) {
|
||||
this.h++;
|
||||
return new d(gVar, this);
|
||||
}
|
||||
if (gVar.p.c((z) arrayList.get(i))) {
|
||||
i++;
|
||||
} else {
|
||||
try {
|
||||
gVar.d0(this);
|
||||
return null;
|
||||
} catch (IOException unused) {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
42
apk_decompiled/sources/K0/d.java
Normal file
42
apk_decompiled/sources/K0/d.java
Normal file
@@ -0,0 +1,42 @@
|
||||
package K0;
|
||||
|
||||
import java.io.Closeable;
|
||||
import kotlin.Unit;
|
||||
import kotlin.text.Regex;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class d implements Closeable {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final c f991a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public boolean f992b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public final /* synthetic */ g f993c;
|
||||
|
||||
public d(g gVar, c cVar) {
|
||||
this.f993c = gVar;
|
||||
this.f991a = cVar;
|
||||
}
|
||||
|
||||
@Override // java.io.Closeable, java.lang.AutoCloseable
|
||||
public final void close() {
|
||||
if (this.f992b) {
|
||||
return;
|
||||
}
|
||||
this.f992b = true;
|
||||
g gVar = this.f993c;
|
||||
synchronized (gVar) {
|
||||
c cVar = this.f991a;
|
||||
int i = cVar.h - 1;
|
||||
cVar.h = i;
|
||||
if (i == 0 && cVar.f989f) {
|
||||
Regex regex = g.f996q;
|
||||
gVar.d0(cVar);
|
||||
}
|
||||
Unit unit = Unit.INSTANCE;
|
||||
}
|
||||
}
|
||||
}
|
||||
129
apk_decompiled/sources/K0/e.java
Normal file
129
apk_decompiled/sources/K0/e.java
Normal file
@@ -0,0 +1,129 @@
|
||||
package K0;
|
||||
|
||||
import com.adif.elcanomovil.commonNavGraph.arguments.NavArguments;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import kotlin.collections.ArrayDeque;
|
||||
import kotlin.collections.CollectionsKt;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
import kotlin.jvm.internal.Reflection;
|
||||
import r3.G;
|
||||
import r3.I;
|
||||
import r3.m;
|
||||
import r3.n;
|
||||
import r3.u;
|
||||
import r3.z;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class e extends n {
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final u f994b;
|
||||
|
||||
public e(u delegate) {
|
||||
Intrinsics.checkNotNullParameter(delegate, "delegate");
|
||||
this.f994b = delegate;
|
||||
}
|
||||
|
||||
public static void j(z path, String functionName, String parameterName) {
|
||||
Intrinsics.checkNotNullParameter(path, "path");
|
||||
Intrinsics.checkNotNullParameter(functionName, "functionName");
|
||||
Intrinsics.checkNotNullParameter(parameterName, "parameterName");
|
||||
}
|
||||
|
||||
@Override // r3.n
|
||||
public final void a(z path) {
|
||||
Intrinsics.checkNotNullParameter(path, "path");
|
||||
j(path, "delete", NavArguments.ARG_DYNAMIC_LINKS_TAB);
|
||||
this.f994b.a(path);
|
||||
}
|
||||
|
||||
@Override // r3.n
|
||||
public final List d(z dir) {
|
||||
Intrinsics.checkNotNullParameter(dir, "dir");
|
||||
j(dir, "list", "dir");
|
||||
List<z> d4 = this.f994b.d(dir);
|
||||
ArrayList arrayList = new ArrayList();
|
||||
for (z path : d4) {
|
||||
Intrinsics.checkNotNullParameter(path, "path");
|
||||
Intrinsics.checkNotNullParameter("list", "functionName");
|
||||
arrayList.add(path);
|
||||
}
|
||||
CollectionsKt.sort(arrayList);
|
||||
return arrayList;
|
||||
}
|
||||
|
||||
@Override // r3.n
|
||||
public final m f(z path) {
|
||||
Intrinsics.checkNotNullParameter(path, "path");
|
||||
j(path, "metadataOrNull", NavArguments.ARG_DYNAMIC_LINKS_TAB);
|
||||
m f2 = this.f994b.f(path);
|
||||
if (f2 == null) {
|
||||
return null;
|
||||
}
|
||||
z path2 = (z) f2.f8295d;
|
||||
if (path2 == null) {
|
||||
return f2;
|
||||
}
|
||||
Intrinsics.checkNotNullParameter(path2, "path");
|
||||
Intrinsics.checkNotNullParameter("metadataOrNull", "functionName");
|
||||
Map extras = (Map) f2.i;
|
||||
Intrinsics.checkNotNullParameter(extras, "extras");
|
||||
return new m(f2.f8293b, f2.f8294c, path2, (Long) f2.f8296e, (Long) f2.f8297f, (Long) f2.f8298g, (Long) f2.h, extras);
|
||||
}
|
||||
|
||||
@Override // r3.n
|
||||
public final G g(z file) {
|
||||
m f2;
|
||||
z dir = file.b();
|
||||
if (dir != null) {
|
||||
Intrinsics.checkNotNullParameter(dir, "dir");
|
||||
Intrinsics.checkNotNullParameter(dir, "dir");
|
||||
Intrinsics.checkNotNullParameter(this, "<this>");
|
||||
Intrinsics.checkNotNullParameter(dir, "dir");
|
||||
ArrayDeque arrayDeque = new ArrayDeque();
|
||||
while (dir != null && !c(dir)) {
|
||||
arrayDeque.addFirst(dir);
|
||||
dir = dir.b();
|
||||
}
|
||||
Iterator<E> it = arrayDeque.iterator();
|
||||
while (it.hasNext()) {
|
||||
z dir2 = (z) it.next();
|
||||
Intrinsics.checkNotNullParameter(dir2, "dir");
|
||||
Intrinsics.checkNotNullParameter(dir2, "dir");
|
||||
j(dir2, "createDirectory", "dir");
|
||||
u uVar = this.f994b;
|
||||
uVar.getClass();
|
||||
Intrinsics.checkNotNullParameter(dir2, "dir");
|
||||
if (!dir2.e().mkdir() && ((f2 = uVar.f(dir2)) == null || !f2.f8294c)) {
|
||||
throw new IOException("failed to create directory: " + dir2);
|
||||
}
|
||||
}
|
||||
}
|
||||
Intrinsics.checkNotNullParameter(file, "file");
|
||||
j(file, "sink", "file");
|
||||
return this.f994b.g(file);
|
||||
}
|
||||
|
||||
@Override // r3.n
|
||||
public final I h(z file) {
|
||||
Intrinsics.checkNotNullParameter(file, "file");
|
||||
j(file, "source", "file");
|
||||
return this.f994b.h(file);
|
||||
}
|
||||
|
||||
public final void i(z source, z target) {
|
||||
Intrinsics.checkNotNullParameter(source, "source");
|
||||
Intrinsics.checkNotNullParameter(target, "target");
|
||||
j(source, "atomicMove", "source");
|
||||
j(target, "atomicMove", "target");
|
||||
this.f994b.i(source, target);
|
||||
}
|
||||
|
||||
public final String toString() {
|
||||
return Reflection.getOrCreateKotlinClass(e.class).getSimpleName() + '(' + this.f994b + ')';
|
||||
}
|
||||
}
|
||||
61
apk_decompiled/sources/K0/f.java
Normal file
61
apk_decompiled/sources/K0/f.java
Normal file
@@ -0,0 +1,61 @@
|
||||
package K0;
|
||||
|
||||
import a.AbstractC0105a;
|
||||
import java.io.IOException;
|
||||
import kotlin.ResultKt;
|
||||
import kotlin.Unit;
|
||||
import kotlin.coroutines.Continuation;
|
||||
import kotlin.coroutines.intrinsics.IntrinsicsKt;
|
||||
import kotlin.coroutines.jvm.internal.SuspendLambda;
|
||||
import kotlin.jvm.functions.Function2;
|
||||
import kotlinx.coroutines.CoroutineScope;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class f extends SuspendLambda implements Function2 {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final /* synthetic */ g f995a;
|
||||
|
||||
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
|
||||
public f(g gVar, Continuation continuation) {
|
||||
super(2, continuation);
|
||||
this.f995a = gVar;
|
||||
}
|
||||
|
||||
@Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
|
||||
public final Continuation create(Object obj, Continuation continuation) {
|
||||
return new f(this.f995a, continuation);
|
||||
}
|
||||
|
||||
@Override // kotlin.jvm.functions.Function2
|
||||
public final Object invoke(Object obj, Object obj2) {
|
||||
return ((f) create((CoroutineScope) obj, (Continuation) obj2)).invokeSuspend(Unit.INSTANCE);
|
||||
}
|
||||
|
||||
/* JADX WARN: Type inference failed for: r3v6, types: [java.lang.Object, r3.G] */
|
||||
@Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
|
||||
public final Object invokeSuspend(Object obj) {
|
||||
IntrinsicsKt.getCOROUTINE_SUSPENDED();
|
||||
ResultKt.throwOnFailure(obj);
|
||||
g gVar = this.f995a;
|
||||
synchronized (gVar) {
|
||||
if (!gVar.f1006l || gVar.f1007m) {
|
||||
return Unit.INSTANCE;
|
||||
}
|
||||
try {
|
||||
gVar.e0();
|
||||
} catch (IOException unused) {
|
||||
gVar.f1008n = true;
|
||||
}
|
||||
try {
|
||||
if (gVar.i >= 2000) {
|
||||
gVar.g0();
|
||||
}
|
||||
} catch (IOException unused2) {
|
||||
gVar.f1009o = true;
|
||||
gVar.f1004j = AbstractC0105a.c(new Object());
|
||||
}
|
||||
return Unit.INSTANCE;
|
||||
}
|
||||
}
|
||||
}
|
||||
617
apk_decompiled/sources/K0/g.java
Normal file
617
apk_decompiled/sources/K0/g.java
Normal file
@@ -0,0 +1,617 @@
|
||||
package K0;
|
||||
|
||||
import a.AbstractC0105a;
|
||||
import java.io.Closeable;
|
||||
import java.io.File;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.Flushable;
|
||||
import java.io.IOException;
|
||||
import java.util.Iterator;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.logging.Logger;
|
||||
import kotlin.ExceptionsKt;
|
||||
import kotlin.Unit;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
import kotlin.text.Regex;
|
||||
import kotlin.text.StringsKt;
|
||||
import kotlin.text.Typography;
|
||||
import kotlinx.coroutines.BuildersKt;
|
||||
import kotlinx.coroutines.CoroutineDispatcher;
|
||||
import kotlinx.coroutines.CoroutineScope;
|
||||
import kotlinx.coroutines.CoroutineScopeKt;
|
||||
import kotlinx.coroutines.Job;
|
||||
import kotlinx.coroutines.SupervisorKt;
|
||||
import r3.B;
|
||||
import r3.u;
|
||||
import r3.w;
|
||||
import r3.y;
|
||||
import r3.z;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class g implements Closeable, Flushable {
|
||||
|
||||
/* renamed from: q, reason: collision with root package name */
|
||||
public static final Regex f996q = new Regex("[a-z0-9_-]{1,120}");
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final z f997a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final long f998b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public final z f999c;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public final z f1000d;
|
||||
|
||||
/* renamed from: e, reason: collision with root package name */
|
||||
public final z f1001e;
|
||||
|
||||
/* renamed from: f, reason: collision with root package name */
|
||||
public final LinkedHashMap f1002f;
|
||||
|
||||
/* renamed from: g, reason: collision with root package name */
|
||||
public final CoroutineScope f1003g;
|
||||
public long h;
|
||||
public int i;
|
||||
|
||||
/* renamed from: j, reason: collision with root package name */
|
||||
public B f1004j;
|
||||
|
||||
/* renamed from: k, reason: collision with root package name */
|
||||
public boolean f1005k;
|
||||
|
||||
/* renamed from: l, reason: collision with root package name */
|
||||
public boolean f1006l;
|
||||
|
||||
/* renamed from: m, reason: collision with root package name */
|
||||
public boolean f1007m;
|
||||
|
||||
/* renamed from: n, reason: collision with root package name */
|
||||
public boolean f1008n;
|
||||
|
||||
/* renamed from: o, reason: collision with root package name */
|
||||
public boolean f1009o;
|
||||
public final e p;
|
||||
|
||||
public g(long j4, CoroutineDispatcher coroutineDispatcher, u uVar, z zVar) {
|
||||
this.f997a = zVar;
|
||||
this.f998b = j4;
|
||||
if (j4 <= 0) {
|
||||
throw new IllegalArgumentException("maxSize <= 0");
|
||||
}
|
||||
this.f999c = zVar.d("journal");
|
||||
this.f1000d = zVar.d("journal.tmp");
|
||||
this.f1001e = zVar.d("journal.bkp");
|
||||
this.f1002f = new LinkedHashMap(0, 0.75f, true);
|
||||
this.f1003g = CoroutineScopeKt.CoroutineScope(SupervisorKt.SupervisorJob$default((Job) null, 1, (Object) null).plus(coroutineDispatcher.limitedParallelism(1)));
|
||||
this.p = new e(uVar);
|
||||
}
|
||||
|
||||
/* JADX WARN: Code restructure failed: missing block: B:56:0x011a, code lost:
|
||||
|
||||
if ((r9.i >= 2000) != false) goto L58;
|
||||
*/
|
||||
/* JADX WARN: Removed duplicated region for block: B:53:0x0113 A[Catch: all -> 0x0031, TryCatch #0 {, blocks: (B:3:0x0001, B:7:0x000f, B:11:0x0016, B:13:0x001c, B:16:0x002c, B:26:0x003a, B:28:0x0052, B:29:0x0074, B:31:0x0084, B:33:0x008b, B:36:0x0058, B:38:0x0068, B:40:0x00ab, B:42:0x00b2, B:45:0x00b7, B:47:0x00c8, B:50:0x00cd, B:51:0x0108, B:53:0x0113, B:59:0x011c, B:60:0x00e5, B:62:0x00fa, B:64:0x0105, B:67:0x009b, B:69:0x0121, B:70:0x0128), top: B:2:0x0001 }] */
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct add '--show-bad-code' argument
|
||||
*/
|
||||
public static final void d(K0.g r9, K0.b r10, boolean r11) {
|
||||
/*
|
||||
Method dump skipped, instructions count: 299
|
||||
To view this dump add '--comments-level debug' option
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: K0.g.d(K0.g, K0.b, boolean):void");
|
||||
}
|
||||
|
||||
public static void f0(String str) {
|
||||
if (f996q.matches(str)) {
|
||||
return;
|
||||
}
|
||||
throw new IllegalArgumentException(("keys must match regex [a-z0-9_-]{1,120}: \"" + str + Typography.quote).toString());
|
||||
}
|
||||
|
||||
public final synchronized void O() {
|
||||
try {
|
||||
if (this.f1006l) {
|
||||
return;
|
||||
}
|
||||
this.p.b(this.f1000d);
|
||||
if (this.p.c(this.f1001e)) {
|
||||
if (this.p.c(this.f999c)) {
|
||||
this.p.b(this.f1001e);
|
||||
} else {
|
||||
this.p.i(this.f1001e, this.f999c);
|
||||
}
|
||||
}
|
||||
if (this.p.c(this.f999c)) {
|
||||
try {
|
||||
b0();
|
||||
a0();
|
||||
this.f1006l = true;
|
||||
return;
|
||||
} catch (IOException unused) {
|
||||
try {
|
||||
close();
|
||||
AbstractC0105a.r(this.p, this.f997a);
|
||||
this.f1007m = false;
|
||||
} catch (Throwable th) {
|
||||
this.f1007m = false;
|
||||
throw th;
|
||||
}
|
||||
}
|
||||
}
|
||||
g0();
|
||||
this.f1006l = true;
|
||||
} catch (Throwable th2) {
|
||||
throw th2;
|
||||
}
|
||||
}
|
||||
|
||||
public final void Y() {
|
||||
BuildersKt.launch$default(this.f1003g, null, null, new f(this, null), 3, null);
|
||||
}
|
||||
|
||||
/* JADX WARN: Type inference failed for: r2v4, types: [java.lang.Object, r3.K] */
|
||||
public final B Z() {
|
||||
e eVar = this.p;
|
||||
eVar.getClass();
|
||||
z file = this.f999c;
|
||||
Intrinsics.checkNotNullParameter(file, "file");
|
||||
eVar.getClass();
|
||||
Intrinsics.checkNotNullParameter(file, "file");
|
||||
e.j(file, "appendingSink", "file");
|
||||
eVar.f994b.getClass();
|
||||
Intrinsics.checkNotNullParameter(file, "file");
|
||||
File e4 = file.e();
|
||||
Logger logger = w.f8315a;
|
||||
Intrinsics.checkNotNullParameter(e4, "<this>");
|
||||
FileOutputStream fileOutputStream = new FileOutputStream(e4, true);
|
||||
Intrinsics.checkNotNullParameter(fileOutputStream, "<this>");
|
||||
return AbstractC0105a.c(new h(new y(fileOutputStream, new Object()), new I1.b(this, 1)));
|
||||
}
|
||||
|
||||
public final void a0() {
|
||||
Iterator it = this.f1002f.values().iterator();
|
||||
long j4 = 0;
|
||||
while (it.hasNext()) {
|
||||
c cVar = (c) it.next();
|
||||
int i = 0;
|
||||
if (cVar.f990g == null) {
|
||||
while (i < 2) {
|
||||
j4 += cVar.f985b[i];
|
||||
i++;
|
||||
}
|
||||
} else {
|
||||
cVar.f990g = null;
|
||||
while (i < 2) {
|
||||
z zVar = (z) cVar.f986c.get(i);
|
||||
e eVar = this.p;
|
||||
eVar.b(zVar);
|
||||
eVar.b((z) cVar.f987d.get(i));
|
||||
i++;
|
||||
}
|
||||
it.remove();
|
||||
}
|
||||
}
|
||||
this.h = j4;
|
||||
}
|
||||
|
||||
/* JADX WARN: Removed duplicated region for block: B:25:0x00c0 */
|
||||
/* JADX WARN: Removed duplicated region for block: B:28:0x00c4 */
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct add '--show-bad-code' argument
|
||||
*/
|
||||
public final void b0() {
|
||||
/*
|
||||
r13 = this;
|
||||
java.lang.String r0 = ", "
|
||||
java.lang.String r1 = "unexpected journal header: ["
|
||||
K0.e r2 = r13.p
|
||||
r3.z r3 = r13.f999c
|
||||
r3.I r2 = r2.h(r3)
|
||||
r3.C r2 = a.AbstractC0105a.d(r2)
|
||||
r3 = 9223372036854775807(0x7fffffffffffffff, double:NaN)
|
||||
r5 = 0
|
||||
java.lang.String r6 = r2.a0(r3) // Catch: java.lang.Throwable -> L61
|
||||
java.lang.String r7 = r2.a0(r3) // Catch: java.lang.Throwable -> L61
|
||||
java.lang.String r8 = r2.a0(r3) // Catch: java.lang.Throwable -> L61
|
||||
java.lang.String r9 = r2.a0(r3) // Catch: java.lang.Throwable -> L61
|
||||
java.lang.String r10 = r2.a0(r3) // Catch: java.lang.Throwable -> L61
|
||||
java.lang.String r11 = "libcore.io.DiskLruCache"
|
||||
boolean r11 = kotlin.jvm.internal.Intrinsics.areEqual(r11, r6) // Catch: java.lang.Throwable -> L61
|
||||
if (r11 == 0) goto L84
|
||||
java.lang.String r11 = "1"
|
||||
boolean r11 = kotlin.jvm.internal.Intrinsics.areEqual(r11, r7) // Catch: java.lang.Throwable -> L61
|
||||
if (r11 == 0) goto L84
|
||||
r11 = 1
|
||||
java.lang.String r11 = java.lang.String.valueOf(r11) // Catch: java.lang.Throwable -> L61
|
||||
boolean r11 = kotlin.jvm.internal.Intrinsics.areEqual(r11, r8) // Catch: java.lang.Throwable -> L61
|
||||
if (r11 == 0) goto L84
|
||||
r11 = 2
|
||||
java.lang.String r11 = java.lang.String.valueOf(r11) // Catch: java.lang.Throwable -> L61
|
||||
boolean r11 = kotlin.jvm.internal.Intrinsics.areEqual(r11, r9) // Catch: java.lang.Throwable -> L61
|
||||
if (r11 == 0) goto L84
|
||||
int r11 = r10.length() // Catch: java.lang.Throwable -> L61
|
||||
if (r11 > 0) goto L84
|
||||
r0 = 0
|
||||
L57:
|
||||
java.lang.String r1 = r2.a0(r3) // Catch: java.lang.Throwable -> L61 java.io.EOFException -> L63
|
||||
r13.c0(r1) // Catch: java.lang.Throwable -> L61 java.io.EOFException -> L63
|
||||
int r0 = r0 + 1
|
||||
goto L57
|
||||
L61:
|
||||
r13 = move-exception
|
||||
goto Lb3
|
||||
L63:
|
||||
java.util.LinkedHashMap r1 = r13.f1002f // Catch: java.lang.Throwable -> L61
|
||||
int r1 = r1.size() // Catch: java.lang.Throwable -> L61
|
||||
int r0 = r0 - r1
|
||||
r13.i = r0 // Catch: java.lang.Throwable -> L61
|
||||
boolean r0 = r2.d() // Catch: java.lang.Throwable -> L61
|
||||
if (r0 != 0) goto L76
|
||||
r13.g0() // Catch: java.lang.Throwable -> L61
|
||||
goto L7c
|
||||
L76:
|
||||
r3.B r0 = r13.Z() // Catch: java.lang.Throwable -> L61
|
||||
r13.f1004j = r0 // Catch: java.lang.Throwable -> L61
|
||||
L7c:
|
||||
kotlin.Unit r13 = kotlin.Unit.INSTANCE // Catch: java.lang.Throwable -> L61
|
||||
r2.close() // Catch: java.lang.Throwable -> L82
|
||||
goto Lbe
|
||||
L82:
|
||||
r5 = move-exception
|
||||
goto Lbe
|
||||
L84:
|
||||
java.io.IOException r13 = new java.io.IOException // Catch: java.lang.Throwable -> L61
|
||||
java.lang.StringBuilder r3 = new java.lang.StringBuilder // Catch: java.lang.Throwable -> L61
|
||||
r3.<init>(r1) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r6) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r0) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r7) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r0) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r8) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r0) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r9) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r0) // Catch: java.lang.Throwable -> L61
|
||||
r3.append(r10) // Catch: java.lang.Throwable -> L61
|
||||
r0 = 93
|
||||
r3.append(r0) // Catch: java.lang.Throwable -> L61
|
||||
java.lang.String r0 = r3.toString() // Catch: java.lang.Throwable -> L61
|
||||
r13.<init>(r0) // Catch: java.lang.Throwable -> L61
|
||||
throw r13 // Catch: java.lang.Throwable -> L61
|
||||
Lb3:
|
||||
r2.close() // Catch: java.lang.Throwable -> Lb7
|
||||
goto Lbb
|
||||
Lb7:
|
||||
r0 = move-exception
|
||||
kotlin.ExceptionsKt.addSuppressed(r13, r0)
|
||||
Lbb:
|
||||
r12 = r5
|
||||
r5 = r13
|
||||
r13 = r12
|
||||
Lbe:
|
||||
if (r5 != 0) goto Lc4
|
||||
kotlin.jvm.internal.Intrinsics.checkNotNull(r13)
|
||||
return
|
||||
Lc4:
|
||||
throw r5
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: K0.g.b0():void");
|
||||
}
|
||||
|
||||
public final void c0(String str) {
|
||||
String substring;
|
||||
int l4 = StringsKt.l(str, ' ', 0, 6);
|
||||
if (l4 == -1) {
|
||||
throw new IOException(C.w.z("unexpected journal line: ", str));
|
||||
}
|
||||
int i = l4 + 1;
|
||||
int l5 = StringsKt.l(str, ' ', i, 4);
|
||||
LinkedHashMap linkedHashMap = this.f1002f;
|
||||
if (l5 == -1) {
|
||||
substring = str.substring(i);
|
||||
Intrinsics.checkNotNullExpressionValue(substring, "this as java.lang.String).substring(startIndex)");
|
||||
if (l4 == 6 && StringsKt.D(str, "REMOVE")) {
|
||||
linkedHashMap.remove(substring);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
substring = str.substring(i, l5);
|
||||
Intrinsics.checkNotNullExpressionValue(substring, "this as java.lang.String…ing(startIndex, endIndex)");
|
||||
}
|
||||
Object obj = linkedHashMap.get(substring);
|
||||
if (obj == null) {
|
||||
obj = new c(this, substring);
|
||||
linkedHashMap.put(substring, obj);
|
||||
}
|
||||
c cVar = (c) obj;
|
||||
if (l5 == -1 || l4 != 5 || !StringsKt.D(str, "CLEAN")) {
|
||||
if (l5 == -1 && l4 == 5 && StringsKt.D(str, "DIRTY")) {
|
||||
cVar.f990g = new b(this, cVar);
|
||||
return;
|
||||
} else {
|
||||
if (l5 != -1 || l4 != 4 || !StringsKt.D(str, "READ")) {
|
||||
throw new IOException(C.w.z("unexpected journal line: ", str));
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
String substring2 = str.substring(l5 + 1);
|
||||
Intrinsics.checkNotNullExpressionValue(substring2, "this as java.lang.String).substring(startIndex)");
|
||||
List y3 = StringsKt.y(substring2, new char[]{' '});
|
||||
cVar.f988e = true;
|
||||
cVar.f990g = null;
|
||||
int size = y3.size();
|
||||
cVar.i.getClass();
|
||||
if (size != 2) {
|
||||
throw new IOException("unexpected journal line: " + y3);
|
||||
}
|
||||
try {
|
||||
int size2 = y3.size();
|
||||
for (int i4 = 0; i4 < size2; i4++) {
|
||||
cVar.f985b[i4] = Long.parseLong((String) y3.get(i4));
|
||||
}
|
||||
} catch (NumberFormatException unused) {
|
||||
throw new IOException("unexpected journal line: " + y3);
|
||||
}
|
||||
}
|
||||
|
||||
@Override // java.io.Closeable, java.lang.AutoCloseable
|
||||
public final synchronized void close() {
|
||||
try {
|
||||
if (this.f1006l && !this.f1007m) {
|
||||
for (c cVar : (c[]) this.f1002f.values().toArray(new c[0])) {
|
||||
b bVar = cVar.f990g;
|
||||
if (bVar != null) {
|
||||
c cVar2 = bVar.f980a;
|
||||
if (Intrinsics.areEqual(cVar2.f990g, bVar)) {
|
||||
cVar2.f989f = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
e0();
|
||||
CoroutineScopeKt.cancel$default(this.f1003g, null, 1, null);
|
||||
B b4 = this.f1004j;
|
||||
Intrinsics.checkNotNull(b4);
|
||||
b4.close();
|
||||
this.f1004j = null;
|
||||
this.f1007m = true;
|
||||
return;
|
||||
}
|
||||
this.f1007m = true;
|
||||
} catch (Throwable th) {
|
||||
throw th;
|
||||
}
|
||||
}
|
||||
|
||||
public final void d0(c cVar) {
|
||||
B b4;
|
||||
int i = cVar.h;
|
||||
String str = cVar.f984a;
|
||||
if (i > 0 && (b4 = this.f1004j) != null) {
|
||||
b4.Q("DIRTY");
|
||||
b4.y(32);
|
||||
b4.Q(str);
|
||||
b4.y(10);
|
||||
b4.flush();
|
||||
}
|
||||
if (cVar.h > 0 || cVar.f990g != null) {
|
||||
cVar.f989f = true;
|
||||
return;
|
||||
}
|
||||
for (int i4 = 0; i4 < 2; i4++) {
|
||||
this.p.b((z) cVar.f986c.get(i4));
|
||||
long j4 = this.h;
|
||||
long[] jArr = cVar.f985b;
|
||||
this.h = j4 - jArr[i4];
|
||||
jArr[i4] = 0;
|
||||
}
|
||||
this.i++;
|
||||
B b5 = this.f1004j;
|
||||
if (b5 != null) {
|
||||
b5.Q("REMOVE");
|
||||
b5.y(32);
|
||||
b5.Q(str);
|
||||
b5.y(10);
|
||||
}
|
||||
this.f1002f.remove(str);
|
||||
if (this.i >= 2000) {
|
||||
Y();
|
||||
}
|
||||
}
|
||||
|
||||
public final void e() {
|
||||
if (this.f1007m) {
|
||||
throw new IllegalStateException("cache is closed");
|
||||
}
|
||||
}
|
||||
|
||||
/* JADX WARN: Code restructure failed: missing block: B:9:0x0022, code lost:
|
||||
|
||||
d0(r1);
|
||||
*/
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct add '--show-bad-code' argument
|
||||
*/
|
||||
public final void e0() {
|
||||
/*
|
||||
r4 = this;
|
||||
L0:
|
||||
long r0 = r4.h
|
||||
long r2 = r4.f998b
|
||||
int r0 = (r0 > r2 ? 1 : (r0 == r2 ? 0 : -1))
|
||||
if (r0 <= 0) goto L27
|
||||
java.util.LinkedHashMap r0 = r4.f1002f
|
||||
java.util.Collection r0 = r0.values()
|
||||
java.util.Iterator r0 = r0.iterator()
|
||||
L12:
|
||||
boolean r1 = r0.hasNext()
|
||||
if (r1 == 0) goto L26
|
||||
java.lang.Object r1 = r0.next()
|
||||
K0.c r1 = (K0.c) r1
|
||||
boolean r2 = r1.f989f
|
||||
if (r2 != 0) goto L12
|
||||
r4.d0(r1)
|
||||
goto L0
|
||||
L26:
|
||||
return
|
||||
L27:
|
||||
r0 = 0
|
||||
r4.f1008n = r0
|
||||
return
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: K0.g.e0():void");
|
||||
}
|
||||
|
||||
@Override // java.io.Flushable
|
||||
public final synchronized void flush() {
|
||||
if (this.f1006l) {
|
||||
e();
|
||||
e0();
|
||||
B b4 = this.f1004j;
|
||||
Intrinsics.checkNotNull(b4);
|
||||
b4.flush();
|
||||
}
|
||||
}
|
||||
|
||||
public final synchronized void g0() {
|
||||
Unit unit;
|
||||
try {
|
||||
B b4 = this.f1004j;
|
||||
if (b4 != null) {
|
||||
b4.close();
|
||||
}
|
||||
B c4 = AbstractC0105a.c(this.p.g(this.f1000d));
|
||||
Throwable th = null;
|
||||
try {
|
||||
c4.Q("libcore.io.DiskLruCache");
|
||||
c4.y(10);
|
||||
c4.Q("1");
|
||||
c4.y(10);
|
||||
c4.R(1);
|
||||
c4.y(10);
|
||||
c4.R(2);
|
||||
c4.y(10);
|
||||
c4.y(10);
|
||||
for (c cVar : this.f1002f.values()) {
|
||||
if (cVar.f990g != null) {
|
||||
c4.Q("DIRTY");
|
||||
c4.y(32);
|
||||
c4.Q(cVar.f984a);
|
||||
c4.y(10);
|
||||
} else {
|
||||
c4.Q("CLEAN");
|
||||
c4.y(32);
|
||||
c4.Q(cVar.f984a);
|
||||
for (long j4 : cVar.f985b) {
|
||||
c4.y(32);
|
||||
c4.R(j4);
|
||||
}
|
||||
c4.y(10);
|
||||
}
|
||||
}
|
||||
unit = Unit.INSTANCE;
|
||||
try {
|
||||
c4.close();
|
||||
} catch (Throwable th2) {
|
||||
th = th2;
|
||||
}
|
||||
} catch (Throwable th3) {
|
||||
try {
|
||||
c4.close();
|
||||
} catch (Throwable th4) {
|
||||
ExceptionsKt.addSuppressed(th3, th4);
|
||||
}
|
||||
unit = null;
|
||||
th = th3;
|
||||
}
|
||||
if (th != null) {
|
||||
throw th;
|
||||
}
|
||||
Intrinsics.checkNotNull(unit);
|
||||
if (this.p.c(this.f999c)) {
|
||||
this.p.i(this.f999c, this.f1001e);
|
||||
this.p.i(this.f1000d, this.f999c);
|
||||
this.p.b(this.f1001e);
|
||||
} else {
|
||||
this.p.i(this.f1000d, this.f999c);
|
||||
}
|
||||
this.f1004j = Z();
|
||||
this.i = 0;
|
||||
this.f1005k = false;
|
||||
this.f1009o = false;
|
||||
} catch (Throwable th5) {
|
||||
throw th5;
|
||||
}
|
||||
}
|
||||
|
||||
public final synchronized b s(String str) {
|
||||
try {
|
||||
e();
|
||||
f0(str);
|
||||
O();
|
||||
c cVar = (c) this.f1002f.get(str);
|
||||
if ((cVar != null ? cVar.f990g : null) != null) {
|
||||
return null;
|
||||
}
|
||||
if (cVar != null && cVar.h != 0) {
|
||||
return null;
|
||||
}
|
||||
if (!this.f1008n && !this.f1009o) {
|
||||
B b4 = this.f1004j;
|
||||
Intrinsics.checkNotNull(b4);
|
||||
b4.Q("DIRTY");
|
||||
b4.y(32);
|
||||
b4.Q(str);
|
||||
b4.y(10);
|
||||
b4.flush();
|
||||
if (this.f1005k) {
|
||||
return null;
|
||||
}
|
||||
if (cVar == null) {
|
||||
cVar = new c(this, str);
|
||||
this.f1002f.put(str, cVar);
|
||||
}
|
||||
b bVar = new b(this, cVar);
|
||||
cVar.f990g = bVar;
|
||||
return bVar;
|
||||
}
|
||||
Y();
|
||||
return null;
|
||||
} catch (Throwable th) {
|
||||
throw th;
|
||||
}
|
||||
}
|
||||
|
||||
public final synchronized d x(String str) {
|
||||
d a2;
|
||||
e();
|
||||
f0(str);
|
||||
O();
|
||||
c cVar = (c) this.f1002f.get(str);
|
||||
if (cVar != null && (a2 = cVar.a()) != null) {
|
||||
boolean z3 = true;
|
||||
this.i++;
|
||||
B b4 = this.f1004j;
|
||||
Intrinsics.checkNotNull(b4);
|
||||
b4.Q("READ");
|
||||
b4.y(32);
|
||||
b4.Q(str);
|
||||
b4.y(10);
|
||||
if (this.i < 2000) {
|
||||
z3 = false;
|
||||
}
|
||||
if (z3) {
|
||||
Y();
|
||||
}
|
||||
return a2;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
55
apk_decompiled/sources/K0/h.java
Normal file
55
apk_decompiled/sources/K0/h.java
Normal file
@@ -0,0 +1,55 @@
|
||||
package K0;
|
||||
|
||||
import java.io.IOException;
|
||||
import r3.C0576h;
|
||||
import r3.G;
|
||||
import r3.o;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class h extends o {
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final I1.b f1010b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public boolean f1011c;
|
||||
|
||||
public h(G g4, I1.b bVar) {
|
||||
super(g4);
|
||||
this.f1010b = bVar;
|
||||
}
|
||||
|
||||
@Override // r3.o, r3.G, java.io.Closeable, java.lang.AutoCloseable
|
||||
public final void close() {
|
||||
try {
|
||||
super.close();
|
||||
} catch (IOException e4) {
|
||||
this.f1011c = true;
|
||||
this.f1010b.invoke(e4);
|
||||
}
|
||||
}
|
||||
|
||||
@Override // r3.o, r3.G, java.io.Flushable
|
||||
public final void flush() {
|
||||
try {
|
||||
super.flush();
|
||||
} catch (IOException e4) {
|
||||
this.f1011c = true;
|
||||
this.f1010b.invoke(e4);
|
||||
}
|
||||
}
|
||||
|
||||
@Override // r3.o, r3.G
|
||||
public final void z(C0576h c0576h, long j4) {
|
||||
if (this.f1011c) {
|
||||
c0576h.l(j4);
|
||||
return;
|
||||
}
|
||||
try {
|
||||
super.z(c0576h, j4);
|
||||
} catch (IOException e4) {
|
||||
this.f1011c = true;
|
||||
this.f1010b.invoke(e4);
|
||||
}
|
||||
}
|
||||
}
|
||||
19
apk_decompiled/sources/K0/i.java
Normal file
19
apk_decompiled/sources/K0/i.java
Normal file
@@ -0,0 +1,19 @@
|
||||
package K0;
|
||||
|
||||
import java.io.Closeable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class i implements Closeable {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final d f1012a;
|
||||
|
||||
public i(d dVar) {
|
||||
this.f1012a = dVar;
|
||||
}
|
||||
|
||||
@Override // java.io.Closeable, java.lang.AutoCloseable
|
||||
public final void close() {
|
||||
this.f1012a.close();
|
||||
}
|
||||
}
|
||||
20
apk_decompiled/sources/K0/j.java
Normal file
20
apk_decompiled/sources/K0/j.java
Normal file
@@ -0,0 +1,20 @@
|
||||
package K0;
|
||||
|
||||
import kotlinx.coroutines.CoroutineDispatcher;
|
||||
import r3.u;
|
||||
import r3.z;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class j {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final u f1013a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final g f1014b;
|
||||
|
||||
public j(long j4, CoroutineDispatcher coroutineDispatcher, u uVar, z zVar) {
|
||||
this.f1013a = uVar;
|
||||
this.f1014b = new g(j4, coroutineDispatcher, uVar, zVar);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user