230 lines
11 KiB
Java
230 lines
11 KiB
Java
|
package com.kofax.kmc.kut.utilities;
|
||
|
|
||
|
import android.app.Application;
|
||
|
import android.content.Context;
|
||
|
import android.media.AudioTrack;
|
||
|
import android.os.Process;
|
||
|
import android.os.SystemClock;
|
||
|
import android.text.AndroidCharacter;
|
||
|
import android.text.TextUtils;
|
||
|
import android.util.TypedValue;
|
||
|
import android.view.Gravity;
|
||
|
import android.view.KeyEvent;
|
||
|
import android.view.MotionEvent;
|
||
|
import android.view.View;
|
||
|
import android.view.ViewConfiguration;
|
||
|
import android.widget.ExpandableListView;
|
||
|
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
|
||
|
import java.lang.reflect.Method;
|
||
|
import o.xzZ;
|
||
|
|
||
|
/* loaded from: classes.dex */
|
||
|
public class AppContextProvider extends Application {
|
||
|
private static char[] a;
|
||
|
private static int b;
|
||
|
private static long c;
|
||
|
private static Context nA;
|
||
|
private static final byte[] $$a = {57, -60, 61, 103};
|
||
|
private static final int $$b = 158;
|
||
|
private static int $10 = 0;
|
||
|
private static int $11 = 1;
|
||
|
private static int e = 0;
|
||
|
|
||
|
/* JADX WARN: Removed duplicated region for block: B:10:0x0023 */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:7:0x001b */
|
||
|
/* JADX WARN: Unsupported multi-entry loop pattern (BACK_EDGE: B:10:0x0023 -> B:4:0x002d). Please report as a decompilation issue!!! */
|
||
|
/*
|
||
|
Code decompiled incorrectly, please refer to instructions dump.
|
||
|
To view partially-correct add '--show-bad-code' argument
|
||
|
*/
|
||
|
private static void g(short r6, byte r7, int r8, java.lang.Object[] r9) {
|
||
|
/*
|
||
|
byte[] r0 = com.kofax.kmc.kut.utilities.AppContextProvider.$$a
|
||
|
int r6 = 106 - r6
|
||
|
int r8 = r8 * 2
|
||
|
int r1 = r8 + 1
|
||
|
int r7 = r7 * 2
|
||
|
int r7 = 3 - r7
|
||
|
byte[] r1 = new byte[r1]
|
||
|
r2 = 0
|
||
|
if (r0 != 0) goto L15
|
||
|
r3 = r7
|
||
|
r6 = r8
|
||
|
r4 = r2
|
||
|
goto L2d
|
||
|
L15:
|
||
|
r3 = r2
|
||
|
L16:
|
||
|
byte r4 = (byte) r6
|
||
|
r1[r3] = r4
|
||
|
if (r3 != r8) goto L23
|
||
|
java.lang.String r6 = new java.lang.String
|
||
|
r6.<init>(r1, r2)
|
||
|
r9[r2] = r6
|
||
|
return
|
||
|
L23:
|
||
|
int r7 = r7 + 1
|
||
|
int r3 = r3 + 1
|
||
|
r4 = r0[r7]
|
||
|
r5 = r3
|
||
|
r3 = r7
|
||
|
r7 = r4
|
||
|
r4 = r5
|
||
|
L2d:
|
||
|
int r7 = -r7
|
||
|
int r6 = r6 + r7
|
||
|
r7 = r3
|
||
|
r3 = r4
|
||
|
goto L16
|
||
|
*/
|
||
|
throw new UnsupportedOperationException("Method not decompiled: com.kofax.kmc.kut.utilities.AppContextProvider.g(short, byte, int, java.lang.Object[]):void");
|
||
|
}
|
||
|
|
||
|
@Override // android.app.Application
|
||
|
public void onCreate() {
|
||
|
int i = 2 % 2;
|
||
|
int i2 = b + 119;
|
||
|
e = i2 % 128;
|
||
|
if (i2 % 2 == 0) {
|
||
|
super.onCreate();
|
||
|
nA = getApplicationContext();
|
||
|
} else {
|
||
|
super.onCreate();
|
||
|
nA = getApplicationContext();
|
||
|
Object obj = null;
|
||
|
obj.hashCode();
|
||
|
throw null;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* JADX WARN: Removed duplicated region for block: B:64:0x027f */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:65:0x0280 */
|
||
|
/*
|
||
|
Code decompiled incorrectly, please refer to instructions dump.
|
||
|
To view partially-correct add '--show-bad-code' argument
|
||
|
*/
|
||
|
private static void f(int r21, int r22, char r23, java.lang.Object[] r24) {
|
||
|
/*
|
||
|
Method dump skipped, instructions count: 666
|
||
|
To view this dump add '--comments-level debug' option
|
||
|
*/
|
||
|
throw new UnsupportedOperationException("Method not decompiled: com.kofax.kmc.kut.utilities.AppContextProvider.f(int, int, char, java.lang.Object[]):void");
|
||
|
}
|
||
|
|
||
|
@Override // android.content.ContextWrapper
|
||
|
public void attachBaseContext(Context context) {
|
||
|
int i = 2 % 2;
|
||
|
int i2 = e + 49;
|
||
|
b = i2 % 128;
|
||
|
int i3 = i2 % 2;
|
||
|
super.attachBaseContext(context);
|
||
|
Object[] objArr = new Object[1];
|
||
|
f((SystemClock.currentThreadTimeMillis() > (-1L) ? 1 : (SystemClock.currentThreadTimeMillis() == (-1L) ? 0 : -1)) - 1, 17 - TextUtils.lastIndexOf("", '0', 0, 0), (char) (((Process.getThreadPriority(0) + 20) >> 6) + 32893), objArr);
|
||
|
Class<?> cls = Class.forName((String) objArr[0]);
|
||
|
Object[] objArr2 = new Object[1];
|
||
|
f((ViewConfiguration.getWindowTouchSlop() >> 8) + 18, 5 - TextUtils.indexOf("", ""), (char) KeyEvent.getDeadChar(0, 0), objArr2);
|
||
|
int intValue = ((Integer) cls.getDeclaredMethod((String) objArr2[0], new Class[0]).invoke(null, new Object[0])).intValue() % 100000;
|
||
|
if (intValue >= 99000) {
|
||
|
int i4 = b + 111;
|
||
|
e = i4 % 128;
|
||
|
if (i4 % 2 != 0) {
|
||
|
int i5 = 48 / 0;
|
||
|
if (intValue <= 99999) {
|
||
|
return;
|
||
|
}
|
||
|
} else if (intValue <= 99999) {
|
||
|
return;
|
||
|
}
|
||
|
}
|
||
|
Context applicationContext = context != null ? context.getApplicationContext() : context;
|
||
|
if (applicationContext != null) {
|
||
|
try {
|
||
|
Object obj = xzZ.y.get(125943855);
|
||
|
if (obj == null) {
|
||
|
obj = ((Class) xzZ.c(492 - (ViewConfiguration.getMaximumDrawingCacheSize() >> 24), TextUtils.indexOf("", "") + 5, (char) ((-1) - ExpandableListView.getPackedPositionChild(0L)))).getMethod("a", null);
|
||
|
xzZ.y.put(125943855, obj);
|
||
|
}
|
||
|
Object invoke = ((Method) obj).invoke(null, null);
|
||
|
Object[] objArr3 = new Object[1];
|
||
|
f(23 - View.MeasureSpec.makeMeasureSpec(0, 0), 48 - (KeyEvent.getMaxKeyCode() >> 16), (char) TextUtils.indexOf("", ""), objArr3);
|
||
|
String str = (String) objArr3[0];
|
||
|
Object[] objArr4 = new Object[1];
|
||
|
f(71 - (ViewConfiguration.getMinimumFlingVelocity() >> 16), 64 - TextUtils.getOffsetBefore("", 0), (char) (KeyEvent.getMaxKeyCode() >> 16), objArr4);
|
||
|
String str2 = (String) objArr4[0];
|
||
|
Object[] objArr5 = new Object[1];
|
||
|
f((ViewConfiguration.getKeyRepeatDelay() >> 16) + 135, (TypedValue.complexToFraction(0, BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED) > BitmapDescriptorFactory.HUE_RED ? 1 : (TypedValue.complexToFraction(0, BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED) == BitmapDescriptorFactory.HUE_RED ? 0 : -1)) + 64, (char) ((Process.getThreadPriority(0) + 20) >> 6), objArr5);
|
||
|
String str3 = (String) objArr5[0];
|
||
|
Object[] objArr6 = new Object[1];
|
||
|
f(199 - View.resolveSizeAndState(0, 0, 0), (ViewConfiguration.getKeyRepeatTimeout() >> 16) + 74, (char) (TextUtils.getOffsetBefore("", 0) + 9936), objArr6);
|
||
|
String str4 = (String) objArr6[0];
|
||
|
Object[] objArr7 = new Object[1];
|
||
|
f(MotionEvent.axisFromString("") + 274, (ViewConfiguration.getWindowTouchSlop() >> 8) + 5, (char) (ViewConfiguration.getWindowTouchSlop() >> 8), objArr7);
|
||
|
String str5 = (String) objArr7[0];
|
||
|
Object[] objArr8 = new Object[1];
|
||
|
f(278 - Gravity.getAbsoluteGravity(0, 0), 37 - (AudioTrack.getMaxVolume() > BitmapDescriptorFactory.HUE_RED ? 1 : (AudioTrack.getMaxVolume() == BitmapDescriptorFactory.HUE_RED ? 0 : -1)), (char) (33800 - (ViewConfiguration.getWindowTouchSlop() >> 8)), objArr8);
|
||
|
Object[] objArr9 = {applicationContext, str, str2, str3, str4, true, str5, (String) objArr8[0]};
|
||
|
Object obj2 = xzZ.y.get(1656189573);
|
||
|
if (obj2 == null) {
|
||
|
obj2 = ((Class) xzZ.c(Process.getGidForName("") + 488, View.resolveSizeAndState(0, 0, 0) + 5, (char) (AndroidCharacter.getMirror('0') - '0'))).getMethod("e", Context.class, String.class, String.class, String.class, String.class, Boolean.TYPE, String.class, String.class);
|
||
|
xzZ.y.put(1656189573, obj2);
|
||
|
}
|
||
|
((Method) obj2).invoke(invoke, objArr9);
|
||
|
} catch (Throwable th) {
|
||
|
Throwable cause = th.getCause();
|
||
|
if (cause == null) {
|
||
|
throw th;
|
||
|
}
|
||
|
throw cause;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
static void d() {
|
||
|
a = new char[]{4046, 63081, 64667, 58149, 59744, 61326, 54843, 56345, 49792, 51508, 53009, 46535, 48189, 41544, 43260, 44818, 38236, 39924, 36799, 30211, 31959, 25411, 26902, 36835, 30285, 31926, 25416, 26945, 28665, 22084, 23595, 17136, 18691, 20336, 13707, 15361, 8760, 10449, 12082, 5424, 7113, 560, 2194, 3777, 62766, 64451, 57843, 59508, 61068, 54433, 56159, 49617, 51171, 52742, 46267, 47843, 41295, 42938, 44571, 37908, 39679, 33088, 34600, 36256, 29710, 31355, 24799, 26449, 28002, 21383, 23102, 36791, 30232, 31924, 25423, 26948, 28664, 22038, 23667, 17143, 18703, 20336, 13788, 15360, 8812, 10453, 12091, 5476, 7118, 563, 2200, 3729, 62764, 64451, 57854, 59425, 61068, 54514, 56073, 49536, 51171, 52818, 46258, 47845, 41293, 42935, 44619, 37959, 39586, 33088, 34600, 36260, 29784, 31267, 24796, 26375, 28011, 21460, 23144, 16438, 18114, 19812, 13213, 14737, 8226, 9879, 11432, 4906, 6617, 8179, 1618, 3204, 62136, 63747, 65519, 36787, 30274, 31922, 25369, 26899, 28585, 22087, 23599, 17056, 18691, 20337, 13711, 15440, 8814, 10450, 12082, 5427, 7064, 612, 2202, 3779, 62762, 64405, 57848, 59505, 61058, 54436, 56079, 49546, 51180, 52827, 46318, 47846, 41240, 42979, 44575, 37959, 39592, 33043, 34683, 36263, 29706, 31351, 24793, 26452, 27961, 21460, 23151, 16432, 18079, 19760, 13202, 14788, 8227, 9874, 11436, 4898, 6619, 8100, 1547, 3207, 62178, 63745, 65469, 43370, 20702, 23078, 17802, 20433, 18800, 28893, 31413, 25649, 28547, 27123, 4951, 6785, 1253, 3679, 2487, 13287, 15704, 9393, 11795, 10307, 54182, 56592, 51067, 52908, 51201, 62012, 64974, 59146, 57720, 59607, 37435, 40054, 34761, 33075, 34953, 45782, 48228, 42901, 41455, 43811, 21144, 23798, 17993, 16787, 19455, 30035, 31912, 26343, 24580, 27569, 5397, 8015, 1765, 19, 2666, 13739, 16197, 14715, 8404, 10757, 54383, 57281, 55598, 49965, 51932, 62560, 65493, 63943, 58172, 60055, 38132, 40502, 39321, 36843, 30292, 31930, 25348, 26946, 3007, 61971, 63672, 59158, 60702, 60331, 53790, 55410, 50871, 52484, 52090, 45447, 47192, 42623, 44254, 43824, 37227, 40899, 34343, 36035, 35480, 29047, 32713, 26095, 27688, 27345, 20728, 24323, 17805, 17335, 18953, 12471, 16110, 9543, 9147, 10823};
|
||
|
c = 60377424634803834L;
|
||
|
}
|
||
|
|
||
|
public static void setContext(Context context) {
|
||
|
int i = 2 % 2;
|
||
|
int i2 = e;
|
||
|
int i3 = i2 + 123;
|
||
|
b = i3 % 128;
|
||
|
int i4 = i3 % 2;
|
||
|
nA = context;
|
||
|
if (i4 == 0) {
|
||
|
throw null;
|
||
|
}
|
||
|
int i5 = i2 + 27;
|
||
|
b = i5 % 128;
|
||
|
int i6 = i5 % 2;
|
||
|
}
|
||
|
|
||
|
public static Context getContext() {
|
||
|
int i = 2 % 2;
|
||
|
int i2 = b + 99;
|
||
|
int i3 = i2 % 128;
|
||
|
e = i3;
|
||
|
int i4 = i2 % 2;
|
||
|
Context context = nA;
|
||
|
int i5 = i3 + 97;
|
||
|
b = i5 % 128;
|
||
|
if (i5 % 2 != 0) {
|
||
|
return context;
|
||
|
}
|
||
|
throw null;
|
||
|
}
|
||
|
|
||
|
static {
|
||
|
b = 1;
|
||
|
d();
|
||
|
int i = e + 55;
|
||
|
b = i % 128;
|
||
|
if (i % 2 != 0) {
|
||
|
return;
|
||
|
}
|
||
|
Object obj = null;
|
||
|
obj.hashCode();
|
||
|
throw null;
|
||
|
}
|
||
|
}
|