正在查看: Tuna Cash v1.0.0 应用的 LivenessActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: Tuna Cash v1.0.0 应用的 LivenessActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package aai.liveness.activity;
import LLLli.lIiiLli;
import LLiIl.LLiIl;
import LLiIl.lLILIl;
import LLiIl.llLii;
import LlLlL.IiLIL;
import LlLlL.LILlLi;
import LlLlL.iiIiiI;
import LlLlL.lLILl;
import a3d2025050999291218703.ILLiI;
import a3d2025050999291218703.LIili;
import a3d2025050999291218703.LlLiILL;
import a3d2025050999291218703.iLiLiI;
import a3d2025050999291218703.iLilI;
import a3d2025050999291218703.ilLll;
import a3d2025050999291218703.lilLl;
import aai.liveness.LivenessView;
import android.app.ProgressDialog;
import android.content.Context;
import android.graphics.drawable.AnimationDrawable;
import android.hardware.SensorEventListener;
import android.hardware.SensorManager;
import android.os.Bundle;
import android.os.Handler;
import android.util.SparseArray;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import android.widget.CheckBox;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.compose.ui.text.input.internal.PartialGapBuffer;
import iiILli.IlIIiiI;
import iliLLil.LLILli;
import iliLLil.iiILI;
import iliLLil.liLILi;
import java.util.ArrayList;
import java.util.Iterator;
import llLii.IIIiILL;
public class LivenessActivity extends lLILl implements IIIiILL {
public static final int f1541LIILi = 0;
public SparseArray f1542IILLiL;
public ProgressDialog f1543IILliLL;
public View f1544IlIIiiI;
public View f1545IlILllI;
public TextView f1546LIili;
public ImageView f1547Liiii;
public CheckBox f1548iIllL;
public LivenessView f1549liIiIiI;
public TextView f1550lilLl;
public LivenessActivity() {
this.f1643liLILi.lIliL.LLiIl("androidx:appcompat", new LILlLi(this));
addOnContextAvailableListener(new IiLIL(this));
}
public final void ILLiI() {
LLiIl currentDetectionType = this.f1549liIiIiI.getCurrentDetectionType();
if (currentDetectionType != null) {
int ordinal = currentDetectionType.ordinal();
lLILl(ordinal != 1 ? ordinal != 2 ? ordinal != 3 ? 0 : LLILli.liveness_pos_raw : LLILli.liveness_mouse : LLILli.liveness_blink);
int ordinal2 = currentDetectionType.ordinal();
int i = ordinal2 != 1 ? ordinal2 != 2 ? ordinal2 != 3 ? -1 : iiILI.anim_frame_turn_head : iiILI.anim_frame_open_mouse : iiILI.anim_frame_blink;
AnimationDrawable animationDrawable = (AnimationDrawable) this.f1542IILLiL.get(i);
if (animationDrawable == null) {
animationDrawable = (AnimationDrawable) getResources().getDrawable(i);
this.f1542IILLiL.put(i, animationDrawable);
}
this.f1547Liiii.setImageDrawable(animationDrawable);
animationDrawable.start();
}
}
@Override
public final void LLiIl() {
LivenessView livenessView = this.f1549liIiIiI;
IlIIiiI ilIIiiI = new IlIIiiI(this, 1);
livenessView.getClass();
ilLll illll = new ilLll(12, livenessView, ilIIiiI);
lilLl lilll = livenessView.f1496lLlii;
if (lilll.LllLii()) {
illll.iiIiiI();
new Thread(new LIili(lilll, illll, 4)).start();
}
}
public final void iiILI() {
throw new UnsupportedOperationException("Method not decompiled: aai.liveness.activity.LivenessActivity.iiILI():void");
}
@Override
public final void ilLll(String str, String str2, boolean z) {
ProgressDialog progressDialog = this.f1543IILliLL;
if (progressDialog != null) {
progressDialog.dismiss();
}
if (z) {
liLILi(null);
return;
}
if ("NO_RESPONSE".equals(str)) {
str2 = getString(LLILli.liveness_failed_reason_auth_failed);
}
ILLiI iLLiI = new ILLiI((Context) this);
Object obj = iLLiI.f1303ILLiI;
((LlLlL.ilLll) obj).f1259ilLll = str2;
int i = LLILli.liveness_perform;
iliLLil.IiLIL iiLIL = new iliLLil.IiLIL(this, str2);
LlLlL.ilLll illll = (LlLlL.ilLll) obj;
illll.f1254IiLlI = illll.f1262lLILIl.getText(i);
((LlLlL.ilLll) iLLiI.f1303ILLiI).f1252IILii = iiLIL;
iiIiiI iliLLil2 = iLLiI.iliLLil();
if (isFinishing() || isDestroyed()) {
return;
}
iliLLil2.show();
}
@Override
public final void iliLLil(long j) {
int i = (int) (j / 1000);
this.f1546LIili.setText(i + "s");
}
@Override
public final void lLILIl() {
ProgressDialog progressDialog = this.f1543IILliLL;
if (progressDialog != null) {
progressDialog.dismiss();
}
if (isFinishing() || isDestroyed()) {
return;
}
ProgressDialog progressDialog2 = new ProgressDialog(this);
this.f1543IILliLL = progressDialog2;
progressDialog2.setMessage(getString(LLILli.liveness_auth_check));
this.f1543IILliLL.setCanceledOnTouchOutside(false);
this.f1543IILliLL.show();
}
public final void lLILl(int i) {
this.f1550lilLl.setText(i);
}
public final void onRequestPermissionsResult(int i, String[] strArr, int[] iArr) {
super.onRequestPermissionsResult(i, strArr, iArr);
if (i != 1991 || lIiiLli.lLILIl(this, new String[]{"android.permission.CAMERA"}[0]) == 0) {
return;
}
ILLiI iLLiI = new ILLiI((Context) this);
((LlLlL.ilLll) iLLiI.f1303ILLiI).f1259ilLll = getString(LLILli.liveness_no_camera_permission);
String string = getString(LLILli.liveness_perform);
iliLLil.lLILl llill = new iliLLil.lLILl(this);
LlLlL.ilLll illll = (LlLlL.ilLll) iLLiI.f1303ILLiI;
illll.f1254IiLlI = string;
illll.f1252IILii = llill;
iiIiiI iliLLil2 = iLLiI.iliLLil();
if (isFinishing() || isDestroyed()) {
return;
}
iliLLil2.show();
}
public final void liLILi(llLii lllii) {
this.f1549liIiIiI.f1496lLlii.getClass();
if (lllii != null) {
int ordinal = lllii.ordinal();
if (ordinal == 0) {
lLILl(LLILli.liveness_no_people_face);
return;
}
if (ordinal == 1) {
lLILl(LLILli.liveness_tip_move_furthre);
return;
}
if (ordinal == 2) {
lLILl(LLILli.liveness_tip_move_closer);
return;
}
if (ordinal == 3) {
lLILl(LLILli.liveness_move_face_center);
return;
}
if (ordinal == 4) {
lLILl(LLILli.liveness_frontal);
return;
}
if (ordinal != 5) {
if (ordinal == 19) {
lLILl(LLILli.liveness_large_yaw);
return;
}
if (ordinal == 28) {
lLILl(LLILli.liveness_blink);
return;
}
switch (ordinal) {
case 7:
lLILl(LLILli.liveness_multi_faces);
break;
case 8:
lLILl(LLILli.liveness_open_eyes);
break;
case 9:
lLILl(LLILli.liveness_face_occ);
break;
case 10:
break;
case 11:
ILLiI();
break;
default:
switch (ordinal) {
case 21:
case 22:
case 23:
case 24:
lLILl(LLILli.liveness_face_move);
break;
case 25:
lLILl(LLILli.liveness_weak_light);
break;
case 26:
lLILl(LLILli.liveness_too_light);
break;
}
}
return;
}
lLILl(LLILli.liveness_still);
}
}
@Override
public final void llLii(lLILIl llilil, LLiIl lLiIl) {
String string;
int ordinal = llilil.ordinal();
if (ordinal == 1) {
lLILl(LLILli.liveness_weak_light);
return;
}
if (ordinal == 2) {
lLILl(LLILli.liveness_too_light);
return;
}
int ordinal2 = llilil.ordinal();
if (ordinal2 != 0) {
string = null;
if (ordinal2 == 3) {
int ordinal3 = lLiIl.ordinal();
if (ordinal3 == 1 || ordinal3 == 2) {
string = getString(LLILli.liveness_failed_reason_facemissing_blink_mouth);
} else if (ordinal3 == 3) {
string = getString(LLILli.liveness_failed_reason_facemissing_pos_yaw);
}
} else if (ordinal2 == 4) {
string = getString(LLILli.liveness_failed_reason_multipleface);
} else if (ordinal2 == 5) {
string = getString(LLILli.liveness_failed_reason_muchaction);
}
} else {
string = getString(LLILli.liveness_failed_reason_timeout);
}
iLilI.iiILI(string);
setResult(-1);
finish();
}
public final void onCreate(Bundle bundle) {
super.onCreate(bundle);
setContentView(liLILi.activity_liveness);
Window window = getWindow();
WindowManager.LayoutParams attributes = window.getAttributes();
attributes.screenBrightness = PartialGapBuffer.BUF_SIZE / 255.0f;
window.setAttributes(attributes);
this.f1549liIiIiI = (LivenessView) findViewById(iliLLil.ILLiI.liveness_view);
this.f1547Liiii = (ImageView) findViewById(iliLLil.ILLiI.tip_image_view);
this.f1550lilLl = (TextView) findViewById(iliLLil.ILLiI.tip_text_view);
this.f1546LIili = (TextView) findViewById(iliLLil.ILLiI.timer_text_view_camera_activity);
this.f1544IlIIiiI = findViewById(iliLLil.ILLiI.progress_layout);
this.f1548iIllL = (CheckBox) findViewById(iliLLil.ILLiI.voice_check_box);
View findViewById = findViewById(iliLLil.ILLiI.back_view_camera_activity);
this.f1545IlILllI = findViewById(iliLLil.ILLiI.text_view_loading);
findViewById.setOnClickListener(new iliLLil.iiIiiI(this, 0));
this.f1548iIllL.setChecked(this.f1549liIiIiI.f1496lLlii.f397liLLllI);
this.f1548iIllL.setOnCheckedChangeListener(new iliLLil.LILlLi(this));
this.f1542IILLiL = new SparseArray();
this.f1549liIiIiI.setLivenssCallback(this);
ArrayList arrayList = iLiLiI.f1393LILlLi;
}
@Override
public final void onDestroy() {
SensorManager sensorManager;
LivenessView livenessView = this.f1549liIiIiI;
lilLl lilll = livenessView.f1496lLlii;
synchronized (lilll) {
try {
lilll.f1524Liiii = null;
lilll.LlLiILL();
lilll.iilLIL();
Handler handler = lilll.f1534lilLl;
if (handler != null) {
handler.removeCallbacksAndMessages(null);
lilll.f1534lilLl = null;
}
ArrayList arrayList = lilll.f1522LLLIl;
if (arrayList != null && !arrayList.isEmpty()) {
Iterator it = lilll.f1522LLLIl.iterator();
while (it.hasNext()) {
SensorEventListener sensorEventListener = (llIiLil.llLii) it.next();
sensorEventListener.getClass();
try {
if (((llIiLil.llLii) sensorEventListener).LLiIl != null && (sensorManager = ((llIiLil.llLii) sensorEventListener).lIliL) != null) {
sensorManager.unregisterListener(sensorEventListener);
}
} catch (Exception unused) {
}
((llIiLil.llLii) sensorEventListener).ilLll = new StringBuilder();
((llIiLil.llLii) sensorEventListener).IiLlI = null;
}
}
ArrayList arrayList2 = lilll.f1521LIili;
if (arrayList2 != null) {
arrayList2.clear();
}
} catch (Throwable th) {
throw th;
}
}
livenessView.lLILIl("destroy");
this.f1542IILLiL.clear();
super.onDestroy();
}
@Override
public final void onDetectionFrameStateChanged(llLii lllii) {
liLILi(lllii);
}
public final void onPause() {
ProgressDialog progressDialog = this.f1543IILliLL;
if (progressDialog != null) {
progressDialog.dismiss();
}
this.f1549liIiIiI.lIliL();
super.onPause();
}
public final void onResume() {
LlLiILL llLiILL = this.f1549liIiIiI.f1496lLlii.f1527iilIlI;
if (llLiILL == null || !llLiILL.f1365liLLllI) {
int i = 0;
this.f1549liIiIiI.setVisibility(0);
this.f1550lilLl.setVisibility(0);
this.f1547Liiii.setVisibility(0);
this.f1546LIili.setText("");
this.f1546LIili.setBackgroundResource(0);
this.f1546LIili.setVisibility(0);
this.f1548iIllL.setVisibility(4);
this.f1547Liiii.setImageDrawable(null);
this.f1544IlIIiiI.setVisibility(4);
this.f1545IlILllI.setVisibility(4);
if (lIiiLli.lLILIl(this, new String[]{"android.permission.CAMERA"}[0]) == 0) {
LivenessView livenessView = this.f1549liIiIiI;
LlLiILL llLiILL2 = livenessView.f1496lLlii.f1527iilIlI;
if (llLiILL2 == null || !llLiILL2.f1365liLLllI) {
lilLl lilll = livenessView.f1496lLlii;
lilll.f1530lIlilI = false;
ArrayList arrayList = lilll.f1521LIili;
if (arrayList == null) {
IIIiILL iIIiILL = lilll.f1524Liiii;
synchronized (lilll) {
try {
ArrayList arrayList2 = iLiLiI.f1393LILlLi;
if (arrayList2 == null || arrayList2.isEmpty()) {
lilll.iilIL(iIIiILL, LLiIl.BLINK, LLiIl.POS_YAW);
} else {
LLiIl[] lLiIlArr = new LLiIl[arrayList2.size()];
while (true) {
ArrayList arrayList3 = iLiLiI.f1393LILlLi;
if (i >= arrayList3.size()) {
break;
}
lLiIlArr[i] = (LLiIl) arrayList3.get(i);
i++;
}
lilll.iilIL(iIIiILL, lLiIlArr);
}
} catch (Throwable th) {
throw th;
}
}
} else {
LLiIl[] lLiIlArr2 = new LLiIl[arrayList.size()];
lilll.f1521LIili.toArray(lLiIlArr2);
lilll.iilIL(lilll.f1524Liiii, lLiIlArr2);
}
lilll.iiIiLl();
}
}
}
super.onResume();
}
}