CrackMe.apk
Download file
package androidx.browser.customtabs;
import android.app.PendingIntent;
import android.app.Service;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.os.IBinder;
import android.os.RemoteException;
import android.support.customtabs.ICustomTabsCallback;
import android.support.customtabs.ICustomTabsService;
import androidx.collection.SimpleArrayMap;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.List;
import java.util.NoSuchElementException;
public abstract class CustomTabsService extends Service {
public static final String ACTION_CUSTOM_TABS_CONNECTION = "android.support.customtabs.action.CustomTabsService";
public static final String CATEGORY_COLOR_SCHEME_CUSTOMIZATION = "androidx.browser.customtabs.category.ColorSchemeCustomization";
public static final String CATEGORY_NAVBAR_COLOR_CUSTOMIZATION = "androidx.browser.customtabs.category.NavBarColorCustomization";
public static final String CATEGORY_TRUSTED_WEB_ACTIVITY_IMMERSIVE_MODE = "androidx.browser.trusted.category.ImmersiveMode";
public static final String CATEGORY_WEB_SHARE_TARGET_V2 = "androidx.browser.trusted.category.WebShareTargetV2";
public static final int FILE_PURPOSE_TRUSTED_WEB_ACTIVITY_SPLASH_IMAGE = 1;
public static final String KEY_SUCCESS = "androidx.browser.customtabs.SUCCESS";
public static final String KEY_URL = "android.support.customtabs.otherurls.URL";
public static final int RELATION_HANDLE_ALL_URLS = 2;
public static final int RELATION_USE_AS_ORIGIN = 1;
public static final int RESULT_FAILURE_DISALLOWED = -1;
public static final int RESULT_FAILURE_MESSAGING_ERROR = -3;
public static final int RESULT_FAILURE_REMOTE_ERROR = -2;
public static final int RESULT_SUCCESS = 0;
public static final String TRUSTED_WEB_ACTIVITY_CATEGORY = "androidx.browser.trusted.category.TrustedWebActivities";
private ICustomTabsService.Stub mBinder = new ICustomTabsService.Stub() {
public boolean warmup(long j) {
return CustomTabsService.this.warmup(j);
}
public boolean newSession(ICustomTabsCallback iCustomTabsCallback) {
return newSessionInternal(iCustomTabsCallback, (PendingIntent) null);
}
public boolean newSessionWithExtras(ICustomTabsCallback iCustomTabsCallback, Bundle bundle) {
return newSessionInternal(iCustomTabsCallback, getSessionIdFromBundle(bundle));
}
private boolean newSessionInternal(ICustomTabsCallback iCustomTabsCallback, PendingIntent pendingIntent) {
CustomTabsSessionToken customTabsSessionToken = new CustomTabsSessionToken(iCustomTabsCallback, pendingIntent);
try {
CustomTabsService$1$$ExternalSyntheticLambda0 customTabsService$1$$ExternalSyntheticLambda0 = new CustomTabsService$1$$ExternalSyntheticLambda0(this, customTabsSessionToken);
synchronized (CustomTabsService.this.mDeathRecipientMap) {
iCustomTabsCallback.asBinder().linkToDeath(customTabsService$1$$ExternalSyntheticLambda0, 0);
CustomTabsService.this.mDeathRecipientMap.put(iCustomTabsCallback.asBinder(), customTabsService$1$$ExternalSyntheticLambda0);
}
return CustomTabsService.this.newSession(customTabsSessionToken);
} catch (RemoteException unused) {
return false;
}
}
/* access modifiers changed from: package-private */
/* renamed from: lambda$newSessionInternal$0$androidx-browser-customtabs-CustomTabsService$1 reason: not valid java name */
public /* synthetic */ void m2lambda$newSessionInternal$0$androidxbrowsercustomtabsCustomTabsService$1(CustomTabsSessionToken customTabsSessionToken) {
CustomTabsService.this.cleanUpSession(customTabsSessionToken);
}
public boolean mayLaunchUrl(ICustomTabsCallback iCustomTabsCallback, Uri uri, Bundle bundle, List<Bundle> list) {
return CustomTabsService.this.mayLaunchUrl(new CustomTabsSessionToken(iCustomTabsCallback, getSessionIdFromBundle(bundle)), uri, bundle, list);
}
public Bundle extraCommand(String str, Bundle bundle) {
return CustomTabsService.this.extraCommand(str, bundle);
}
public boolean updateVisuals(ICustomTabsCallback iCustomTabsCallback, Bundle bundle) {
return CustomTabsService.this.updateVisuals(new CustomTabsSessionToken(iCustomTabsCallback, getSessionIdFromBundle(bundle)), bundle);
}
public boolean requestPostMessageChannel(ICustomTabsCallback iCustomTabsCallback, Uri uri) {
return CustomTabsService.this.requestPostMessageChannel(new CustomTabsSessionToken(iCustomTabsCallback, (PendingIntent) null), uri);
}
public boolean requestPostMessageChannelWithExtras(ICustomTabsCallback iCustomTabsCallback, Uri uri, Bundle bundle) {
return CustomTabsService.this.requestPostMessageChannel(new CustomTabsSessionToken(iCustomTabsCallback, getSessionIdFromBundle(bundle)), uri);
}
public int postMessage(ICustomTabsCallback iCustomTabsCallback, String str, Bundle bundle) {
return CustomTabsService.this.postMessage(new CustomTabsSessionToken(iCustomTabsCallback, getSessionIdFromBundle(bundle)), str, bundle);
}
public boolean validateRelationship(ICustomTabsCallback iCustomTabsCallback, int i, Uri uri, Bundle bundle) {
return CustomTabsService.this.validateRelationship(new CustomTabsSessionToken(iCustomTabsCallback, getSessionIdFromBundle(bundle)), i, uri, bundle);
}
public boolean receiveFile(ICustomTabsCallback iCustomTabsCallback, Uri uri, int i, Bundle bundle) {
return CustomTabsService.this.receiveFile(new CustomTabsSessionToken(iCustomTabsCallback, getSessionIdFromBundle(bundle)), uri, i, bundle);
}
private PendingIntent getSessionIdFromBundle(Bundle bundle) {
if (bundle == null) {
return null;
}
PendingIntent pendingIntent = (PendingIntent) bundle.getParcelable(CustomTabsIntent.EXTRA_SESSION_ID);
bundle.remove(CustomTabsIntent.EXTRA_SESSION_ID);
return pendingIntent;
}
};
final SimpleArrayMap<IBinder, IBinder.DeathRecipient> mDeathRecipientMap = new SimpleArrayMap<>();
@Retention(RetentionPolicy.SOURCE)
public @interface FilePurpose {
}
@Retention(RetentionPolicy.SOURCE)
public @interface Relation {
}
@Retention(RetentionPolicy.SOURCE)
public @interface Result {
}
/* access modifiers changed from: protected */
public abstract Bundle extraCommand(String str, Bundle bundle);
/* access modifiers changed from: protected */
public abstract boolean mayLaunchUrl(CustomTabsSessionToken customTabsSessionToken, Uri uri, Bundle bundle, List<Bundle> list);
/* access modifiers changed from: protected */
public abstract boolean newSession(CustomTabsSessionToken customTabsSessionToken);
/* access modifiers changed from: protected */
public abstract int postMessage(CustomTabsSessionToken customTabsSessionToken, String str, Bundle bundle);
/* access modifiers changed from: protected */
public abstract boolean receiveFile(CustomTabsSessionToken customTabsSessionToken, Uri uri, int i, Bundle bundle);
/* access modifiers changed from: protected */
public abstract boolean requestPostMessageChannel(CustomTabsSessionToken customTabsSessionToken, Uri uri);
/* access modifiers changed from: protected */
public abstract boolean updateVisuals(CustomTabsSessionToken customTabsSessionToken, Bundle bundle);
/* access modifiers changed from: protected */
public abstract boolean validateRelationship(CustomTabsSessionToken customTabsSessionToken, int i, Uri uri, Bundle bundle);
/* access modifiers changed from: protected */
public abstract boolean warmup(long j);
public IBinder onBind(Intent intent) {
return this.mBinder;
}
/* access modifiers changed from: protected */
public boolean cleanUpSession(CustomTabsSessionToken customTabsSessionToken) {
try {
synchronized (this.mDeathRecipientMap) {
IBinder callbackBinder = customTabsSessionToken.getCallbackBinder();
if (callbackBinder == null) {
return false;
}
callbackBinder.unlinkToDeath(this.mDeathRecipientMap.get(callbackBinder), 0);
this.mDeathRecipientMap.remove(callbackBinder);
return true;
}
} catch (NoSuchElementException unused) {
return false;
}
}
}
Download file