* Decompile and recreate Soul Browser v1.4.85 with APK CI builds Co-authored-by: KaKi87 <KaKi87@pm.me> * Fix CI build: include bundled google.jks and remove PR trigger The apktool build failed in CI because app/unknown/.../google.jks was excluded by the *.jks gitignore rule. Whitelist app-bundled JKS files and commit the missing resource. Also remove the redundant pull_request workflow trigger. Co-authored-by: KaKi87 <KaKi87@pm.me> * Change package ID to com.github.kaki87.soulbrowser Rename the application ID so the rebuilt APK can be installed alongside the original Soul Browser from Google Play. - Update AndroidManifest package, permissions, providers, and actions - Update R class references in smali (com/github/kaki87/soulbrowser/R) - Update shortcuts.xml targetPackage - Rename app label to "Soul Rebuild" for easy identification Co-authored-by: KaKi87 <KaKi87@pm.me> * Fix install compatibility: remove split APK metadata and bundle native libs The rebuilt APK still declared requiredSplitTypes and Play Store split metadata, causing Android to reject standalone installs as incompatible. - Remove requiredSplitTypes and split-related manifest meta-data - Merge native libs from all ABI splits with uncompressed storage - Page-align before signing for extractNativeLibs=false - Add .so to apktool doNotCompress list Co-authored-by: KaKi87 <KaKi87@pm.me> * Fix install failure: use apksigner v2/v3 and bundle arm64 native libs Target SDK 36 requires APK Signature Scheme v2+, but jarsigner only produces v1 signatures, causing Android to reject the install. - Sign with apksigner (v1+v2+v3) instead of jarsigner - Add arm64-v8a native libraries from universal Soul Browser 1.4.79 - Set extractNativeLibs=true for reliable sideload installs - Commit stable debug keystore for consistent signatures across builds Co-authored-by: KaKi87 <KaKi87@pm.me> * Add committed debug keystore for consistent APK signatures Co-authored-by: KaKi87 <KaKi87@pm.me> * Fix startup crash: use original classes2.dex desugar libraries Apktool recompiles smali_classes2 into a broken classes2.dex, causing ClassNotFoundException for j$.com.android.tools.r8.a at ML Kit init. Inject the original classes2.dex (Java 8+ desugar libs) after apktool build instead of using the recompiled version. Co-authored-by: KaKi87 <KaKi87@pm.me> * Fix missing drawable resources from density split APKs The base APK is an app bundle module; density-specific drawables like seek_thumb_nor_b live in config.xhdpi.apk and were missing after rebuild, causing Resources$NotFoundException at runtime. - Merge non-9-patch resources from split APKs before apktool build - Sync public.xml IDs from R smali only when backing files exist - Add 713 density-specific resource IDs to public.xml Co-authored-by: KaKi87 <KaKi87@pm.me> --------- Co-authored-by: Cursor Agent <cursoragent@cursor.com>
139 lines
6.3 KiB
Java
139 lines
6.3 KiB
Java
package com.google.android.gms.internal.ads;
|
|
|
|
import android.content.Context;
|
|
import android.database.Cursor;
|
|
import android.database.sqlite.SQLiteDatabase;
|
|
import android.net.Uri;
|
|
import com.google.android.gms.ads.RequestConfiguration;
|
|
import com.google.android.gms.common.internal.ImagesContract;
|
|
import com.google.common.util.concurrent.ListenableFuture;
|
|
import java.util.concurrent.Callable;
|
|
|
|
/* loaded from: classes.dex */
|
|
public final class zzehu extends zzfwm {
|
|
public static final /* synthetic */ int g = 0;
|
|
|
|
/* renamed from: c, reason: collision with root package name */
|
|
public final Context f6519c;
|
|
public final zzgyw f;
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public zzehu(android.content.Context r3, com.google.android.gms.internal.ads.zzgyw r4) {
|
|
/*
|
|
r2 = this;
|
|
com.google.android.gms.internal.ads.zzbgb r0 = com.google.android.gms.internal.ads.zzbgk.C9
|
|
com.google.android.gms.internal.ads.zzbgi r1 = com.google.android.gms.ads.internal.client.zzbd.zzc()
|
|
java.lang.Object r0 = r1.a(r0)
|
|
java.lang.Integer r0 = (java.lang.Integer) r0
|
|
int r0 = r0.intValue()
|
|
int r1 = com.google.android.gms.internal.ads.zzfwo.f7705a
|
|
java.lang.String r1 = "AdMobOfflineBufferedPings.db"
|
|
r2.<init>(r3, r0, r1)
|
|
r2.f6519c = r3
|
|
r2.f = r4
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: com.google.android.gms.internal.ads.zzehu.<init>(android.content.Context, com.google.android.gms.internal.ads.zzgyw):void");
|
|
}
|
|
|
|
public static void d(SQLiteDatabase sQLiteDatabase, com.google.android.gms.ads.internal.util.client.zzu zzuVar) {
|
|
SQLiteDatabase sQLiteDatabase2;
|
|
String sb;
|
|
sQLiteDatabase.beginTransaction();
|
|
try {
|
|
String[] strArr = {"timestamp", ImagesContract.URL};
|
|
StringBuilder sb2 = new StringBuilder(15);
|
|
sb2.append("event_state = 1");
|
|
String sb3 = sb2.toString();
|
|
sQLiteDatabase2 = sQLiteDatabase;
|
|
try {
|
|
Cursor query = sQLiteDatabase2.query("offline_buffered_pings", strArr, sb3, null, null, null, "timestamp ASC", null);
|
|
int count = query.getCount();
|
|
String[] strArr2 = new String[count];
|
|
int i = 0;
|
|
while (query.moveToNext()) {
|
|
int columnIndex = query.getColumnIndex("timestamp");
|
|
int columnIndex2 = query.getColumnIndex(ImagesContract.URL);
|
|
if (columnIndex2 != -1) {
|
|
long j = query.getLong(columnIndex);
|
|
String string = query.getString(columnIndex2);
|
|
if (string == null) {
|
|
sb = RequestConfiguration.MAX_AD_CONTENT_RATING_UNSPECIFIED;
|
|
} else {
|
|
Uri parse = Uri.parse(string);
|
|
long currentTimeMillis = com.google.android.gms.ads.internal.zzt.zzk().currentTimeMillis() - j;
|
|
String encodedQuery = parse.getEncodedQuery();
|
|
Uri.Builder clearQuery = parse.buildUpon().clearQuery();
|
|
clearQuery.appendQueryParameter("bd", Long.toString(currentTimeMillis));
|
|
String valueOf = String.valueOf(clearQuery.build());
|
|
StringBuilder sb4 = new StringBuilder(valueOf.length() + 1 + String.valueOf(encodedQuery).length());
|
|
sb4.append(valueOf);
|
|
sb4.append("&");
|
|
sb4.append(encodedQuery);
|
|
sb = sb4.toString();
|
|
}
|
|
strArr2[i] = sb;
|
|
}
|
|
i++;
|
|
}
|
|
query.close();
|
|
sQLiteDatabase2.delete("offline_buffered_pings", "event_state = ?", new String[]{Integer.toString(1)});
|
|
sQLiteDatabase2.setTransactionSuccessful();
|
|
sQLiteDatabase2.endTransaction();
|
|
for (int i2 = 0; i2 < count; i2++) {
|
|
zzuVar.zzc(strArr2[i2], null);
|
|
}
|
|
} catch (Throwable th) {
|
|
th = th;
|
|
Throwable th2 = th;
|
|
sQLiteDatabase2.endTransaction();
|
|
throw th2;
|
|
}
|
|
} catch (Throwable th3) {
|
|
th = th3;
|
|
sQLiteDatabase2 = sQLiteDatabase;
|
|
}
|
|
}
|
|
|
|
public final void a(zzflu zzfluVar) {
|
|
Callable callable = new Callable() { // from class: com.google.android.gms.internal.ads.zzeht
|
|
@Override // java.util.concurrent.Callable
|
|
public final /* synthetic */ Object call() {
|
|
return zzehu.this.getWritableDatabase();
|
|
}
|
|
};
|
|
zzgyw zzgywVar = this.f;
|
|
ListenableFuture v0 = zzgywVar.v0(callable);
|
|
v0.k(new zzgyk(v0, new zzehn(this, zzfluVar)), zzgywVar);
|
|
}
|
|
|
|
public final void b(final String str) {
|
|
a(new zzflu() { // from class: com.google.android.gms.internal.ads.zzehq
|
|
@Override // com.google.android.gms.internal.ads.zzflu
|
|
public final Object zza(Object obj) {
|
|
int i = zzehu.g;
|
|
((SQLiteDatabase) obj).delete("offline_buffered_pings", "gws_query_id = ? AND event_state = ?", new String[]{str, Integer.toString(0)});
|
|
return null;
|
|
}
|
|
});
|
|
}
|
|
|
|
@Override // android.database.sqlite.SQLiteOpenHelper
|
|
public final void onCreate(SQLiteDatabase sQLiteDatabase) {
|
|
sQLiteDatabase.execSQL("CREATE TABLE offline_buffered_pings (timestamp INTEGER PRIMARY_KEY, gws_query_id TEXT, url TEXT, event_state INTEGER)");
|
|
}
|
|
|
|
@Override // android.database.sqlite.SQLiteOpenHelper
|
|
public final void onDowngrade(SQLiteDatabase sQLiteDatabase, int i, int i2) {
|
|
sQLiteDatabase.execSQL("DROP TABLE IF EXISTS offline_buffered_pings");
|
|
}
|
|
|
|
@Override // android.database.sqlite.SQLiteOpenHelper
|
|
public final void onUpgrade(SQLiteDatabase sQLiteDatabase, int i, int i2) {
|
|
sQLiteDatabase.execSQL("DROP TABLE IF EXISTS offline_buffered_pings");
|
|
}
|
|
}
|