mirror of
https://github.com/Katana-Official/SPatch-Update.git
synced 2026-04-01 07:09:44 +08:00
Add readme&license
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
package com.keijumt.passwordview;
|
||||
|
||||
import kotlin.Metadata;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\030\n\002\030\002\n\002\020\000\n\000\n\002\020\002\n\000\n\002\020\016\n\002\b\002\bf\030\0002\0020\001J\020\020\002\032\0020\0032\006\020\004\032\0020\005H&J\b\020\006\032\0020\003H&¨\006\007"}, d2 = {"Lcom/keijumt/passwordview/ActionListener;", "", "onCompleteInput", "", "inputText", "", "onEndJudgeAnimation", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public interface ActionListener {
|
||||
void onCompleteInput(String paramString);
|
||||
|
||||
void onEndJudgeAnimation();
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\ActionListener.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
21
lib/src/main/java/com/keijumt/passwordview/BuildConfig.java
Normal file
21
lib/src/main/java/com/keijumt/passwordview/BuildConfig.java
Normal file
@@ -0,0 +1,21 @@
|
||||
package com.keijumt.passwordview;
|
||||
|
||||
public final class BuildConfig {
|
||||
public static final String APPLICATION_ID = "com.keijumt.passwordview";
|
||||
|
||||
public static final String BUILD_TYPE = "release";
|
||||
|
||||
public static final boolean DEBUG = false;
|
||||
|
||||
public static final String FLAVOR = "";
|
||||
|
||||
public static final int VERSION_CODE = 1;
|
||||
|
||||
public static final String VERSION_NAME = "1.0";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\BuildConfig.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
186
lib/src/main/java/com/keijumt/passwordview/CircleView.java
Normal file
186
lib/src/main/java/com/keijumt/passwordview/CircleView.java
Normal file
@@ -0,0 +1,186 @@
|
||||
package com.keijumt.passwordview;
|
||||
|
||||
import android.animation.Animator;
|
||||
import android.animation.AnimatorListenerAdapter;
|
||||
import android.animation.TimeInterpolator;
|
||||
import android.animation.ValueAnimator;
|
||||
import android.content.Context;
|
||||
import android.graphics.Canvas;
|
||||
import android.graphics.Paint;
|
||||
import android.util.AttributeSet;
|
||||
import android.view.View;
|
||||
import androidx.interpolator.view.animation.FastOutLinearInInterpolator;
|
||||
import java.util.HashMap;
|
||||
import kotlin.Metadata;
|
||||
import kotlin.TypeCastException;
|
||||
import kotlin.Unit;
|
||||
import kotlin.jvm.functions.Function0;
|
||||
import kotlin.jvm.internal.DefaultConstructorMarker;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000Z\n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\000\n\002\030\002\n\000\n\002\020\b\n\002\b\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\020\t\n\002\b\002\n\002\020\007\n\002\b\005\n\002\020\002\n\000\n\002\030\002\n\002\b\004\n\002\020\013\n\002\b\006\n\002\030\002\n\002\b\r\b\000\030\0002\0020\001B%\b\007\022\006\020\002\032\0020\003\022\n\b\002\020\004\032\004\030\0010\005\022\b\b\002\020\006\032\0020\007¢\006\002\020\bJ\030\020\027\032\0020\0302\020\b\002\020\031\032\n\022\004\022\0020\030\030\0010\032J\006\020\033\032\0020\007J\006\020\034\032\0020\007J\006\020\035\032\0020\007J\006\020\036\032\0020\037J \020 \032\0020\0222\006\020!\032\0020\0222\006\020\"\032\0020\0222\006\020#\032\0020\022H\002J\020\020$\032\0020\0302\006\020%\032\0020&H\025J\030\020'\032\0020\0302\006\020(\032\0020\0072\006\020)\032\0020\007H\024J\016\020*\032\0020\0302\006\020+\032\0020\007J\016\020,\032\0020\0302\006\020+\032\0020\007J\016\020-\032\0020\0302\006\020.\032\0020\017J\016\020/\032\0020\0302\006\020+\032\0020\007J\016\0200\032\0020\0302\006\0201\032\0020\022J\016\0202\032\0020\0302\006\020\026\032\0020\022R\020\020\t\032\004\030\0010\nX\016¢\006\002\n\000R\016\020\013\032\0020\fX\004¢\006\002\n\000R\016\020\r\032\0020\fX\004¢\006\002\n\000R\016\020\016\032\0020\017X\016¢\006\002\n\000R\016\020\020\032\0020\fX\004¢\006\002\n\000R\036\020\023\032\0020\0222\006\020\021\032\0020\022@BX\016¢\006\b\n\000\"\004\b\024\020\025R\016\020\026\032\0020\022X\016¢\006\002\n\000¨\0063"}, d2 = {"Lcom/keijumt/passwordview/CircleView;", "Landroid/view/View;", "context", "Landroid/content/Context;", "attrs", "Landroid/util/AttributeSet;", "defStyleAttr", "", "(Landroid/content/Context;Landroid/util/AttributeSet;I)V", "animator", "Landroid/animation/ValueAnimator;", "fillAndStrokeCirclePaint", "Landroid/graphics/Paint;", "fillCirclePaint", "inputAndRemoveAnimationDuration", "", "outLinePaint", "value", "", "progress", "setProgress", "(F)V", "radius", "animateAndInvoke", "", "onEnd", "Lkotlin/Function0;", "getFillAndStrokeCircleColor", "getFillCircleColor", "getOutLineColor", "isAnimating", "", "lerp", "a", "b", "t", "onDraw", "canvas", "Landroid/graphics/Canvas;", "onMeasure", "widthMeasureSpec", "heightMeasureSpec", "setFillAndStrokeCircleColor", "color", "setFillCircleColor", "setInputAndRemoveAnimationDuration", "duration", "setOutLineColor", "setOutlineStrokeWidth", "strokeWidth", "setRadius", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class CircleView extends View {
|
||||
private HashMap _$_findViewCache;
|
||||
|
||||
private ValueAnimator animator;
|
||||
|
||||
private final Paint fillAndStrokeCirclePaint;
|
||||
|
||||
private final Paint fillCirclePaint;
|
||||
|
||||
private long inputAndRemoveAnimationDuration;
|
||||
|
||||
private final Paint outLinePaint;
|
||||
|
||||
private float progress;
|
||||
|
||||
private float radius;
|
||||
|
||||
public CircleView(Context paramContext) { this(paramContext, null, 0, 6, null); }
|
||||
|
||||
public CircleView(Context paramContext, AttributeSet paramAttributeSet) { this(paramContext, paramAttributeSet, 0, 4, null); }
|
||||
|
||||
public CircleView(Context paramContext, AttributeSet paramAttributeSet, int paramInt) {
|
||||
super(paramContext, paramAttributeSet, paramInt);
|
||||
Paint paint = new Paint(1);
|
||||
paint.setColor(-7829368);
|
||||
paint.setStrokeWidth(4.0F);
|
||||
paint.setStyle(Paint.Style.STROKE);
|
||||
this.outLinePaint = paint;
|
||||
paint = new Paint(1);
|
||||
paint.setColor(-1);
|
||||
paint.setStyle(Paint.Style.FILL);
|
||||
this.fillCirclePaint = paint;
|
||||
paint = new Paint(1);
|
||||
paint.setColor(-16777216);
|
||||
paint.setStyle(Paint.Style.FILL_AND_STROKE);
|
||||
this.fillAndStrokeCirclePaint = paint;
|
||||
this.radius = 16.0F;
|
||||
this.inputAndRemoveAnimationDuration = 200L;
|
||||
}
|
||||
|
||||
private final float lerp(float paramFloat1, float paramFloat2, float paramFloat3) { return paramFloat1 + (paramFloat2 - paramFloat1) * paramFloat3; }
|
||||
|
||||
private final void setProgress(float paramFloat) {
|
||||
this.progress = paramFloat;
|
||||
postInvalidateOnAnimation();
|
||||
}
|
||||
|
||||
public void _$_clearFindViewByIdCache() {
|
||||
HashMap hashMap = this._$_findViewCache;
|
||||
if (hashMap != null)
|
||||
hashMap.clear();
|
||||
}
|
||||
|
||||
public View _$_findCachedViewById(int paramInt) {
|
||||
if (this._$_findViewCache == null)
|
||||
this._$_findViewCache = new HashMap<Object, Object>();
|
||||
View view2 = (View)this._$_findViewCache.get(Integer.valueOf(paramInt));
|
||||
View view1 = view2;
|
||||
if (view2 == null) {
|
||||
view1 = findViewById(paramInt);
|
||||
this._$_findViewCache.put(Integer.valueOf(paramInt), view1);
|
||||
}
|
||||
return view1;
|
||||
}
|
||||
|
||||
public final void animateAndInvoke(Function0<Unit> paramFunction0) {
|
||||
if (this.animator != null)
|
||||
return;
|
||||
float f2 = this.progress;
|
||||
float f1 = 0.0F;
|
||||
if (f2 == 0.0F)
|
||||
f1 = 1.0F;
|
||||
ValueAnimator valueAnimator = ValueAnimator.ofFloat(new float[] { this.progress, f1 });
|
||||
valueAnimator.setDuration(this.inputAndRemoveAnimationDuration);
|
||||
valueAnimator.addUpdateListener(new CircleView$animateAndInvoke$$inlined$apply$lambda$1(paramFunction0));
|
||||
valueAnimator.addListener((Animator.AnimatorListener)new CircleView$animateAndInvoke$$inlined$apply$lambda$2(paramFunction0));
|
||||
valueAnimator.setInterpolator((TimeInterpolator)new FastOutLinearInInterpolator());
|
||||
this.animator = valueAnimator;
|
||||
if (valueAnimator != null)
|
||||
valueAnimator.start();
|
||||
}
|
||||
|
||||
public final int getFillAndStrokeCircleColor() { return this.fillAndStrokeCirclePaint.getColor(); }
|
||||
|
||||
public final int getFillCircleColor() { return this.fillCirclePaint.getColor(); }
|
||||
|
||||
public final int getOutLineColor() { return this.outLinePaint.getColor(); }
|
||||
|
||||
public final boolean isAnimating() { return (this.animator != null); }
|
||||
|
||||
protected void onDraw(Canvas paramCanvas) {
|
||||
Intrinsics.checkParameterIsNotNull(paramCanvas, "canvas");
|
||||
float f1 = this.outLinePaint.getStrokeWidth() / 2;
|
||||
float f2 = this.radius;
|
||||
paramCanvas.drawCircle(f2 + f1, f2 + f1, lerp(f2 - f1, 0.0F, this.progress), this.fillCirclePaint);
|
||||
f2 = this.radius;
|
||||
paramCanvas.drawCircle(f2 + f1, f2 + f1, lerp(f2, 0.0F, this.progress), this.outLinePaint);
|
||||
f2 = this.radius;
|
||||
paramCanvas.drawCircle(f2 + f1, f2 + f1, lerp(0.0F, f2 + f1, this.progress), this.fillAndStrokeCirclePaint);
|
||||
}
|
||||
|
||||
protected void onMeasure(int paramInt1, int paramInt2) {
|
||||
float f1 = this.radius;
|
||||
float f2 = 2;
|
||||
setMeasuredDimension((int)(f1 * f2 + this.outLinePaint.getStrokeWidth()), (int)(this.radius * f2 + this.outLinePaint.getStrokeWidth()));
|
||||
}
|
||||
|
||||
public final void setFillAndStrokeCircleColor(int paramInt) {
|
||||
this.fillAndStrokeCirclePaint.setColor(paramInt);
|
||||
postInvalidateOnAnimation();
|
||||
}
|
||||
|
||||
public final void setFillCircleColor(int paramInt) {
|
||||
this.fillCirclePaint.setColor(paramInt);
|
||||
postInvalidateOnAnimation();
|
||||
}
|
||||
|
||||
public final void setInputAndRemoveAnimationDuration(long paramLong) { this.inputAndRemoveAnimationDuration = paramLong; }
|
||||
|
||||
public final void setOutLineColor(int paramInt) {
|
||||
this.outLinePaint.setColor(paramInt);
|
||||
postInvalidateOnAnimation();
|
||||
}
|
||||
|
||||
public final void setOutlineStrokeWidth(float paramFloat) { this.outLinePaint.setStrokeWidth(paramFloat); }
|
||||
|
||||
public final void setRadius(float paramFloat) {
|
||||
this.radius = paramFloat;
|
||||
invalidate();
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\024\n\000\n\002\020\002\n\000\n\002\030\002\n\002\b\002\n\002\b\003\020\000\032\0020\0012\016\020\002\032\n \004*\004\030\0010\0030\003H\n¢\006\002\b\005¨\006\006"}, d2 = {"<anonymous>", "", "it", "Landroid/animation/ValueAnimator;", "kotlin.jvm.PlatformType", "onAnimationUpdate", "com/keijumt/passwordview/CircleView$animateAndInvoke$1$1"}, k = 3, mv = {1, 1, 13})
|
||||
static final class CircleView$animateAndInvoke$$inlined$apply$lambda$1 implements ValueAnimator.AnimatorUpdateListener {
|
||||
CircleView$animateAndInvoke$$inlined$apply$lambda$1(Function0 param1Function0) {}
|
||||
|
||||
public final void onAnimationUpdate(ValueAnimator param1ValueAnimator) {
|
||||
CircleView circleView = CircleView.this;
|
||||
Intrinsics.checkExpressionValueIsNotNull(param1ValueAnimator, "it");
|
||||
Object object = param1ValueAnimator.getAnimatedValue();
|
||||
if (object != null) {
|
||||
circleView.setProgress(((Float)object).floatValue());
|
||||
return;
|
||||
}
|
||||
throw new TypeCastException("null cannot be cast to non-null type kotlin.Float");
|
||||
}
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\027\n\000\n\002\030\002\n\000\n\002\020\002\n\000\n\002\030\002\n\000*\001\000\b\n\030\0002\0020\001J\022\020\002\032\0020\0032\b\020\004\032\004\030\0010\005H\026¨\006\006¸\006\000"}, d2 = {"com/keijumt/passwordview/CircleView$animateAndInvoke$1$2", "Landroid/animation/AnimatorListenerAdapter;", "onAnimationEnd", "", "animation", "Landroid/animation/Animator;", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class CircleView$animateAndInvoke$$inlined$apply$lambda$2 extends AnimatorListenerAdapter {
|
||||
CircleView$animateAndInvoke$$inlined$apply$lambda$2(Function0 param1Function0) {}
|
||||
|
||||
public void onAnimationEnd(Animator param1Animator) {
|
||||
CircleView.this.animator = (ValueAnimator)null;
|
||||
Function0 function0 = this.$onEnd$inlined;
|
||||
if (function0 != null)
|
||||
Unit unit = (Unit)function0.invoke();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\CircleView.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
423
lib/src/main/java/com/keijumt/passwordview/PasswordView.java
Normal file
423
lib/src/main/java/com/keijumt/passwordview/PasswordView.java
Normal file
@@ -0,0 +1,423 @@
|
||||
package com.keijumt.passwordview;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.TypedArray;
|
||||
import android.util.AttributeSet;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.LinearLayout;
|
||||
import com.keijumt.passwordview.animation.Animator;
|
||||
import com.keijumt.passwordview.animation.FillAndStrokeColorChangeAnimation;
|
||||
import com.keijumt.passwordview.animation.FillColorChangeAnimation;
|
||||
import com.keijumt.passwordview.animation.ShakeAnimator;
|
||||
import com.keijumt.passwordview.animation.SpringAnimator;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import kotlin.Metadata;
|
||||
import kotlin.Unit;
|
||||
import kotlin.collections.CollectionsKt;
|
||||
import kotlin.jvm.functions.Function0;
|
||||
import kotlin.jvm.internal.DefaultConstructorMarker;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
import kotlin.jvm.internal.Lambda;
|
||||
import kotlin.text.StringsKt;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000^\n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\000\n\002\030\002\n\000\n\002\020\b\n\002\b\002\n\002\030\002\n\000\n\002\030\002\n\002\b\003\n\002\020!\n\002\030\002\n\000\n\002\020\t\n\002\b\002\n\002\020\007\n\002\b\006\n\002\020\016\n\002\b\017\n\002\020\002\n\002\b\004\n\002\030\002\n\002\b\020\030\000 A2\0020\001:\001AB%\b\007\022\006\020\002\032\0020\003\022\n\b\002\020\004\032\004\030\0010\005\022\b\b\002\020\006\032\0020\007¢\006\002\020\bJ\020\020,\032\0020-2\006\020.\032\0020\007H\002J\016\020/\032\0020-2\006\0200\032\0020\035J\032\0201\032\004\030\001022\006\0203\032\0020\0072\006\020.\032\0020\007H\002J\006\0204\032\0020-J\020\0204\032\0020-2\006\0205\032\0020\023H\002J\030\0206\032\0020-2\006\0205\032\0020\0232\006\0207\032\0020\007H\002J\030\0208\032\0020-2\006\0205\032\0020\0232\006\0207\032\0020\007H\002J\030\0209\032\0020-2\006\020:\032\0020\0352\006\020;\032\0020\035H\002J\006\020<\032\0020-J\020\020<\032\0020-2\006\0205\032\0020\023H\002J\006\020=\032\0020-J\006\020>\032\0020-J\006\020?\032\0020-J\016\020@\032\0020-2\006\020\t\032\0020\nR\020\020\t\032\004\030\0010\nX\016¢\006\002\n\000R\026\020\013\032\n \r*\004\030\0010\f0\fX\004¢\006\002\n\000R\016\020\016\032\0020\007X\004¢\006\002\n\000R\024\020\017\032\b\022\004\022\0020\0210\020X\004¢\006\002\n\000R\016\020\022\032\0020\023X\004¢\006\002\n\000R\016\020\024\032\0020\023X\004¢\006\002\n\000R\016\020\025\032\0020\026X\004¢\006\002\n\000R\016\020\027\032\0020\007X\004¢\006\002\n\000R\016\020\030\032\0020\026X\004¢\006\002\n\000R\016\020\031\032\0020\023X\004¢\006\002\n\000R\016\020\032\032\0020\007X\004¢\006\002\n\000R\016\020\033\032\0020\026X\004¢\006\002\n\000R\036\020\036\032\0020\0352\006\020\034\032\0020\035@BX\016¢\006\b\n\000\"\004\b\037\020 R\016\020!\032\0020\023X\004¢\006\002\n\000R\016\020\"\032\0020\007X\004¢\006\002\n\000R\016\020#\032\0020\007X\004¢\006\002\n\000R\016\020$\032\0020\007X\004¢\006\002\n\000R\016\020%\032\0020\026X\004¢\006\002\n\000R$\020&\032\0020\0072\006\020\034\032\0020\007@FX\016¢\006\016\n\000\032\004\b'\020(\"\004\b)\020*R\016\020+\032\0020\026X\004¢\006\002\n\000¨\006B"}, d2 = {"Lcom/keijumt/passwordview/PasswordView;", "Landroid/widget/LinearLayout;", "context", "Landroid/content/Context;", "attrs", "Landroid/util/AttributeSet;", "defStyleAttr", "", "(Landroid/content/Context;Landroid/util/AttributeSet;I)V", "actionListener", "Lcom/keijumt/passwordview/ActionListener;", "array", "Landroid/content/res/TypedArray;", "kotlin.jvm.PlatformType", "betweenMargin", "circleViews", "", "Lcom/keijumt/passwordview/CircleView;", "colorChangeAnimationDuration", "", "correctAnimationDuration", "correctBottom", "", "correctColor", "correctTop", "incorrectAnimationDuration", "incorrectColor", "incorrectMaxWidth", "value", "", "input", "setInput", "(Ljava/lang/String;)V", "inputAndRemoveAnimationDuration", "inputColor", "notInputColor", "outlineColor", "outlineStrokeWidth", "passwordCount", "getPasswordCount", "()I", "setPasswordCount", "(I)V", "radius", "addCircleView", "", "circleCount", "appendInputText", "text", "calcMargin", "Landroid/view/ViewGroup$LayoutParams;", "circleIndex", "correctAnimation", "duration", "fillAndStrokeColorChangeAnimation", "color", "fillColorChangeAnimation", "handleInputAnimate", "oldInput", "newInput", "incorrectAnimation", "removeInputText", "removeListener", "reset", "setListener", "Companion", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class PasswordView extends LinearLayout {
|
||||
public static final Companion Companion = new Companion(null);
|
||||
|
||||
private static final int DEFAULT_BETWEEN_MARGIN = 72;
|
||||
|
||||
private static final int DEFAULT_CIRCLE_COUNT = 4;
|
||||
|
||||
private static final int DEFAULT_COLOR_CHANGE_ANIMATION_DURATION = 200;
|
||||
|
||||
private static final int DEFAULT_CORRECT_ANIMATION_DURATION = 150;
|
||||
|
||||
private static final float DEFAULT_CORRECT_BOTTOM = 15.0F;
|
||||
|
||||
private static final int DEFAULT_CORRECT_COLOR = -16711936;
|
||||
|
||||
private static final float DEFAULT_CORRECT_TOP = 40.0F;
|
||||
|
||||
private static final int DEFAULT_INCORRECT_ANIMATION_DURATION = 400;
|
||||
|
||||
private static final int DEFAULT_INCORRECT_COLOR = -65536;
|
||||
|
||||
private static final float DEFAULT_INCORRECT_MAX_WIDTH = 40.0F;
|
||||
|
||||
private static final int DEFAULT_INPUT_AND_REMOVE_ANIMATION_DURATION = 200;
|
||||
|
||||
private static final int DEFAULT_INPUT_COLOR = -16777216;
|
||||
|
||||
private static final int DEFAULT_NOT_INPUT_COLOR = -1;
|
||||
|
||||
private static final int DEFAULT_OUTLINE_COLOR = -7829368;
|
||||
|
||||
private static final float DEFAULT_OUTLINE_STROKE_WIDTH = 4.0F;
|
||||
|
||||
private static final float DEFAULT_RADIUS = 20.0F;
|
||||
|
||||
private HashMap _$_findViewCache;
|
||||
|
||||
private ActionListener actionListener;
|
||||
|
||||
private final TypedArray array;
|
||||
|
||||
private final int betweenMargin;
|
||||
|
||||
private final List<CircleView> circleViews;
|
||||
|
||||
private final long colorChangeAnimationDuration;
|
||||
|
||||
private final long correctAnimationDuration;
|
||||
|
||||
private final float correctBottom;
|
||||
|
||||
private final int correctColor;
|
||||
|
||||
private final float correctTop;
|
||||
|
||||
private final long incorrectAnimationDuration;
|
||||
|
||||
private final int incorrectColor;
|
||||
|
||||
private final float incorrectMaxWidth;
|
||||
|
||||
private String input;
|
||||
|
||||
private final long inputAndRemoveAnimationDuration;
|
||||
|
||||
private final int inputColor;
|
||||
|
||||
private final int notInputColor;
|
||||
|
||||
private final int outlineColor;
|
||||
|
||||
private final float outlineStrokeWidth;
|
||||
|
||||
private int passwordCount;
|
||||
|
||||
private final float radius;
|
||||
|
||||
public PasswordView(Context paramContext) { this(paramContext, null, 0, 6, null); }
|
||||
|
||||
public PasswordView(Context paramContext, AttributeSet paramAttributeSet) { this(paramContext, paramAttributeSet, 0, 4, null); }
|
||||
|
||||
public PasswordView(Context paramContext, AttributeSet paramAttributeSet, int paramInt) {
|
||||
super(paramContext, paramAttributeSet, paramInt);
|
||||
TypedArray typedArray = paramContext.obtainStyledAttributes(paramAttributeSet, R.styleable.PasswordView);
|
||||
this.array = typedArray;
|
||||
this.passwordCount = typedArray.getInteger(R.styleable.PasswordView_password_count, 4);
|
||||
this.radius = this.array.getDimension(R.styleable.PasswordView_password_radius, 20.0F);
|
||||
this.betweenMargin = this.array.getDimensionPixelOffset(R.styleable.PasswordView_password_between_margin, 72);
|
||||
this.inputColor = this.array.getColor(R.styleable.PasswordView_password_input_color, -16777216);
|
||||
this.notInputColor = this.array.getColor(R.styleable.PasswordView_password_input_color, -1);
|
||||
this.outlineColor = this.array.getColor(R.styleable.PasswordView_password_outline_color, -7829368);
|
||||
this.correctColor = this.array.getColor(R.styleable.PasswordView_password_correct_color, -16711936);
|
||||
this.incorrectColor = this.array.getColor(R.styleable.PasswordView_password_incorrect_color, -65536);
|
||||
this.correctAnimationDuration = this.array.getInteger(R.styleable.PasswordView_password_correct_duration, 150);
|
||||
this.incorrectAnimationDuration = this.array.getInteger(R.styleable.PasswordView_password_correct_duration, 400);
|
||||
this.colorChangeAnimationDuration = this.array.getInteger(R.styleable.PasswordView_password_color_change_duration, 200);
|
||||
this.inputAndRemoveAnimationDuration = this.array.getInteger(R.styleable.PasswordView_password_input_and_remove_duration, 200);
|
||||
this.correctTop = this.array.getDimension(R.styleable.PasswordView_password_correct_top, 40.0F);
|
||||
this.correctBottom = this.array.getDimension(R.styleable.PasswordView_password_correct_bottom, 15.0F);
|
||||
this.incorrectMaxWidth = this.array.getDimension(R.styleable.PasswordView_password_incorrect_max_width, 40.0F);
|
||||
this.outlineStrokeWidth = this.array.getDimension(R.styleable.PasswordView_password_outline_stroke_width, 4.0F);
|
||||
this.circleViews = new ArrayList<CircleView>();
|
||||
this.input = "";
|
||||
this.array.recycle();
|
||||
setOrientation(0);
|
||||
addCircleView(this.passwordCount);
|
||||
}
|
||||
|
||||
private final void addCircleView(int paramInt) {
|
||||
removeAllViews();
|
||||
for (int i = 0; i < paramInt; i++) {
|
||||
Context context = getContext();
|
||||
Intrinsics.checkExpressionValueIsNotNull(context, "context");
|
||||
CircleView circleView = new CircleView(context, null, 0, 6, null);
|
||||
circleView.setOutLineColor(this.outlineColor);
|
||||
circleView.setOutlineStrokeWidth(this.outlineStrokeWidth);
|
||||
circleView.setFillCircleColor(this.notInputColor);
|
||||
circleView.setFillAndStrokeCircleColor(this.inputColor);
|
||||
circleView.setInputAndRemoveAnimationDuration(this.inputAndRemoveAnimationDuration);
|
||||
circleView.setRadius(this.radius);
|
||||
circleView.setLayoutParams(calcMargin(i, paramInt));
|
||||
addView(circleView);
|
||||
this.circleViews.add(circleView);
|
||||
}
|
||||
}
|
||||
|
||||
private final ViewGroup.LayoutParams calcMargin(int paramInt1, int paramInt2) {
|
||||
if (paramInt2 >= 0) {
|
||||
if (paramInt1 >= 0) {
|
||||
if (paramInt2 == 0)
|
||||
return null;
|
||||
int i = this.betweenMargin / 2;
|
||||
int j = (int)(this.incorrectMaxWidth / 2);
|
||||
Object object = new LinearLayout.LayoutParams(getWidth(), getHeight());
|
||||
object.topMargin = (int)this.correctTop;
|
||||
object.bottomMargin = (int)this.correctBottom;
|
||||
if (paramInt2 == 1) {
|
||||
object.leftMargin = j;
|
||||
object.rightMargin = j;
|
||||
return (ViewGroup.LayoutParams)object;
|
||||
}
|
||||
if (paramInt2 == 2) {
|
||||
if (paramInt1 != 0) {
|
||||
if (paramInt1 == 1) {
|
||||
object.leftMargin = i;
|
||||
object.rightMargin = j;
|
||||
return (ViewGroup.LayoutParams)object;
|
||||
}
|
||||
object = new StringBuilder();
|
||||
object.append("circleIndex:");
|
||||
object.append(paramInt1);
|
||||
object.append(" must be greater than or equal to 0");
|
||||
throw (Throwable)new IllegalArgumentException(object.toString());
|
||||
}
|
||||
object.leftMargin = j;
|
||||
object.rightMargin = i;
|
||||
return (ViewGroup.LayoutParams)object;
|
||||
}
|
||||
if (paramInt1 == 0) {
|
||||
object.leftMargin = j;
|
||||
object.rightMargin = i;
|
||||
return (ViewGroup.LayoutParams)object;
|
||||
}
|
||||
if (1 <= paramInt1 && --paramInt2 > paramInt1) {
|
||||
object.leftMargin = i;
|
||||
object.rightMargin = i;
|
||||
return (ViewGroup.LayoutParams)object;
|
||||
}
|
||||
if (paramInt1 == paramInt2) {
|
||||
object.leftMargin = i;
|
||||
object.rightMargin = j;
|
||||
return (ViewGroup.LayoutParams)object;
|
||||
}
|
||||
object = new StringBuilder();
|
||||
object.append("circleIndex:");
|
||||
object.append(paramInt1);
|
||||
object.append(" must be greater than or equal to 0");
|
||||
throw (Throwable)new IllegalArgumentException(object.toString());
|
||||
}
|
||||
StringBuilder stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("circleIndex:");
|
||||
stringBuilder1.append(paramInt1);
|
||||
stringBuilder1.append(" must be greater than or equal to 0");
|
||||
throw (Throwable)new IllegalArgumentException(stringBuilder1.toString());
|
||||
}
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("passwordCount:");
|
||||
stringBuilder.append(paramInt2);
|
||||
stringBuilder.append(" must be greater than or equal to 0");
|
||||
throw (Throwable)new IllegalArgumentException(stringBuilder.toString());
|
||||
}
|
||||
|
||||
private final void correctAnimation(long paramLong) {
|
||||
Iterator<CircleView> iterator = this.circleViews.iterator();
|
||||
for (int i = 0; iterator.hasNext(); i++) {
|
||||
SpringAnimator springAnimator = (SpringAnimator)iterator.next();
|
||||
if (i)
|
||||
CollectionsKt.throwIndexOverflow();
|
||||
springAnimator = new SpringAnimator((CircleView)springAnimator);
|
||||
springAnimator.setDuration(paramLong);
|
||||
springAnimator.setStartDelay((i * 40));
|
||||
springAnimator.setMoveTopY(this.correctTop);
|
||||
springAnimator.setMoveBottomY(this.correctBottom);
|
||||
springAnimator.addListener(new PasswordView$correctAnimation$$inlined$forEachIndexed$lambda$1(this, paramLong));
|
||||
springAnimator.start();
|
||||
}
|
||||
}
|
||||
|
||||
private final void fillAndStrokeColorChangeAnimation(long paramLong, int paramInt) {
|
||||
Iterator<CircleView> iterator = this.circleViews.iterator();
|
||||
while (iterator.hasNext()) {
|
||||
FillAndStrokeColorChangeAnimation fillAndStrokeColorChangeAnimation = new FillAndStrokeColorChangeAnimation(iterator.next());
|
||||
fillAndStrokeColorChangeAnimation.setDuration(paramLong);
|
||||
fillAndStrokeColorChangeAnimation.setToColor(paramInt);
|
||||
fillAndStrokeColorChangeAnimation.start();
|
||||
}
|
||||
}
|
||||
|
||||
private final void fillColorChangeAnimation(long paramLong, int paramInt) {
|
||||
Iterator<CircleView> iterator = this.circleViews.iterator();
|
||||
while (iterator.hasNext()) {
|
||||
FillColorChangeAnimation fillColorChangeAnimation = new FillColorChangeAnimation(iterator.next());
|
||||
fillColorChangeAnimation.setDuration(paramLong);
|
||||
fillColorChangeAnimation.setToColor(paramInt);
|
||||
fillColorChangeAnimation.start();
|
||||
}
|
||||
}
|
||||
|
||||
private final void handleInputAnimate(String paramString1, String paramString2) {
|
||||
if (paramString2.length() > paramString1.length()) {
|
||||
int i = paramString1.length();
|
||||
int j = paramString2.length();
|
||||
while (i < j) {
|
||||
((CircleView)this.circleViews.get(i)).animateAndInvoke(new PasswordView$handleInputAnimate$1(paramString2));
|
||||
i++;
|
||||
}
|
||||
} else {
|
||||
int i = paramString2.length();
|
||||
int j = paramString1.length();
|
||||
while (i < j) {
|
||||
CircleView.animateAndInvoke$default(this.circleViews.get(i), null, 1, null);
|
||||
i++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private final void incorrectAnimation(long paramLong) {
|
||||
Iterator<CircleView> iterator = this.circleViews.iterator();
|
||||
for (int i = 0; iterator.hasNext(); i++) {
|
||||
ShakeAnimator shakeAnimator = (ShakeAnimator)iterator.next();
|
||||
if (i)
|
||||
CollectionsKt.throwIndexOverflow();
|
||||
shakeAnimator = new ShakeAnimator((CircleView)shakeAnimator);
|
||||
shakeAnimator.setDuration(paramLong);
|
||||
shakeAnimator.setShakeMaxWidth((int)this.incorrectMaxWidth);
|
||||
shakeAnimator.setStartDelay((i * 40));
|
||||
shakeAnimator.addListener(new PasswordView$incorrectAnimation$$inlined$forEachIndexed$lambda$1(this, paramLong));
|
||||
shakeAnimator.start();
|
||||
}
|
||||
}
|
||||
|
||||
private final void setInput(String paramString) {
|
||||
String str = this.input;
|
||||
this.input = paramString;
|
||||
if (str.length() != paramString.length() || paramString.length() <= this.circleViews.size())
|
||||
handleInputAnimate(str, paramString);
|
||||
}
|
||||
|
||||
public void _$_clearFindViewByIdCache() {
|
||||
HashMap hashMap = this._$_findViewCache;
|
||||
if (hashMap != null)
|
||||
hashMap.clear();
|
||||
}
|
||||
|
||||
public View _$_findCachedViewById(int paramInt) {
|
||||
if (this._$_findViewCache == null)
|
||||
this._$_findViewCache = new HashMap<Object, Object>();
|
||||
View view2 = (View)this._$_findViewCache.get(Integer.valueOf(paramInt));
|
||||
View view1 = view2;
|
||||
if (view2 == null) {
|
||||
view1 = findViewById(paramInt);
|
||||
this._$_findViewCache.put(Integer.valueOf(paramInt), view1);
|
||||
}
|
||||
return view1;
|
||||
}
|
||||
|
||||
public final void appendInputText(String paramString) {
|
||||
Intrinsics.checkParameterIsNotNull(paramString, "text");
|
||||
if (paramString.length() + this.input.length() > this.passwordCount)
|
||||
return;
|
||||
int j = paramString.length();
|
||||
for (int i = 0; i < j; i++) {
|
||||
if (((CircleView)this.circleViews.get(this.input.length() + i)).isAnimating())
|
||||
return;
|
||||
}
|
||||
String str = this.input;
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append(str);
|
||||
stringBuilder.append(paramString);
|
||||
setInput(stringBuilder.toString());
|
||||
}
|
||||
|
||||
public final void correctAnimation() {
|
||||
correctAnimation(this.correctAnimationDuration);
|
||||
fillAndStrokeColorChangeAnimation(this.colorChangeAnimationDuration, this.correctColor);
|
||||
}
|
||||
|
||||
public final int getPasswordCount() { return this.passwordCount; }
|
||||
|
||||
public final void incorrectAnimation() {
|
||||
incorrectAnimation(this.incorrectAnimationDuration);
|
||||
fillAndStrokeColorChangeAnimation(this.colorChangeAnimationDuration, this.incorrectColor);
|
||||
}
|
||||
|
||||
public final void removeInputText() {
|
||||
boolean bool;
|
||||
if (this.input.length() == 0) {
|
||||
bool = true;
|
||||
} else {
|
||||
bool = false;
|
||||
}
|
||||
if (bool)
|
||||
return;
|
||||
if (((CircleView)this.circleViews.get(this.input.length() - 1)).isAnimating())
|
||||
return;
|
||||
setInput(StringsKt.dropLast(this.input, 1));
|
||||
}
|
||||
|
||||
public final void removeListener() { this.actionListener = (ActionListener)null; }
|
||||
|
||||
public final void reset() {
|
||||
setInput("");
|
||||
fillColorChangeAnimation(this.colorChangeAnimationDuration, this.notInputColor);
|
||||
fillAndStrokeColorChangeAnimation(this.colorChangeAnimationDuration, this.inputColor);
|
||||
}
|
||||
|
||||
public final void setListener(ActionListener paramActionListener) {
|
||||
Intrinsics.checkParameterIsNotNull(paramActionListener, "actionListener");
|
||||
this.actionListener = paramActionListener;
|
||||
}
|
||||
|
||||
public final void setPasswordCount(int paramInt) {
|
||||
this.passwordCount = paramInt;
|
||||
addCircleView(paramInt);
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\034\n\002\030\002\n\002\020\000\n\002\b\002\n\002\020\b\n\002\b\004\n\002\020\007\n\002\b\f\b\003\030\0002\0020\001B\007\b\002¢\006\002\020\002R\016\020\003\032\0020\004XT¢\006\002\n\000R\016\020\005\032\0020\004XT¢\006\002\n\000R\016\020\006\032\0020\004XT¢\006\002\n\000R\016\020\007\032\0020\004XT¢\006\002\n\000R\016\020\b\032\0020\tXT¢\006\002\n\000R\016\020\n\032\0020\004XT¢\006\002\n\000R\016\020\013\032\0020\tXT¢\006\002\n\000R\016\020\f\032\0020\004XT¢\006\002\n\000R\016\020\r\032\0020\004XT¢\006\002\n\000R\016\020\016\032\0020\tXT¢\006\002\n\000R\016\020\017\032\0020\004XT¢\006\002\n\000R\016\020\020\032\0020\004XT¢\006\002\n\000R\016\020\021\032\0020\004XT¢\006\002\n\000R\016\020\022\032\0020\004XT¢\006\002\n\000R\016\020\023\032\0020\tXT¢\006\002\n\000R\016\020\024\032\0020\tXT¢\006\002\n\000¨\006\025"}, d2 = {"Lcom/keijumt/passwordview/PasswordView$Companion;", "", "()V", "DEFAULT_BETWEEN_MARGIN", "", "DEFAULT_CIRCLE_COUNT", "DEFAULT_COLOR_CHANGE_ANIMATION_DURATION", "DEFAULT_CORRECT_ANIMATION_DURATION", "DEFAULT_CORRECT_BOTTOM", "", "DEFAULT_CORRECT_COLOR", "DEFAULT_CORRECT_TOP", "DEFAULT_INCORRECT_ANIMATION_DURATION", "DEFAULT_INCORRECT_COLOR", "DEFAULT_INCORRECT_MAX_WIDTH", "DEFAULT_INPUT_AND_REMOVE_ANIMATION_DURATION", "DEFAULT_INPUT_COLOR", "DEFAULT_NOT_INPUT_COLOR", "DEFAULT_OUTLINE_COLOR", "DEFAULT_OUTLINE_STROKE_WIDTH", "DEFAULT_RADIUS", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class Companion {
|
||||
private Companion() {}
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\023\n\000\n\002\030\002\n\000\n\002\020\002\n\002\b\002*\001\000\b\n\030\0002\0020\001J\b\020\002\032\0020\003H\026¨\006\004¸\006\005"}, d2 = {"com/keijumt/passwordview/PasswordView$correctAnimation$1$1$1", "Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "onAnimationEnd", "", "library_release", "com/keijumt/passwordview/PasswordView$$special$$inlined$run$lambda$1"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class PasswordView$correctAnimation$$inlined$forEachIndexed$lambda$1 implements Animator.AnimatorListener {
|
||||
PasswordView$correctAnimation$$inlined$forEachIndexed$lambda$1(PasswordView param1PasswordView, long param1Long) {}
|
||||
|
||||
public void onAnimationEnd() {
|
||||
if (this.$index$inlined == PasswordView.this.getPasswordCount() - 1) {
|
||||
ActionListener actionListener = PasswordView.this.actionListener;
|
||||
if (actionListener != null)
|
||||
actionListener.onEndJudgeAnimation();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\b\n\000\n\002\020\002\n\000\020\000\032\0020\001H\n¢\006\002\b\002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 1, 13})
|
||||
static final class PasswordView$handleInputAnimate$1 extends Lambda implements Function0<Unit> {
|
||||
PasswordView$handleInputAnimate$1(String param1String) { super(0); }
|
||||
|
||||
public final void invoke() {
|
||||
if (this.$newInput.length() == PasswordView.this.circleViews.size()) {
|
||||
ActionListener actionListener = PasswordView.this.actionListener;
|
||||
if (actionListener != null)
|
||||
actionListener.onCompleteInput(PasswordView.this.input);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\023\n\000\n\002\030\002\n\000\n\002\020\002\n\002\b\002*\001\000\b\n\030\0002\0020\001J\b\020\002\032\0020\003H\026¨\006\004¸\006\005"}, d2 = {"com/keijumt/passwordview/PasswordView$incorrectAnimation$1$1$1", "Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "onAnimationEnd", "", "library_release", "com/keijumt/passwordview/PasswordView$$special$$inlined$apply$lambda$1"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class PasswordView$incorrectAnimation$$inlined$forEachIndexed$lambda$1 implements Animator.AnimatorListener {
|
||||
PasswordView$incorrectAnimation$$inlined$forEachIndexed$lambda$1(PasswordView param1PasswordView, long param1Long) {}
|
||||
|
||||
public void onAnimationEnd() {
|
||||
if (this.$index$inlined == PasswordView.this.getPasswordCount() - 1) {
|
||||
ActionListener actionListener = PasswordView.this.actionListener;
|
||||
if (actionListener != null)
|
||||
actionListener.onEndJudgeAnimation();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\PasswordView.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
3304
lib/src/main/java/com/keijumt/passwordview/R.java
Normal file
3304
lib/src/main/java/com/keijumt/passwordview/R.java
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,32 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import android.view.View;
|
||||
import kotlin.Metadata;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000 \n\002\030\002\n\002\020\000\n\000\n\002\030\002\n\002\b\002\n\002\020\002\n\000\n\002\030\002\n\002\b\004\b&\030\0002\0020\001:\001\013B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\020\020\005\032\0020\0062\006\020\007\032\0020\bH\026J\b\020\t\032\0020\006H\026J\b\020\n\032\0020\006H&R\016\020\002\032\0020\003X\004¢\006\002\n\000¨\006\f"}, d2 = {"Lcom/keijumt/passwordview/animation/Animator;", "", "target", "Landroid/view/View;", "(Landroid/view/View;)V", "addListener", "", "listener", "Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "removeAllListener", "start", "AnimatorListener", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public abstract class Animator {
|
||||
private final View target;
|
||||
|
||||
public Animator(View paramView) { this.target = paramView; }
|
||||
|
||||
public void addListener(AnimatorListener paramAnimatorListener) {
|
||||
Intrinsics.checkParameterIsNotNull(paramAnimatorListener, "listener");
|
||||
throw (Throwable)new RuntimeException("Stub!");
|
||||
}
|
||||
|
||||
public void removeAllListener() { throw (Throwable)new RuntimeException("Stub!"); }
|
||||
|
||||
public abstract void start();
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\020\n\002\030\002\n\002\020\000\n\000\n\002\020\002\n\000\bf\030\0002\0020\001J\b\020\002\032\0020\003H&¨\006\004"}, d2 = {"Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "", "onAnimationEnd", "", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public static interface AnimatorListener {
|
||||
void onAnimationEnd();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\Animator.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,83 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import android.animation.Animator;
|
||||
import android.animation.AnimatorListenerAdapter;
|
||||
import android.animation.ValueAnimator;
|
||||
import android.view.View;
|
||||
import com.keijumt.passwordview.CircleView;
|
||||
import kotlin.Metadata;
|
||||
import kotlin.TypeCastException;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\0006\n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\030\002\n\000\n\002\020\t\n\002\b\b\n\002\020\b\n\002\b\005\n\002\020\002\n\000\n\002\030\002\n\002\b\005\b \030\0002\0020\001B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\020\020\026\032\0020\0272\006\020\030\032\0020\031H\026J\b\020\032\032\0020\021H$J\020\020\033\032\0020\0272\006\020\034\032\0020\021H&J\b\020\035\032\0020\027H\026R\020\020\005\032\004\030\0010\006X\016¢\006\002\n\000R\032\020\007\032\0020\bX\016¢\006\016\n\000\032\004\b\t\020\n\"\004\b\013\020\fR\032\020\r\032\0020\bX\016¢\006\016\n\000\032\004\b\016\020\n\"\004\b\017\020\fR\032\020\020\032\0020\021X\016¢\006\016\n\000\032\004\b\022\020\023\"\004\b\024\020\025¨\006\036"}, d2 = {"Lcom/keijumt/passwordview/animation/ColorChangeAnimation;", "Lcom/keijumt/passwordview/animation/Animator;", "target", "Lcom/keijumt/passwordview/CircleView;", "(Lcom/keijumt/passwordview/CircleView;)V", "animator", "Landroid/animation/ValueAnimator;", "duration", "", "getDuration", "()J", "setDuration", "(J)V", "startDelay", "getStartDelay", "setStartDelay", "toColor", "", "getToColor", "()I", "setToColor", "(I)V", "addListener", "", "listener", "Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "getColor", "setColor", "color", "start", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public abstract class ColorChangeAnimation extends Animator {
|
||||
private ValueAnimator animator;
|
||||
|
||||
private long duration = 200L;
|
||||
|
||||
private long startDelay = 100L;
|
||||
|
||||
private int toColor;
|
||||
|
||||
public ColorChangeAnimation(CircleView paramCircleView) { super((View)paramCircleView); }
|
||||
|
||||
public void addListener(Animator.AnimatorListener paramAnimatorListener) {
|
||||
Intrinsics.checkParameterIsNotNull(paramAnimatorListener, "listener");
|
||||
ValueAnimator valueAnimator = this.animator;
|
||||
if (valueAnimator != null)
|
||||
valueAnimator.addListener((Animator.AnimatorListener)new ColorChangeAnimation$addListener$1(paramAnimatorListener));
|
||||
}
|
||||
|
||||
protected abstract int getColor();
|
||||
|
||||
public final long getDuration() { return this.duration; }
|
||||
|
||||
public final long getStartDelay() { return this.startDelay; }
|
||||
|
||||
public final int getToColor() { return this.toColor; }
|
||||
|
||||
public abstract void setColor(int paramInt);
|
||||
|
||||
public final void setDuration(long paramLong) { this.duration = paramLong; }
|
||||
|
||||
public final void setStartDelay(long paramLong) { this.startDelay = paramLong; }
|
||||
|
||||
public final void setToColor(int paramInt) { this.toColor = paramInt; }
|
||||
|
||||
public void start() {
|
||||
ValueAnimator valueAnimator = ValueAnimator.ofArgb(new int[] { getColor(), this.toColor });
|
||||
valueAnimator.setDuration(this.duration);
|
||||
valueAnimator.setStartDelay(this.startDelay);
|
||||
valueAnimator.addUpdateListener(new ColorChangeAnimation$start$$inlined$apply$lambda$1());
|
||||
this.animator = valueAnimator;
|
||||
if (valueAnimator != null)
|
||||
valueAnimator.start();
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\027\n\000\n\002\030\002\n\000\n\002\020\002\n\000\n\002\030\002\n\000*\001\000\b\n\030\0002\0020\001J\022\020\002\032\0020\0032\b\020\004\032\004\030\0010\005H\026¨\006\006"}, d2 = {"com/keijumt/passwordview/animation/ColorChangeAnimation$addListener$1", "Landroid/animation/AnimatorListenerAdapter;", "onAnimationEnd", "", "animation", "Landroid/animation/Animator;", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class ColorChangeAnimation$addListener$1 extends AnimatorListenerAdapter {
|
||||
ColorChangeAnimation$addListener$1(Animator.AnimatorListener param1AnimatorListener) {}
|
||||
|
||||
public void onAnimationEnd(Animator param1Animator) { this.$listener.onAnimationEnd(); }
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\024\n\000\n\002\020\002\n\000\n\002\030\002\n\002\b\002\n\002\b\003\020\000\032\0020\0012\016\020\002\032\n \004*\004\030\0010\0030\003H\n¢\006\002\b\005¨\006\006"}, d2 = {"<anonymous>", "", "it", "Landroid/animation/ValueAnimator;", "kotlin.jvm.PlatformType", "onAnimationUpdate", "com/keijumt/passwordview/animation/ColorChangeAnimation$start$1$1"}, k = 3, mv = {1, 1, 13})
|
||||
static final class ColorChangeAnimation$start$$inlined$apply$lambda$1 implements ValueAnimator.AnimatorUpdateListener {
|
||||
public final void onAnimationUpdate(ValueAnimator param1ValueAnimator) {
|
||||
ColorChangeAnimation colorChangeAnimation = ColorChangeAnimation.this;
|
||||
Intrinsics.checkExpressionValueIsNotNull(param1ValueAnimator, "it");
|
||||
Object object = param1ValueAnimator.getAnimatedValue();
|
||||
if (object != null) {
|
||||
colorChangeAnimation.setColor(((Integer)object).intValue());
|
||||
return;
|
||||
}
|
||||
throw new TypeCastException("null cannot be cast to non-null type kotlin.Int");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\ColorChangeAnimation.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import com.keijumt.passwordview.CircleView;
|
||||
import kotlin.Metadata;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000 \n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\020\b\n\000\n\002\020\002\n\002\b\002\b\000\030\0002\0020\001B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\b\020\005\032\0020\006H\024J\020\020\007\032\0020\b2\006\020\t\032\0020\006H\026R\016\020\002\032\0020\003X\004¢\006\002\n\000¨\006\n"}, d2 = {"Lcom/keijumt/passwordview/animation/FillAndStrokeColorChangeAnimation;", "Lcom/keijumt/passwordview/animation/ColorChangeAnimation;", "circleView", "Lcom/keijumt/passwordview/CircleView;", "(Lcom/keijumt/passwordview/CircleView;)V", "getColor", "", "setColor", "", "color", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class FillAndStrokeColorChangeAnimation extends ColorChangeAnimation {
|
||||
private final CircleView circleView;
|
||||
|
||||
public FillAndStrokeColorChangeAnimation(CircleView paramCircleView) {
|
||||
super(paramCircleView);
|
||||
this.circleView = paramCircleView;
|
||||
}
|
||||
|
||||
protected int getColor() { return this.circleView.getFillAndStrokeCircleColor(); }
|
||||
|
||||
public void setColor(int paramInt) { this.circleView.setFillAndStrokeCircleColor(paramInt); }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\FillAndStrokeColorChangeAnimation.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import com.keijumt.passwordview.CircleView;
|
||||
import kotlin.Metadata;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000 \n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\020\b\n\000\n\002\020\002\n\002\b\002\b\000\030\0002\0020\001B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\b\020\005\032\0020\006H\024J\020\020\007\032\0020\b2\006\020\t\032\0020\006H\026R\016\020\002\032\0020\003X\004¢\006\002\n\000¨\006\n"}, d2 = {"Lcom/keijumt/passwordview/animation/FillColorChangeAnimation;", "Lcom/keijumt/passwordview/animation/ColorChangeAnimation;", "circleView", "Lcom/keijumt/passwordview/CircleView;", "(Lcom/keijumt/passwordview/CircleView;)V", "getColor", "", "setColor", "", "color", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class FillColorChangeAnimation extends ColorChangeAnimation {
|
||||
private final CircleView circleView;
|
||||
|
||||
public FillColorChangeAnimation(CircleView paramCircleView) {
|
||||
super(paramCircleView);
|
||||
this.circleView = paramCircleView;
|
||||
}
|
||||
|
||||
protected int getColor() { return this.circleView.getFillCircleColor(); }
|
||||
|
||||
public void setColor(int paramInt) { this.circleView.setFillCircleColor(paramInt); }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\FillColorChangeAnimation.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import com.keijumt.passwordview.CircleView;
|
||||
import kotlin.Metadata;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000 \n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\020\b\n\000\n\002\020\002\n\002\b\002\b\000\030\0002\0020\001B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\b\020\005\032\0020\006H\024J\020\020\007\032\0020\b2\006\020\t\032\0020\006H\026R\016\020\002\032\0020\003X\004¢\006\002\n\000¨\006\n"}, d2 = {"Lcom/keijumt/passwordview/animation/OutLineColorChangeAnimation;", "Lcom/keijumt/passwordview/animation/ColorChangeAnimation;", "circleView", "Lcom/keijumt/passwordview/CircleView;", "(Lcom/keijumt/passwordview/CircleView;)V", "getColor", "", "setColor", "", "color", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class OutLineColorChangeAnimation extends ColorChangeAnimation {
|
||||
private final CircleView circleView;
|
||||
|
||||
public OutLineColorChangeAnimation(CircleView paramCircleView) {
|
||||
super(paramCircleView);
|
||||
this.circleView = paramCircleView;
|
||||
}
|
||||
|
||||
protected int getColor() { return this.circleView.getOutLineColor(); }
|
||||
|
||||
public void setColor(int paramInt) { this.circleView.setOutLineColor(paramInt); }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\OutLineColorChangeAnimation.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,94 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import android.animation.Animator;
|
||||
import android.animation.AnimatorListenerAdapter;
|
||||
import android.animation.ValueAnimator;
|
||||
import android.view.View;
|
||||
import kotlin.Metadata;
|
||||
import kotlin.TypeCastException;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\0008\n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\030\002\n\002\b\002\n\002\020\t\n\002\b\005\n\002\020\b\n\002\b\013\n\002\020\002\n\000\n\002\030\002\n\002\b\003\b\000\030\0002\0020\001B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\020\020\032\032\0020\0332\006\020\034\032\0020\035H\026J\b\020\036\032\0020\033H\026J\b\020\037\032\0020\033H\026R\026\020\005\032\n \007*\004\030\0010\0060\006X\016¢\006\002\n\000R\032\020\b\032\0020\tX\016¢\006\016\n\000\032\004\b\n\020\013\"\004\b\f\020\rR\032\020\016\032\0020\017X\016¢\006\016\n\000\032\004\b\020\020\021\"\004\b\022\020\023R\032\020\024\032\0020\017X\016¢\006\016\n\000\032\004\b\025\020\021\"\004\b\026\020\023R\032\020\027\032\0020\tX\016¢\006\016\n\000\032\004\b\030\020\013\"\004\b\031\020\rR\016\020\002\032\0020\003X\004¢\006\002\n\000¨\006 "}, d2 = {"Lcom/keijumt/passwordview/animation/ShakeAnimator;", "Lcom/keijumt/passwordview/animation/Animator;", "target", "Landroid/view/View;", "(Landroid/view/View;)V", "animator", "Landroid/animation/ValueAnimator;", "kotlin.jvm.PlatformType", "duration", "", "getDuration", "()J", "setDuration", "(J)V", "shakeMaxWidth", "", "getShakeMaxWidth", "()I", "setShakeMaxWidth", "(I)V", "shakeTimes", "getShakeTimes", "setShakeTimes", "startDelay", "getStartDelay", "setStartDelay", "addListener", "", "listener", "Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "removeAllListener", "start", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class ShakeAnimator extends Animator {
|
||||
private ValueAnimator animator;
|
||||
|
||||
private long duration;
|
||||
|
||||
private int shakeMaxWidth;
|
||||
|
||||
private int shakeTimes;
|
||||
|
||||
private long startDelay;
|
||||
|
||||
private final View target;
|
||||
|
||||
public ShakeAnimator(View paramView) {
|
||||
super(paramView);
|
||||
this.target = paramView;
|
||||
this.animator = ValueAnimator.ofFloat(new float[] { 0.0F, 1.0F });
|
||||
this.duration = 400L;
|
||||
this.shakeMaxWidth = 40;
|
||||
this.shakeTimes = 4;
|
||||
}
|
||||
|
||||
public void addListener(Animator.AnimatorListener paramAnimatorListener) {
|
||||
Intrinsics.checkParameterIsNotNull(paramAnimatorListener, "listener");
|
||||
this.animator.addListener((Animator.AnimatorListener)new ShakeAnimator$addListener$1(paramAnimatorListener));
|
||||
}
|
||||
|
||||
public final long getDuration() { return this.duration; }
|
||||
|
||||
public final int getShakeMaxWidth() { return this.shakeMaxWidth; }
|
||||
|
||||
public final int getShakeTimes() { return this.shakeTimes; }
|
||||
|
||||
public final long getStartDelay() { return this.startDelay; }
|
||||
|
||||
public void removeAllListener() { this.animator.removeAllListeners(); }
|
||||
|
||||
public final void setDuration(long paramLong) { this.duration = paramLong; }
|
||||
|
||||
public final void setShakeMaxWidth(int paramInt) { this.shakeMaxWidth = paramInt; }
|
||||
|
||||
public final void setShakeTimes(int paramInt) { this.shakeTimes = paramInt; }
|
||||
|
||||
public final void setStartDelay(long paramLong) { this.startDelay = paramLong; }
|
||||
|
||||
public void start() {
|
||||
ValueAnimator valueAnimator = this.animator;
|
||||
valueAnimator.cancel();
|
||||
valueAnimator.setDuration(this.duration);
|
||||
valueAnimator.setStartDelay(this.startDelay);
|
||||
valueAnimator.addUpdateListener(new ShakeAnimator$start$$inlined$run$lambda$1(this));
|
||||
valueAnimator.start();
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\027\n\000\n\002\030\002\n\000\n\002\020\002\n\000\n\002\030\002\n\000*\001\000\b\n\030\0002\0020\001J\022\020\002\032\0020\0032\b\020\004\032\004\030\0010\005H\026¨\006\006"}, d2 = {"com/keijumt/passwordview/animation/ShakeAnimator$addListener$1", "Landroid/animation/AnimatorListenerAdapter;", "onAnimationEnd", "", "animation", "Landroid/animation/Animator;", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class ShakeAnimator$addListener$1 extends AnimatorListenerAdapter {
|
||||
ShakeAnimator$addListener$1(Animator.AnimatorListener param1AnimatorListener) {}
|
||||
|
||||
public void onAnimationEnd(Animator param1Animator) { this.$listener.onAnimationEnd(); }
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\024\n\000\n\002\020\002\n\000\n\002\030\002\n\002\b\002\n\002\b\003\020\000\032\0020\0012\016\020\002\032\n \004*\004\030\0010\0030\003H\n¢\006\002\b\005¨\006\006"}, d2 = {"<anonymous>", "", "it", "Landroid/animation/ValueAnimator;", "kotlin.jvm.PlatformType", "onAnimationUpdate", "com/keijumt/passwordview/animation/ShakeAnimator$start$1$1"}, k = 3, mv = {1, 1, 13})
|
||||
static final class ShakeAnimator$start$$inlined$run$lambda$1 implements ValueAnimator.AnimatorUpdateListener {
|
||||
ShakeAnimator$start$$inlined$run$lambda$1(ShakeAnimator param1ShakeAnimator) {}
|
||||
|
||||
public final void onAnimationUpdate(ValueAnimator param1ValueAnimator) {
|
||||
Intrinsics.checkExpressionValueIsNotNull(param1ValueAnimator, "it");
|
||||
Object object = param1ValueAnimator.getAnimatedValue();
|
||||
if (object != null) {
|
||||
float f = ((Float)object).floatValue();
|
||||
ShakeAnimator.this.target.setX(this.$initialPositionX + (float)Math.sin(ShakeAnimator.this.getShakeTimes() * Math.PI * f) * ShakeAnimator.this.getShakeMaxWidth() / 2);
|
||||
return;
|
||||
}
|
||||
throw new TypeCastException("null cannot be cast to non-null type kotlin.Float");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\ShakeAnimator.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,82 @@
|
||||
package com.keijumt.passwordview.animation;
|
||||
|
||||
import android.animation.Animator;
|
||||
import android.animation.AnimatorListenerAdapter;
|
||||
import android.animation.AnimatorSet;
|
||||
import android.animation.ObjectAnimator;
|
||||
import android.animation.TimeInterpolator;
|
||||
import android.view.View;
|
||||
import androidx.interpolator.view.animation.FastOutSlowInInterpolator;
|
||||
import kotlin.Metadata;
|
||||
import kotlin.jvm.internal.Intrinsics;
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\0006\n\002\030\002\n\002\030\002\n\000\n\002\030\002\n\002\b\002\n\002\030\002\n\000\n\002\020\t\n\002\b\005\n\002\020\007\n\002\b\f\n\002\020\002\n\000\n\002\030\002\n\002\b\002\b\000\030\0002\0020\001B\r\022\006\020\002\032\0020\003¢\006\002\020\004J\020\020\032\032\0020\0332\006\020\034\032\0020\035H\026J\b\020\036\032\0020\033H\026R\016\020\005\032\0020\006X\004¢\006\002\n\000R\032\020\007\032\0020\bX\016¢\006\016\n\000\032\004\b\t\020\n\"\004\b\013\020\fR$\020\017\032\0020\0162\006\020\r\032\0020\016@FX\016¢\006\016\n\000\032\004\b\020\020\021\"\004\b\022\020\023R$\020\024\032\0020\0162\006\020\r\032\0020\016@FX\016¢\006\016\n\000\032\004\b\025\020\021\"\004\b\026\020\023R\032\020\027\032\0020\bX\016¢\006\016\n\000\032\004\b\030\020\n\"\004\b\031\020\fR\016\020\002\032\0020\003X\004¢\006\002\n\000¨\006\037"}, d2 = {"Lcom/keijumt/passwordview/animation/SpringAnimator;", "Lcom/keijumt/passwordview/animation/Animator;", "target", "Landroid/view/View;", "(Landroid/view/View;)V", "animatorSet", "Landroid/animation/AnimatorSet;", "duration", "", "getDuration", "()J", "setDuration", "(J)V", "value", "", "moveBottomY", "getMoveBottomY", "()F", "setMoveBottomY", "(F)V", "moveTopY", "getMoveTopY", "setMoveTopY", "startDelay", "getStartDelay", "setStartDelay", "addListener", "", "listener", "Lcom/keijumt/passwordview/animation/Animator$AnimatorListener;", "start", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public final class SpringAnimator extends Animator {
|
||||
private final AnimatorSet animatorSet;
|
||||
|
||||
private long duration;
|
||||
|
||||
private float moveBottomY;
|
||||
|
||||
private float moveTopY;
|
||||
|
||||
private long startDelay;
|
||||
|
||||
private final View target;
|
||||
|
||||
public SpringAnimator(View paramView) {
|
||||
super(paramView);
|
||||
this.target = paramView;
|
||||
this.animatorSet = new AnimatorSet();
|
||||
this.duration = 150L;
|
||||
this.moveTopY = this.target.getY() - 30.0F;
|
||||
this.moveBottomY = this.target.getY() + 10.0F;
|
||||
}
|
||||
|
||||
public void addListener(Animator.AnimatorListener paramAnimatorListener) {
|
||||
Intrinsics.checkParameterIsNotNull(paramAnimatorListener, "listener");
|
||||
this.animatorSet.addListener((Animator.AnimatorListener)new SpringAnimator$addListener$1(paramAnimatorListener));
|
||||
}
|
||||
|
||||
public final long getDuration() { return this.duration; }
|
||||
|
||||
public final float getMoveBottomY() { return this.moveBottomY; }
|
||||
|
||||
public final float getMoveTopY() { return this.moveTopY; }
|
||||
|
||||
public final long getStartDelay() { return this.startDelay; }
|
||||
|
||||
public final void setDuration(long paramLong) { this.duration = paramLong; }
|
||||
|
||||
public final void setMoveBottomY(float paramFloat) { this.moveBottomY = this.target.getY() + paramFloat; }
|
||||
|
||||
public final void setMoveTopY(float paramFloat) { this.moveTopY = this.target.getY() - paramFloat; }
|
||||
|
||||
public final void setStartDelay(long paramLong) { this.startDelay = paramLong; }
|
||||
|
||||
public void start() {
|
||||
AnimatorSet animatorSet1 = this.animatorSet;
|
||||
float f = this.target.getY();
|
||||
ObjectAnimator objectAnimator1 = ObjectAnimator.ofFloat(this.target, "y", new float[] { this.moveTopY });
|
||||
ObjectAnimator objectAnimator2 = ObjectAnimator.ofFloat(this.target, "y", new float[] { this.moveBottomY });
|
||||
ObjectAnimator objectAnimator3 = ObjectAnimator.ofFloat(this.target, "y", new float[] { f });
|
||||
animatorSet1.playSequentially(new Animator[] { (Animator)objectAnimator1, (Animator)objectAnimator2, (Animator)objectAnimator3 });
|
||||
animatorSet1.setInterpolator((TimeInterpolator)new FastOutSlowInInterpolator());
|
||||
animatorSet1.setDuration(this.duration);
|
||||
animatorSet1.setStartDelay(this.startDelay);
|
||||
animatorSet1.start();
|
||||
}
|
||||
|
||||
@Metadata(bv = {1, 0, 3}, d1 = {"\000\027\n\000\n\002\030\002\n\000\n\002\020\002\n\000\n\002\030\002\n\000*\001\000\b\n\030\0002\0020\001J\022\020\002\032\0020\0032\b\020\004\032\004\030\0010\005H\026¨\006\006"}, d2 = {"com/keijumt/passwordview/animation/SpringAnimator$addListener$1", "Landroid/animation/AnimatorListenerAdapter;", "onAnimationEnd", "", "animation", "Landroid/animation/Animator;", "library_release"}, k = 1, mv = {1, 1, 13})
|
||||
public static final class SpringAnimator$addListener$1 extends AnimatorListenerAdapter {
|
||||
SpringAnimator$addListener$1(Animator.AnimatorListener param1AnimatorListener) {}
|
||||
|
||||
public void onAnimationEnd(Animator param1Animator) { this.$listener.onAnimationEnd(); }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\keijumt\passwordview\animation\SpringAnimator.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
21
lib/src/main/java/com/qq/mta/BuildConfig.java
Normal file
21
lib/src/main/java/com/qq/mta/BuildConfig.java
Normal file
@@ -0,0 +1,21 @@
|
||||
package com.qq.mta;
|
||||
|
||||
public final class BuildConfig {
|
||||
public static final String APPLICATION_ID = "com.qq.mta";
|
||||
|
||||
public static final String BUILD_TYPE = "release";
|
||||
|
||||
public static final boolean DEBUG = false;
|
||||
|
||||
public static final String FLAVOR = "";
|
||||
|
||||
public static final int VERSION_CODE = 1;
|
||||
|
||||
public static final String VERSION_NAME = "1.0";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\qq\mta\BuildConfig.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
13
lib/src/main/java/com/qq/mta/R.java
Normal file
13
lib/src/main/java/com/qq/mta/R.java
Normal file
@@ -0,0 +1,13 @@
|
||||
package com.qq.mta;
|
||||
|
||||
public final class R {
|
||||
public static final class string {
|
||||
public static final int app_name = 2131689500;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\qq\mta\R.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
21
lib/src/main/java/com/simple/spiderman/BuildConfig.java
Normal file
21
lib/src/main/java/com/simple/spiderman/BuildConfig.java
Normal file
@@ -0,0 +1,21 @@
|
||||
package com.simple.spiderman;
|
||||
|
||||
public final class BuildConfig {
|
||||
public static final String APPLICATION_ID = "com.simple.spiderman";
|
||||
|
||||
public static final String BUILD_TYPE = "release";
|
||||
|
||||
public static final boolean DEBUG = false;
|
||||
|
||||
public static final String FLAVOR = "";
|
||||
|
||||
public static final int VERSION_CODE = 1;
|
||||
|
||||
public static final String VERSION_NAME = "1.0";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\simple\spiderman\BuildConfig.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
186
lib/src/main/java/com/simple/spiderman/CrashModel.java
Normal file
186
lib/src/main/java/com/simple/spiderman/CrashModel.java
Normal file
@@ -0,0 +1,186 @@
|
||||
package com.simple.spiderman;
|
||||
|
||||
import android.os.Build;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
public class CrashModel implements Parcelable {
|
||||
public static final Parcelable.Creator<CrashModel> CREATOR = new Parcelable.Creator<CrashModel>() {
|
||||
public CrashModel createFromParcel(Parcel param1Parcel) { return new CrashModel(param1Parcel); }
|
||||
|
||||
public CrashModel[] newArray(int param1Int) { return new CrashModel[param1Int]; }
|
||||
};
|
||||
|
||||
private String className;
|
||||
|
||||
private Device device = new Device();
|
||||
|
||||
private Throwable ex;
|
||||
|
||||
private String exceptionMsg;
|
||||
|
||||
private String exceptionType;
|
||||
|
||||
private String fileName;
|
||||
|
||||
private String fullException;
|
||||
|
||||
private int lineNumber;
|
||||
|
||||
private String methodName;
|
||||
|
||||
private String packageName;
|
||||
|
||||
private long time;
|
||||
|
||||
public CrashModel() {}
|
||||
|
||||
protected CrashModel(Parcel paramParcel) {
|
||||
this.ex = (Throwable)paramParcel.readSerializable();
|
||||
this.exceptionMsg = paramParcel.readString();
|
||||
this.className = paramParcel.readString();
|
||||
this.fileName = paramParcel.readString();
|
||||
this.methodName = paramParcel.readString();
|
||||
this.lineNumber = paramParcel.readInt();
|
||||
this.exceptionType = paramParcel.readString();
|
||||
this.fullException = paramParcel.readString();
|
||||
this.time = paramParcel.readLong();
|
||||
}
|
||||
|
||||
public int describeContents() { return 0; }
|
||||
|
||||
public String getClassName() { return this.className; }
|
||||
|
||||
public Device getDevice() { return this.device; }
|
||||
|
||||
public Throwable getEx() { return this.ex; }
|
||||
|
||||
public String getExceptionMsg() { return this.exceptionMsg; }
|
||||
|
||||
public String getExceptionType() { return this.exceptionType; }
|
||||
|
||||
public String getFileName() { return this.fileName; }
|
||||
|
||||
public String getFullException() { return this.fullException; }
|
||||
|
||||
public int getLineNumber() { return this.lineNumber; }
|
||||
|
||||
public String getMethodName() { return this.methodName; }
|
||||
|
||||
public String getPackageName() { return getClassName().replace(getFileName(), ""); }
|
||||
|
||||
public long getTime() { return this.time; }
|
||||
|
||||
public void setClassName(String paramString) { this.className = paramString; }
|
||||
|
||||
public void setEx(Throwable paramThrowable) { this.ex = paramThrowable; }
|
||||
|
||||
public void setExceptionMsg(String paramString) { this.exceptionMsg = paramString; }
|
||||
|
||||
public void setExceptionType(String paramString) { this.exceptionType = paramString; }
|
||||
|
||||
public void setFileName(String paramString) { this.fileName = paramString; }
|
||||
|
||||
public void setFullException(String paramString) { this.fullException = paramString; }
|
||||
|
||||
public void setLineNumber(int paramInt) { this.lineNumber = paramInt; }
|
||||
|
||||
public void setMethodName(String paramString) { this.methodName = paramString; }
|
||||
|
||||
public void setTime(long paramLong) { this.time = paramLong; }
|
||||
|
||||
public String toString() {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("CrashModel{ex=");
|
||||
stringBuilder.append(this.ex);
|
||||
stringBuilder.append(", packageName='");
|
||||
stringBuilder.append(this.packageName);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", exceptionMsg='");
|
||||
stringBuilder.append(this.exceptionMsg);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", className='");
|
||||
stringBuilder.append(this.className);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", fileName='");
|
||||
stringBuilder.append(this.fileName);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", methodName='");
|
||||
stringBuilder.append(this.methodName);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", lineNumber=");
|
||||
stringBuilder.append(this.lineNumber);
|
||||
stringBuilder.append(", exceptionType='");
|
||||
stringBuilder.append(this.exceptionType);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", fullException='");
|
||||
stringBuilder.append(this.fullException);
|
||||
stringBuilder.append('\'');
|
||||
stringBuilder.append(", time=");
|
||||
stringBuilder.append(this.time);
|
||||
stringBuilder.append(", device=");
|
||||
stringBuilder.append(this.device);
|
||||
stringBuilder.append('}');
|
||||
return stringBuilder.toString();
|
||||
}
|
||||
|
||||
public void writeToParcel(Parcel paramParcel, int paramInt) {
|
||||
paramParcel.writeSerializable(this.ex);
|
||||
paramParcel.writeString(this.exceptionMsg);
|
||||
paramParcel.writeString(this.className);
|
||||
paramParcel.writeString(this.fileName);
|
||||
paramParcel.writeString(this.methodName);
|
||||
paramParcel.writeInt(this.lineNumber);
|
||||
paramParcel.writeString(this.exceptionType);
|
||||
paramParcel.writeString(this.fullException);
|
||||
paramParcel.writeLong(this.time);
|
||||
}
|
||||
|
||||
public static class Device implements Parcelable {
|
||||
public static final Parcelable.Creator<Device> CREATOR = new Parcelable.Creator<Device>() {
|
||||
public CrashModel.Device createFromParcel(Parcel param2Parcel) { return new CrashModel.Device(param2Parcel); }
|
||||
|
||||
public CrashModel.Device[] newArray(int param2Int) { return new CrashModel.Device[param2Int]; }
|
||||
};
|
||||
|
||||
private String brand = Build.BRAND;
|
||||
|
||||
private String model = Build.MODEL;
|
||||
|
||||
private String version = String.valueOf(Build.VERSION.SDK_INT);
|
||||
|
||||
public Device() {}
|
||||
|
||||
protected Device(Parcel param1Parcel) {
|
||||
this.model = param1Parcel.readString();
|
||||
this.brand = param1Parcel.readString();
|
||||
this.version = param1Parcel.readString();
|
||||
}
|
||||
|
||||
public int describeContents() { return 0; }
|
||||
|
||||
public String getBrand() { return this.brand; }
|
||||
|
||||
public String getModel() { return this.model; }
|
||||
|
||||
public String getVersion() { return this.version; }
|
||||
|
||||
public void writeToParcel(Parcel param1Parcel, int param1Int) {
|
||||
param1Parcel.writeString(this.model);
|
||||
param1Parcel.writeString(this.brand);
|
||||
param1Parcel.writeString(this.version);
|
||||
}
|
||||
}
|
||||
|
||||
static final class null implements Parcelable.Creator<Device> {
|
||||
public CrashModel.Device createFromParcel(Parcel param1Parcel) { return new CrashModel.Device(param1Parcel); }
|
||||
|
||||
public CrashModel.Device[] newArray(int param1Int) { return new CrashModel.Device[param1Int]; }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\simple\spiderman\CrashModel.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
3150
lib/src/main/java/com/simple/spiderman/R.java
Normal file
3150
lib/src/main/java/com/simple/spiderman/R.java
Normal file
File diff suppressed because it is too large
Load Diff
15
lib/src/main/java/com/simple/spiderman/SpiderMan.java
Normal file
15
lib/src/main/java/com/simple/spiderman/SpiderMan.java
Normal file
@@ -0,0 +1,15 @@
|
||||
package com.simple.spiderman;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
public class SpiderMan {
|
||||
public static final String TAG = "SpiderMan";
|
||||
|
||||
public static void init(Context paramContext) {}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\simple\spiderman\SpiderMan.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
13
lib/src/main/java/com/swift/sandhook/ArtMethodSizeTest.java
Normal file
13
lib/src/main/java/com/swift/sandhook/ArtMethodSizeTest.java
Normal file
@@ -0,0 +1,13 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
public class ArtMethodSizeTest {
|
||||
public static final void method1() {}
|
||||
|
||||
public static final void method2() {}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\ArtMethodSizeTest.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
21
lib/src/main/java/com/swift/sandhook/ClassNeverCall.java
Normal file
21
lib/src/main/java/com/swift/sandhook/ClassNeverCall.java
Normal file
@@ -0,0 +1,21 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
import android.util.Log;
|
||||
|
||||
public class ClassNeverCall {
|
||||
private void neverCall() {}
|
||||
|
||||
private void neverCall2() { Log.e("ClassNeverCall", "ClassNeverCall2"); }
|
||||
|
||||
private native void neverCallNative();
|
||||
|
||||
private native void neverCallNative2();
|
||||
|
||||
private static void neverCallStatic() {}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\ClassNeverCall.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
27
lib/src/main/java/com/swift/sandhook/HookLog.java
Normal file
27
lib/src/main/java/com/swift/sandhook/HookLog.java
Normal file
@@ -0,0 +1,27 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
import android.util.Log;
|
||||
|
||||
public class HookLog {
|
||||
public static boolean DEBUG = SandHookConfig.DEBUG;
|
||||
|
||||
public static final String TAG = "SandHook";
|
||||
|
||||
public static int d(String paramString) { return Log.d("SandHook", paramString); }
|
||||
|
||||
public static int e(String paramString) { return Log.e("SandHook", paramString); }
|
||||
|
||||
public static int e(String paramString, Throwable paramThrowable) { return Log.e("SandHook", paramString, paramThrowable); }
|
||||
|
||||
public static int i(String paramString) { return Log.i("SandHook", paramString); }
|
||||
|
||||
public static int v(String paramString) { return Log.v("SandHook", paramString); }
|
||||
|
||||
public static int w(String paramString) { return Log.w("SandHook", paramString); }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\HookLog.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
92
lib/src/main/java/com/swift/sandhook/PendingHookHandler.java
Normal file
92
lib/src/main/java/com/swift/sandhook/PendingHookHandler.java
Normal file
@@ -0,0 +1,92 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
import com.swift.sandhook.wrapper.HookErrorException;
|
||||
import com.swift.sandhook.wrapper.HookWrapper;
|
||||
import java.util.Map;
|
||||
import java.util.Vector;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
public class PendingHookHandler {
|
||||
private static boolean canUsePendingHook;
|
||||
|
||||
private static Map<Class, Vector<HookWrapper.HookEntity>> pendingHooks = (Map)new ConcurrentHashMap<Class<?>, Vector<HookWrapper.HookEntity>>();
|
||||
|
||||
static {
|
||||
canUsePendingHook = SandHook.initForPendingHook();
|
||||
}
|
||||
|
||||
public static void addPendingHook(HookWrapper.HookEntity paramHookEntity) { // Byte code:
|
||||
// 0: ldc com/swift/sandhook/PendingHookHandler
|
||||
// 2: monitorenter
|
||||
// 3: getstatic com/swift/sandhook/PendingHookHandler.pendingHooks : Ljava/util/Map;
|
||||
// 6: aload_0
|
||||
// 7: getfield target : Ljava/lang/reflect/Member;
|
||||
// 10: invokeinterface getDeclaringClass : ()Ljava/lang/Class;
|
||||
// 15: invokeinterface get : (Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 20: checkcast java/util/Vector
|
||||
// 23: astore_2
|
||||
// 24: aload_2
|
||||
// 25: astore_1
|
||||
// 26: aload_2
|
||||
// 27: ifnonnull -> 57
|
||||
// 30: new java/util/Vector
|
||||
// 33: dup
|
||||
// 34: invokespecial <init> : ()V
|
||||
// 37: astore_1
|
||||
// 38: getstatic com/swift/sandhook/PendingHookHandler.pendingHooks : Ljava/util/Map;
|
||||
// 41: aload_0
|
||||
// 42: getfield target : Ljava/lang/reflect/Member;
|
||||
// 45: invokeinterface getDeclaringClass : ()Ljava/lang/Class;
|
||||
// 50: aload_1
|
||||
// 51: invokeinterface put : (Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 56: pop
|
||||
// 57: aload_1
|
||||
// 58: aload_0
|
||||
// 59: invokevirtual add : (Ljava/lang/Object;)Z
|
||||
// 62: pop
|
||||
// 63: ldc com/swift/sandhook/PendingHookHandler
|
||||
// 65: monitorexit
|
||||
// 66: return
|
||||
// 67: astore_0
|
||||
// 68: ldc com/swift/sandhook/PendingHookHandler
|
||||
// 70: monitorexit
|
||||
// 71: aload_0
|
||||
// 72: athrow
|
||||
// Exception table:
|
||||
// from to target type
|
||||
// 3 24 67 finally
|
||||
// 30 57 67 finally
|
||||
// 57 63 67 finally }
|
||||
|
||||
public static boolean canWork() { return (canUsePendingHook && SandHook.canGetObject() && !SandHookConfig.DEBUG); }
|
||||
|
||||
public static void onClassInit(long paramLong) {
|
||||
if (paramLong == 0L)
|
||||
return;
|
||||
Class clazz = (Class)SandHook.getObject(paramLong);
|
||||
if (clazz == null)
|
||||
return;
|
||||
Vector vector = pendingHooks.get(clazz);
|
||||
if (vector == null)
|
||||
return;
|
||||
for (HookWrapper.HookEntity hookEntity : vector) {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("do pending hook for method: ");
|
||||
stringBuilder.append(hookEntity.target.toString());
|
||||
HookLog.w(stringBuilder.toString());
|
||||
try {
|
||||
hookEntity.initClass = false;
|
||||
SandHook.hook(hookEntity);
|
||||
} catch (HookErrorException hookErrorException) {
|
||||
HookLog.e("Pending Hook Error!", (Throwable)hookErrorException);
|
||||
}
|
||||
}
|
||||
pendingHooks.remove(clazz);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\PendingHookHandler.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
592
lib/src/main/java/com/swift/sandhook/SandHook.java
Normal file
592
lib/src/main/java/com/swift/sandhook/SandHook.java
Normal file
@@ -0,0 +1,592 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
import com.swift.sandhook.utils.ReflectionUtils;
|
||||
import com.swift.sandhook.utils.Unsafe;
|
||||
import com.swift.sandhook.wrapper.HookErrorException;
|
||||
import com.swift.sandhook.wrapper.HookWrapper;
|
||||
import java.io.File;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.lang.reflect.Member;
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.reflect.Modifier;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
public class SandHook {
|
||||
public static Class artMethodClass;
|
||||
|
||||
static Map<Method, HookWrapper.HookEntity> globalBackupMap;
|
||||
|
||||
static Map<Member, HookWrapper.HookEntity> globalHookEntityMap = new ConcurrentHashMap<Member, HookWrapper.HookEntity>();
|
||||
|
||||
private static HookModeCallBack hookModeCallBack;
|
||||
|
||||
private static HookResultCallBack hookResultCallBack;
|
||||
|
||||
public static Field nativePeerField;
|
||||
|
||||
public static int testAccessFlag;
|
||||
|
||||
public static Object testOffsetArtMethod1;
|
||||
|
||||
public static Object testOffsetArtMethod2;
|
||||
|
||||
public static Method testOffsetMethod1;
|
||||
|
||||
public static Method testOffsetMethod2;
|
||||
|
||||
static {
|
||||
globalBackupMap = new ConcurrentHashMap<Method, HookWrapper.HookEntity>();
|
||||
SandHookConfig.libLoader.loadLib();
|
||||
init();
|
||||
}
|
||||
|
||||
public static void addHookClass(ClassLoader paramClassLoader, Class... paramVarArgs) throws HookErrorException { HookWrapper.addHookClass(paramClassLoader, paramVarArgs); }
|
||||
|
||||
public static void addHookClass(Class... paramVarArgs) throws HookErrorException { HookWrapper.addHookClass(paramVarArgs); }
|
||||
|
||||
public static final Object callOriginByBackup(Method paramMethod, Object paramObject, Object... paramVarArgs) throws Throwable {
|
||||
HookWrapper.HookEntity hookEntity = globalBackupMap.get(paramMethod);
|
||||
return (hookEntity == null) ? null : callOriginMethod(hookEntity.backupIsStub, hookEntity.target, paramMethod, paramObject, paramVarArgs);
|
||||
}
|
||||
|
||||
public static final Object callOriginMethod(Member paramMember, Object paramObject, Object... paramVarArgs) throws Throwable {
|
||||
HookWrapper.HookEntity hookEntity = globalHookEntityMap.get(paramMember);
|
||||
return (hookEntity == null || hookEntity.backup == null) ? null : callOriginMethod(hookEntity.backupIsStub, paramMember, hookEntity.backup, paramObject, paramVarArgs);
|
||||
}
|
||||
|
||||
public static final Object callOriginMethod(Member paramMember, Method paramMethod, Object paramObject, Object[] paramArrayOfObject) throws Throwable { return callOriginMethod(true, paramMember, paramMethod, paramObject, paramArrayOfObject); }
|
||||
|
||||
public static final Object callOriginMethod(boolean paramBoolean, Member paramMember, Method paramMethod, Object paramObject, Object[] paramArrayOfObject) throws Throwable {
|
||||
if (!paramBoolean && SandHookConfig.SDK_INT >= 24) {
|
||||
paramMember.getDeclaringClass();
|
||||
ensureDeclareClass(paramMember, paramMethod);
|
||||
}
|
||||
if (Modifier.isStatic(paramMember.getModifiers()))
|
||||
try {
|
||||
return paramMethod.invoke(null, paramArrayOfObject);
|
||||
} catch (InvocationTargetException invocationTargetException) {
|
||||
if (invocationTargetException.getCause() != null)
|
||||
throw invocationTargetException.getCause();
|
||||
throw invocationTargetException;
|
||||
}
|
||||
try {
|
||||
return paramMethod.invoke(paramObject, paramArrayOfObject);
|
||||
} catch (InvocationTargetException invocationTargetException) {
|
||||
if (invocationTargetException.getCause() != null)
|
||||
throw invocationTargetException.getCause();
|
||||
throw invocationTargetException;
|
||||
}
|
||||
}
|
||||
|
||||
public static native boolean canGetObject();
|
||||
|
||||
public static boolean canGetObjectAddress() { return Unsafe.support(); }
|
||||
|
||||
public static native boolean compileMethod(Member paramMember);
|
||||
|
||||
public static native boolean deCompileMethod(Member paramMember, boolean paramBoolean);
|
||||
|
||||
public static native boolean disableDex2oatInline(boolean paramBoolean);
|
||||
|
||||
public static native boolean disableVMInline();
|
||||
|
||||
public static final void ensureBackupMethod(Method paramMethod) {
|
||||
if (SandHookConfig.SDK_INT < 24)
|
||||
return;
|
||||
HookWrapper.HookEntity hookEntity = globalBackupMap.get(paramMethod);
|
||||
if (hookEntity != null)
|
||||
ensureDeclareClass(hookEntity.target, paramMethod);
|
||||
}
|
||||
|
||||
public static native void ensureDeclareClass(Member paramMember, Method paramMethod);
|
||||
|
||||
public static native void ensureMethodCached(Method paramMethod1, Method paramMethod2);
|
||||
|
||||
private static Object[] getFakeArgs(Method paramMethod) {
|
||||
Class[] arrayOfClass = paramMethod.getParameterTypes();
|
||||
return (arrayOfClass == null || arrayOfClass.length == 0) ? new Object[] { new Object() } : null;
|
||||
}
|
||||
|
||||
public static Field getField(Class<Object> paramClass, String paramString) throws NoSuchFieldException {
|
||||
while (true) {
|
||||
if (paramClass != null && paramClass != Object.class)
|
||||
try {
|
||||
Field field = paramClass.getDeclaredField(paramString);
|
||||
field.setAccessible(true);
|
||||
return field;
|
||||
} catch (Exception exception) {
|
||||
paramClass = (Class)paramClass.getSuperclass();
|
||||
continue;
|
||||
}
|
||||
throw new NoSuchFieldException(paramString);
|
||||
}
|
||||
}
|
||||
|
||||
public static Object getObject(long paramLong) { return getObjectNative(getThreadId(), paramLong); }
|
||||
|
||||
public static long getObjectAddress(Object paramObject) { return Unsafe.getObjectAddress(paramObject); }
|
||||
|
||||
public static native Object getObjectNative(long paramLong1, long paramLong2);
|
||||
|
||||
public static long getThreadId() {
|
||||
Field field = nativePeerField;
|
||||
if (field == null)
|
||||
return 0L;
|
||||
try {
|
||||
return (field.getType() == int.class) ? nativePeerField.getInt(Thread.currentThread()) : nativePeerField.getLong(Thread.currentThread());
|
||||
} catch (IllegalAccessException illegalAccessException) {
|
||||
return 0L;
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean hasJavaArtMethod() {
|
||||
if (SandHookConfig.SDK_INT >= 26)
|
||||
return false;
|
||||
if (artMethodClass != null)
|
||||
return true;
|
||||
try {
|
||||
ClassLoader classLoader = SandHookConfig.initClassLoader;
|
||||
if (classLoader == null) {
|
||||
artMethodClass = Class.forName("java.lang.reflect.ArtMethod");
|
||||
return true;
|
||||
}
|
||||
artMethodClass = Class.forName("java.lang.reflect.ArtMethod", true, SandHookConfig.initClassLoader);
|
||||
return true;
|
||||
} catch (ClassNotFoundException classNotFoundException) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public static void hook(HookWrapper.HookEntity paramHookEntity) throws HookErrorException { // Byte code:
|
||||
// 0: ldc com/swift/sandhook/SandHook
|
||||
// 2: monitorenter
|
||||
// 3: aload_0
|
||||
// 4: ifnull -> 545
|
||||
// 7: aload_0
|
||||
// 8: getfield target : Ljava/lang/reflect/Member;
|
||||
// 11: astore_3
|
||||
// 12: aload_0
|
||||
// 13: getfield hook : Ljava/lang/reflect/Method;
|
||||
// 16: astore #4
|
||||
// 18: aload_0
|
||||
// 19: getfield backup : Ljava/lang/reflect/Method;
|
||||
// 22: astore #5
|
||||
// 24: aload_3
|
||||
// 25: ifnull -> 534
|
||||
// 28: aload #4
|
||||
// 30: ifnull -> 534
|
||||
// 33: getstatic com/swift/sandhook/SandHook.globalHookEntityMap : Ljava/util/Map;
|
||||
// 36: aload_0
|
||||
// 37: getfield target : Ljava/lang/reflect/Member;
|
||||
// 40: invokeinterface containsKey : (Ljava/lang/Object;)Z
|
||||
// 45: ifne -> 486
|
||||
// 48: aload_3
|
||||
// 49: invokestatic canNotHook : (Ljava/lang/reflect/Member;)Z
|
||||
// 52: ifne -> 438
|
||||
// 55: getstatic com/swift/sandhook/SandHookConfig.delayHook : Z
|
||||
// 58: ifeq -> 85
|
||||
// 61: invokestatic canWork : ()Z
|
||||
// 64: ifeq -> 85
|
||||
// 67: aload_0
|
||||
// 68: getfield target : Ljava/lang/reflect/Member;
|
||||
// 71: invokestatic isStaticAndNoInited : (Ljava/lang/reflect/Member;)Z
|
||||
// 74: ifeq -> 85
|
||||
// 77: aload_0
|
||||
// 78: invokestatic addPendingHook : (Lcom/swift/sandhook/wrapper/HookWrapper$HookEntity;)V
|
||||
// 81: ldc com/swift/sandhook/SandHook
|
||||
// 83: monitorexit
|
||||
// 84: return
|
||||
// 85: aload_0
|
||||
// 86: getfield initClass : Z
|
||||
// 89: ifeq -> 97
|
||||
// 92: aload_3
|
||||
// 93: invokestatic resolveStaticMethod : (Ljava/lang/reflect/Member;)Z
|
||||
// 96: pop
|
||||
// 97: aload #5
|
||||
// 99: invokestatic resolveStaticMethod : (Ljava/lang/reflect/Member;)Z
|
||||
// 102: pop
|
||||
// 103: aload #5
|
||||
// 105: ifnull -> 122
|
||||
// 108: aload_0
|
||||
// 109: getfield resolveDexCache : Z
|
||||
// 112: ifeq -> 122
|
||||
// 115: aload #4
|
||||
// 117: aload #5
|
||||
// 119: invokestatic resolveMethod : (Ljava/lang/reflect/Method;Ljava/lang/reflect/Method;)V
|
||||
// 122: aload_3
|
||||
// 123: instanceof java/lang/reflect/Method
|
||||
// 126: ifeq -> 137
|
||||
// 129: aload_3
|
||||
// 130: checkcast java/lang/reflect/Method
|
||||
// 133: iconst_1
|
||||
// 134: invokevirtual setAccessible : (Z)V
|
||||
// 137: getstatic com/swift/sandhook/SandHook.hookModeCallBack : Lcom/swift/sandhook/SandHook$HookModeCallBack;
|
||||
// 140: astore #6
|
||||
// 142: iconst_0
|
||||
// 143: istore_2
|
||||
// 144: aload #6
|
||||
// 146: ifnull -> 561
|
||||
// 149: getstatic com/swift/sandhook/SandHook.hookModeCallBack : Lcom/swift/sandhook/SandHook$HookModeCallBack;
|
||||
// 152: aload_3
|
||||
// 153: invokeinterface hookMode : (Ljava/lang/reflect/Member;)I
|
||||
// 158: istore_1
|
||||
// 159: goto -> 162
|
||||
// 162: getstatic com/swift/sandhook/SandHook.globalHookEntityMap : Ljava/util/Map;
|
||||
// 165: aload_0
|
||||
// 166: getfield target : Ljava/lang/reflect/Member;
|
||||
// 169: aload_0
|
||||
// 170: invokeinterface put : (Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 175: pop
|
||||
// 176: iload_1
|
||||
// 177: ifeq -> 193
|
||||
// 180: aload_3
|
||||
// 181: aload #4
|
||||
// 183: aload #5
|
||||
// 185: iload_1
|
||||
// 186: invokestatic hookMethod : (Ljava/lang/reflect/Member;Ljava/lang/reflect/Method;Ljava/lang/reflect/Method;I)I
|
||||
// 189: istore_1
|
||||
// 190: goto -> 234
|
||||
// 193: aload #4
|
||||
// 195: ldc_w com/swift/sandhook/annotation/HookMode
|
||||
// 198: invokevirtual getAnnotation : (Ljava/lang/Class;)Ljava/lang/annotation/Annotation;
|
||||
// 201: checkcast com/swift/sandhook/annotation/HookMode
|
||||
// 204: astore #6
|
||||
// 206: aload #6
|
||||
// 208: ifnonnull -> 216
|
||||
// 211: iconst_0
|
||||
// 212: istore_1
|
||||
// 213: goto -> 224
|
||||
// 216: aload #6
|
||||
// 218: invokeinterface value : ()I
|
||||
// 223: istore_1
|
||||
// 224: aload_3
|
||||
// 225: aload #4
|
||||
// 227: aload #5
|
||||
// 229: iload_1
|
||||
// 230: invokestatic hookMethod : (Ljava/lang/reflect/Member;Ljava/lang/reflect/Method;Ljava/lang/reflect/Method;I)I
|
||||
// 233: istore_1
|
||||
// 234: iload_1
|
||||
// 235: ifle -> 249
|
||||
// 238: aload #5
|
||||
// 240: ifnull -> 249
|
||||
// 243: aload #5
|
||||
// 245: iconst_1
|
||||
// 246: invokevirtual setAccessible : (Z)V
|
||||
// 249: aload_0
|
||||
// 250: iload_1
|
||||
// 251: putfield hookMode : I
|
||||
// 254: getstatic com/swift/sandhook/SandHook.hookResultCallBack : Lcom/swift/sandhook/SandHook$HookResultCallBack;
|
||||
// 257: ifnull -> 278
|
||||
// 260: getstatic com/swift/sandhook/SandHook.hookResultCallBack : Lcom/swift/sandhook/SandHook$HookResultCallBack;
|
||||
// 263: astore_3
|
||||
// 264: iload_1
|
||||
// 265: ifle -> 270
|
||||
// 268: iconst_1
|
||||
// 269: istore_2
|
||||
// 270: aload_3
|
||||
// 271: iload_2
|
||||
// 272: aload_0
|
||||
// 273: invokeinterface hookResult : (ZLcom/swift/sandhook/wrapper/HookWrapper$HookEntity;)V
|
||||
// 278: iload_1
|
||||
// 279: iflt -> 377
|
||||
// 282: aload_0
|
||||
// 283: getfield backup : Ljava/lang/reflect/Method;
|
||||
// 286: ifnull -> 303
|
||||
// 289: getstatic com/swift/sandhook/SandHook.globalBackupMap : Ljava/util/Map;
|
||||
// 292: aload_0
|
||||
// 293: getfield backup : Ljava/lang/reflect/Method;
|
||||
// 296: aload_0
|
||||
// 297: invokeinterface put : (Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 302: pop
|
||||
// 303: new java/lang/StringBuilder
|
||||
// 306: dup
|
||||
// 307: invokespecial <init> : ()V
|
||||
// 310: astore_3
|
||||
// 311: aload_3
|
||||
// 312: ldc_w 'method <'
|
||||
// 315: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 318: pop
|
||||
// 319: aload_3
|
||||
// 320: aload_0
|
||||
// 321: getfield target : Ljava/lang/reflect/Member;
|
||||
// 324: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 327: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 330: pop
|
||||
// 331: aload_3
|
||||
// 332: ldc_w '> hook <'
|
||||
// 335: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 338: pop
|
||||
// 339: iload_1
|
||||
// 340: iconst_1
|
||||
// 341: if_icmpne -> 566
|
||||
// 344: ldc_w 'inline'
|
||||
// 347: astore_0
|
||||
// 348: goto -> 351
|
||||
// 351: aload_3
|
||||
// 352: aload_0
|
||||
// 353: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 356: pop
|
||||
// 357: aload_3
|
||||
// 358: ldc_w '> success!'
|
||||
// 361: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 364: pop
|
||||
// 365: aload_3
|
||||
// 366: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 369: invokestatic d : (Ljava/lang/String;)I
|
||||
// 372: pop
|
||||
// 373: ldc com/swift/sandhook/SandHook
|
||||
// 375: monitorexit
|
||||
// 376: return
|
||||
// 377: getstatic com/swift/sandhook/SandHook.globalHookEntityMap : Ljava/util/Map;
|
||||
// 380: aload_0
|
||||
// 381: getfield target : Ljava/lang/reflect/Member;
|
||||
// 384: invokeinterface remove : (Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 389: pop
|
||||
// 390: new java/lang/StringBuilder
|
||||
// 393: dup
|
||||
// 394: invokespecial <init> : ()V
|
||||
// 397: astore_3
|
||||
// 398: aload_3
|
||||
// 399: ldc_w 'hook method <'
|
||||
// 402: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 405: pop
|
||||
// 406: aload_3
|
||||
// 407: aload_0
|
||||
// 408: getfield target : Ljava/lang/reflect/Member;
|
||||
// 411: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 414: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 417: pop
|
||||
// 418: aload_3
|
||||
// 419: ldc_w '> error in native!'
|
||||
// 422: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 425: pop
|
||||
// 426: new com/swift/sandhook/wrapper/HookErrorException
|
||||
// 429: dup
|
||||
// 430: aload_3
|
||||
// 431: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 434: invokespecial <init> : (Ljava/lang/String;)V
|
||||
// 437: athrow
|
||||
// 438: new java/lang/StringBuilder
|
||||
// 441: dup
|
||||
// 442: invokespecial <init> : ()V
|
||||
// 445: astore_3
|
||||
// 446: aload_3
|
||||
// 447: ldc_w 'method <'
|
||||
// 450: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 453: pop
|
||||
// 454: aload_3
|
||||
// 455: aload_0
|
||||
// 456: getfield target : Ljava/lang/reflect/Member;
|
||||
// 459: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 462: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 465: pop
|
||||
// 466: aload_3
|
||||
// 467: ldc_w '> can not hook, because of in blacklist!'
|
||||
// 470: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 473: pop
|
||||
// 474: new com/swift/sandhook/wrapper/HookErrorException
|
||||
// 477: dup
|
||||
// 478: aload_3
|
||||
// 479: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 482: invokespecial <init> : (Ljava/lang/String;)V
|
||||
// 485: athrow
|
||||
// 486: new java/lang/StringBuilder
|
||||
// 489: dup
|
||||
// 490: invokespecial <init> : ()V
|
||||
// 493: astore_3
|
||||
// 494: aload_3
|
||||
// 495: ldc_w 'method <'
|
||||
// 498: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 501: pop
|
||||
// 502: aload_3
|
||||
// 503: aload_0
|
||||
// 504: getfield target : Ljava/lang/reflect/Member;
|
||||
// 507: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 510: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 513: pop
|
||||
// 514: aload_3
|
||||
// 515: ldc_w '> has been hooked!'
|
||||
// 518: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 521: pop
|
||||
// 522: new com/swift/sandhook/wrapper/HookErrorException
|
||||
// 525: dup
|
||||
// 526: aload_3
|
||||
// 527: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 530: invokespecial <init> : (Ljava/lang/String;)V
|
||||
// 533: athrow
|
||||
// 534: new com/swift/sandhook/wrapper/HookErrorException
|
||||
// 537: dup
|
||||
// 538: ldc_w 'null input'
|
||||
// 541: invokespecial <init> : (Ljava/lang/String;)V
|
||||
// 544: athrow
|
||||
// 545: new com/swift/sandhook/wrapper/HookErrorException
|
||||
// 548: dup
|
||||
// 549: ldc_w 'null hook entity'
|
||||
// 552: invokespecial <init> : (Ljava/lang/String;)V
|
||||
// 555: athrow
|
||||
// 556: ldc com/swift/sandhook/SandHook
|
||||
// 558: monitorexit
|
||||
// 559: aload_0
|
||||
// 560: athrow
|
||||
// 561: iconst_0
|
||||
// 562: istore_1
|
||||
// 563: goto -> 162
|
||||
// 566: ldc_w 'replacement'
|
||||
// 569: astore_0
|
||||
// 570: goto -> 351
|
||||
// 573: astore_0
|
||||
// 574: goto -> 556
|
||||
// Exception table:
|
||||
// from to target type
|
||||
// 7 24 573 finally
|
||||
// 33 81 573 finally
|
||||
// 85 97 573 finally
|
||||
// 97 103 573 finally
|
||||
// 108 122 573 finally
|
||||
// 122 137 573 finally
|
||||
// 137 142 573 finally
|
||||
// 149 159 573 finally
|
||||
// 162 176 573 finally
|
||||
// 180 190 573 finally
|
||||
// 193 206 573 finally
|
||||
// 216 224 573 finally
|
||||
// 224 234 573 finally
|
||||
// 243 249 573 finally
|
||||
// 249 264 573 finally
|
||||
// 270 278 573 finally
|
||||
// 282 303 573 finally
|
||||
// 303 339 573 finally
|
||||
// 351 373 573 finally
|
||||
// 377 438 573 finally
|
||||
// 438 486 573 finally
|
||||
// 486 534 573 finally
|
||||
// 534 545 573 finally
|
||||
// 545 556 573 finally }
|
||||
|
||||
private static native int hookMethod(Member paramMember, Method paramMethod1, Method paramMethod2, int paramInt);
|
||||
|
||||
private static boolean init() {
|
||||
initTestOffset();
|
||||
initThreadPeer();
|
||||
SandHookMethodResolver.init();
|
||||
return initNative(SandHookConfig.SDK_INT, SandHookConfig.DEBUG);
|
||||
}
|
||||
|
||||
public static native boolean initForPendingHook();
|
||||
|
||||
private static native boolean initNative(int paramInt, boolean paramBoolean);
|
||||
|
||||
private static void initTestAccessFlag() {
|
||||
if (hasJavaArtMethod())
|
||||
try {
|
||||
loadArtMethod();
|
||||
testAccessFlag = ((Integer)getField(artMethodClass, "accessFlags").get(testOffsetArtMethod1)).intValue();
|
||||
return;
|
||||
} catch (Exception exception) {
|
||||
return;
|
||||
}
|
||||
testAccessFlag = ((Integer)getField(Method.class, "accessFlags").get(testOffsetMethod1)).intValue();
|
||||
}
|
||||
|
||||
private static void initTestOffset() {
|
||||
ArtMethodSizeTest.method1();
|
||||
ArtMethodSizeTest.method2();
|
||||
try {
|
||||
testOffsetMethod1 = ArtMethodSizeTest.class.getDeclaredMethod("method1", new Class[0]);
|
||||
testOffsetMethod2 = ArtMethodSizeTest.class.getDeclaredMethod("method2", new Class[0]);
|
||||
initTestAccessFlag();
|
||||
return;
|
||||
} catch (NoSuchMethodException noSuchMethodException) {
|
||||
throw new RuntimeException("SandHook init error", noSuchMethodException);
|
||||
}
|
||||
}
|
||||
|
||||
private static void initThreadPeer() {
|
||||
try {
|
||||
nativePeerField = getField(Thread.class, "nativePeer");
|
||||
return;
|
||||
} catch (NoSuchFieldException noSuchFieldException) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public static native boolean is64Bit();
|
||||
|
||||
private static void loadArtMethod() {
|
||||
try {
|
||||
Field field = getField(Method.class, "artMethod");
|
||||
testOffsetArtMethod1 = field.get(testOffsetMethod1);
|
||||
testOffsetArtMethod2 = field.get(testOffsetMethod2);
|
||||
return;
|
||||
} catch (IllegalAccessException illegalAccessException) {
|
||||
illegalAccessException.printStackTrace();
|
||||
return;
|
||||
} catch (NoSuchFieldException noSuchFieldException) {
|
||||
noSuchFieldException.printStackTrace();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean passApiCheck() { return ReflectionUtils.passApiCheck(); }
|
||||
|
||||
public static boolean resolveStaticMethod(Member paramMember) {
|
||||
if (paramMember == null)
|
||||
return true;
|
||||
try {
|
||||
return true;
|
||||
} catch (ExceptionInInitializerError exceptionInInitializerError) {
|
||||
return false;
|
||||
} finally {
|
||||
paramMember = null;
|
||||
}
|
||||
}
|
||||
|
||||
public static native void setHookMode(int paramInt);
|
||||
|
||||
public static void setHookModeCallBack(HookModeCallBack paramHookModeCallBack) { hookModeCallBack = paramHookModeCallBack; }
|
||||
|
||||
public static void setHookResultCallBack(HookResultCallBack paramHookResultCallBack) { hookResultCallBack = paramHookResultCallBack; }
|
||||
|
||||
public static native void setInlineSafeCheck(boolean paramBoolean);
|
||||
|
||||
public static native boolean setNativeEntry(Member paramMember1, Member paramMember2, long paramLong);
|
||||
|
||||
public static native void skipAllSafeCheck(boolean paramBoolean);
|
||||
|
||||
public static boolean tryDisableProfile(String paramString) {
|
||||
if (SandHookConfig.SDK_INT < 24)
|
||||
return false;
|
||||
try {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("/data/misc/profiles/cur/");
|
||||
stringBuilder.append(SandHookConfig.curUser);
|
||||
stringBuilder.append("/");
|
||||
stringBuilder.append(paramString);
|
||||
stringBuilder.append("/primary.prof");
|
||||
File file = new File(stringBuilder.toString());
|
||||
boolean bool = file.getParentFile().exists();
|
||||
if (!bool)
|
||||
return false;
|
||||
} finally {
|
||||
paramString = null;
|
||||
}
|
||||
}
|
||||
|
||||
@FunctionalInterface
|
||||
public static interface HookModeCallBack {
|
||||
int hookMode(Member param1Member);
|
||||
}
|
||||
|
||||
@FunctionalInterface
|
||||
public static interface HookResultCallBack {
|
||||
void hookResult(boolean param1Boolean, HookWrapper.HookEntity param1HookEntity);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\SandHook.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
47
lib/src/main/java/com/swift/sandhook/SandHookConfig.java
Normal file
47
lib/src/main/java/com/swift/sandhook/SandHookConfig.java
Normal file
@@ -0,0 +1,47 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
import android.os.Build;
|
||||
|
||||
public class SandHookConfig {
|
||||
public static volatile boolean DEBUG;
|
||||
|
||||
public static volatile int SDK_INT = Build.VERSION.SDK_INT;
|
||||
|
||||
public static volatile boolean compiler;
|
||||
|
||||
public static volatile int curUser;
|
||||
|
||||
public static volatile boolean delayHook;
|
||||
|
||||
public static volatile ClassLoader initClassLoader;
|
||||
|
||||
public static volatile LibLoader libLoader;
|
||||
|
||||
public static volatile String libSandHookPath;
|
||||
|
||||
static {
|
||||
DEBUG = true;
|
||||
compiler = true;
|
||||
curUser = 0;
|
||||
delayHook = true;
|
||||
libLoader = new LibLoader() {
|
||||
public void loadLib() {
|
||||
if (SandHookConfig.libSandHookPath == null) {
|
||||
System.loadLibrary("sandhook");
|
||||
return;
|
||||
}
|
||||
System.load(SandHookConfig.libSandHookPath);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
public static interface LibLoader {
|
||||
void loadLib();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\SandHookConfig.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
244
lib/src/main/java/com/swift/sandhook/SandHookMethodResolver.java
Normal file
244
lib/src/main/java/com/swift/sandhook/SandHookMethodResolver.java
Normal file
@@ -0,0 +1,244 @@
|
||||
package com.swift.sandhook;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
public class SandHookMethodResolver {
|
||||
public static Field artMethodField;
|
||||
|
||||
public static boolean canResolvedInJava = false;
|
||||
|
||||
public static Field dexCacheField;
|
||||
|
||||
public static int dexMethodIndex = 0;
|
||||
|
||||
public static Field dexMethodIndexField;
|
||||
|
||||
public static long entryPointFromCompiledCode = 0L;
|
||||
|
||||
public static long entryPointFromInterpreter = 0L;
|
||||
|
||||
public static Field fieldEntryPointFromCompiledCode;
|
||||
|
||||
public static Field fieldEntryPointFromInterpreter;
|
||||
|
||||
public static boolean isArtMethod = false;
|
||||
|
||||
public static long resolvedMethodsAddress;
|
||||
|
||||
public static Field resolvedMethodsField;
|
||||
|
||||
public static Object testArtMethod;
|
||||
|
||||
public static Method testMethod;
|
||||
|
||||
static {
|
||||
|
||||
}
|
||||
|
||||
private static void checkSupport() {
|
||||
try {
|
||||
Field field = SandHook.getField(Method.class, "artMethod");
|
||||
artMethodField = field;
|
||||
testArtMethod = field.get(testMethod);
|
||||
if (SandHook.hasJavaArtMethod() && testArtMethod.getClass() == SandHook.artMethodClass) {
|
||||
checkSupportForArtMethod();
|
||||
isArtMethod = true;
|
||||
return;
|
||||
}
|
||||
if (testArtMethod instanceof Long) {
|
||||
checkSupportForArtMethodId();
|
||||
isArtMethod = false;
|
||||
return;
|
||||
}
|
||||
canResolvedInJava = false;
|
||||
return;
|
||||
} catch (Exception exception) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
private static void checkSupportForArtMethod() throws Exception { // Byte code:
|
||||
// 0: getstatic com/swift/sandhook/SandHook.artMethodClass : Ljava/lang/Class;
|
||||
// 3: ldc 'dexMethodIndex'
|
||||
// 5: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 8: putstatic com/swift/sandhook/SandHookMethodResolver.dexMethodIndexField : Ljava/lang/reflect/Field;
|
||||
// 11: goto -> 25
|
||||
// 14: getstatic com/swift/sandhook/SandHook.artMethodClass : Ljava/lang/Class;
|
||||
// 17: ldc 'methodDexIndex'
|
||||
// 19: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 22: putstatic com/swift/sandhook/SandHookMethodResolver.dexMethodIndexField : Ljava/lang/reflect/Field;
|
||||
// 25: ldc java/lang/Class
|
||||
// 27: ldc 'dexCache'
|
||||
// 29: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 32: astore_0
|
||||
// 33: aload_0
|
||||
// 34: putstatic com/swift/sandhook/SandHookMethodResolver.dexCacheField : Ljava/lang/reflect/Field;
|
||||
// 37: aload_0
|
||||
// 38: getstatic com/swift/sandhook/SandHookMethodResolver.testMethod : Ljava/lang/reflect/Method;
|
||||
// 41: invokevirtual getDeclaringClass : ()Ljava/lang/Class;
|
||||
// 44: invokevirtual get : (Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 47: astore_0
|
||||
// 48: aload_0
|
||||
// 49: invokevirtual getClass : ()Ljava/lang/Class;
|
||||
// 52: ldc 'resolvedMethods'
|
||||
// 54: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 57: astore_1
|
||||
// 58: aload_1
|
||||
// 59: putstatic com/swift/sandhook/SandHookMethodResolver.resolvedMethodsField : Ljava/lang/reflect/Field;
|
||||
// 62: aload_1
|
||||
// 63: aload_0
|
||||
// 64: invokevirtual get : (Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 67: instanceof [Ljava/lang/Object;
|
||||
// 70: ifeq -> 77
|
||||
// 73: iconst_1
|
||||
// 74: putstatic com/swift/sandhook/SandHookMethodResolver.canResolvedInJava : Z
|
||||
// 77: getstatic com/swift/sandhook/SandHookMethodResolver.dexMethodIndexField : Ljava/lang/reflect/Field;
|
||||
// 80: getstatic com/swift/sandhook/SandHookMethodResolver.testArtMethod : Ljava/lang/Object;
|
||||
// 83: invokevirtual get : (Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 86: checkcast java/lang/Integer
|
||||
// 89: invokevirtual intValue : ()I
|
||||
// 92: putstatic com/swift/sandhook/SandHookMethodResolver.dexMethodIndex : I
|
||||
// 95: getstatic com/swift/sandhook/SandHook.artMethodClass : Ljava/lang/Class;
|
||||
// 98: ldc 'entryPointFromQuickCompiledCode'
|
||||
// 100: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 103: putstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 106: goto -> 120
|
||||
// 109: getstatic com/swift/sandhook/SandHook.artMethodClass : Ljava/lang/Class;
|
||||
// 112: ldc 'entryPointFromCompiledCode'
|
||||
// 114: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 117: putstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 120: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 123: invokevirtual getType : ()Ljava/lang/Class;
|
||||
// 126: getstatic java/lang/Integer.TYPE : Ljava/lang/Class;
|
||||
// 129: if_acmpne -> 148
|
||||
// 132: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 135: getstatic com/swift/sandhook/SandHookMethodResolver.testArtMethod : Ljava/lang/Object;
|
||||
// 138: invokevirtual getInt : (Ljava/lang/Object;)I
|
||||
// 141: i2l
|
||||
// 142: putstatic com/swift/sandhook/SandHookMethodResolver.entryPointFromCompiledCode : J
|
||||
// 145: goto -> 172
|
||||
// 148: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 151: invokevirtual getType : ()Ljava/lang/Class;
|
||||
// 154: getstatic java/lang/Long.TYPE : Ljava/lang/Class;
|
||||
// 157: if_acmpne -> 172
|
||||
// 160: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 163: getstatic com/swift/sandhook/SandHookMethodResolver.testArtMethod : Ljava/lang/Object;
|
||||
// 166: invokevirtual getLong : (Ljava/lang/Object;)J
|
||||
// 169: putstatic com/swift/sandhook/SandHookMethodResolver.entryPointFromCompiledCode : J
|
||||
// 172: getstatic com/swift/sandhook/SandHook.artMethodClass : Ljava/lang/Class;
|
||||
// 175: ldc 'entryPointFromInterpreter'
|
||||
// 177: invokestatic getField : (Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/reflect/Field;
|
||||
// 180: astore_0
|
||||
// 181: aload_0
|
||||
// 182: putstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromInterpreter : Ljava/lang/reflect/Field;
|
||||
// 185: aload_0
|
||||
// 186: invokevirtual getType : ()Ljava/lang/Class;
|
||||
// 189: getstatic java/lang/Integer.TYPE : Ljava/lang/Class;
|
||||
// 192: if_acmpne -> 209
|
||||
// 195: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromInterpreter : Ljava/lang/reflect/Field;
|
||||
// 198: getstatic com/swift/sandhook/SandHookMethodResolver.testArtMethod : Ljava/lang/Object;
|
||||
// 201: invokevirtual getInt : (Ljava/lang/Object;)I
|
||||
// 204: i2l
|
||||
// 205: putstatic com/swift/sandhook/SandHookMethodResolver.entryPointFromInterpreter : J
|
||||
// 208: return
|
||||
// 209: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromCompiledCode : Ljava/lang/reflect/Field;
|
||||
// 212: invokevirtual getType : ()Ljava/lang/Class;
|
||||
// 215: getstatic java/lang/Long.TYPE : Ljava/lang/Class;
|
||||
// 218: if_acmpne -> 233
|
||||
// 221: getstatic com/swift/sandhook/SandHookMethodResolver.fieldEntryPointFromInterpreter : Ljava/lang/reflect/Field;
|
||||
// 224: getstatic com/swift/sandhook/SandHookMethodResolver.testArtMethod : Ljava/lang/Object;
|
||||
// 227: invokevirtual getLong : (Ljava/lang/Object;)J
|
||||
// 230: putstatic com/swift/sandhook/SandHookMethodResolver.entryPointFromInterpreter : J
|
||||
// 233: return
|
||||
// 234: astore_0
|
||||
// 235: goto -> 14
|
||||
// 238: astore_0
|
||||
// 239: goto -> 95
|
||||
// 242: astore_0
|
||||
// 243: goto -> 109
|
||||
// 246: astore_0
|
||||
// 247: return
|
||||
// Exception table:
|
||||
// from to target type
|
||||
// 0 11 234 java/lang/NoSuchFieldException
|
||||
// 77 95 238 finally
|
||||
// 95 106 242 finally
|
||||
// 109 120 246 finally
|
||||
// 120 145 246 finally
|
||||
// 148 172 246 finally
|
||||
// 172 208 246 finally
|
||||
// 209 233 246 finally }
|
||||
|
||||
private static void checkSupportForArtMethodId() throws Exception {
|
||||
Field field1 = SandHook.getField(Method.class, "dexMethodIndex");
|
||||
dexMethodIndexField = field1;
|
||||
dexMethodIndex = ((Integer)field1.get(testMethod)).intValue();
|
||||
field1 = SandHook.getField(Class.class, "dexCache");
|
||||
dexCacheField = field1;
|
||||
Object object = field1.get(testMethod.getDeclaringClass());
|
||||
Field field2 = SandHook.getField(object.getClass(), "resolvedMethods");
|
||||
resolvedMethodsField = field2;
|
||||
object = field2.get(object);
|
||||
if (object instanceof Long) {
|
||||
canResolvedInJava = false;
|
||||
resolvedMethodsAddress = ((Long)object).longValue();
|
||||
return;
|
||||
}
|
||||
if (object instanceof long[]) {
|
||||
canResolvedInJava = true;
|
||||
return;
|
||||
}
|
||||
if (object instanceof int[])
|
||||
canResolvedInJava = true;
|
||||
}
|
||||
|
||||
public static void init() {
|
||||
testMethod = SandHook.testOffsetMethod1;
|
||||
checkSupport();
|
||||
}
|
||||
|
||||
private static void resolveInJava(Method paramMethod1, Method paramMethod2) throws Exception {
|
||||
Object object2;
|
||||
Object object1 = dexCacheField.get(paramMethod1.getDeclaringClass());
|
||||
if (isArtMethod) {
|
||||
object2 = artMethodField.get(paramMethod2);
|
||||
int j = ((Integer)dexMethodIndexField.get(object2)).intValue();
|
||||
((Object[])resolvedMethodsField.get(object1))[j] = object2;
|
||||
return;
|
||||
}
|
||||
int i = ((Integer)dexMethodIndexField.get(object2)).intValue();
|
||||
object1 = resolvedMethodsField.get(object1);
|
||||
if (object1 instanceof long[]) {
|
||||
long l = ((Long)artMethodField.get(object2)).longValue();
|
||||
((long[])object1)[i] = l;
|
||||
return;
|
||||
}
|
||||
if (object1 instanceof int[]) {
|
||||
int j = Long.valueOf(((Long)artMethodField.get(object2)).longValue()).intValue();
|
||||
((int[])object1)[i] = j;
|
||||
return;
|
||||
}
|
||||
throw new UnsupportedOperationException("un support");
|
||||
}
|
||||
|
||||
private static void resolveInNative(Method paramMethod1, Method paramMethod2) { SandHook.ensureMethodCached(paramMethod1, paramMethod2); }
|
||||
|
||||
public static void resolveMethod(Method paramMethod1, Method paramMethod2) {
|
||||
if (canResolvedInJava && artMethodField != null)
|
||||
try {
|
||||
resolveInJava(paramMethod1, paramMethod2);
|
||||
return;
|
||||
} catch (Exception exception) {
|
||||
resolveInNative(paramMethod1, paramMethod2);
|
||||
return;
|
||||
}
|
||||
resolveInNative(paramMethod1, paramMethod2);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\SandHookMethodResolver.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.TYPE})
|
||||
public @interface HookClass {
|
||||
Class<?> value();
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\HookClass.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.METHOD})
|
||||
public @interface HookMethod {
|
||||
String value() default "<init>";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\HookMethod.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.METHOD, ElementType.FIELD})
|
||||
public @interface HookMethodBackup {
|
||||
String value() default "<init>";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\HookMethodBackup.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.METHOD})
|
||||
public @interface HookMode {
|
||||
public static final int AUTO = 0;
|
||||
|
||||
public static final int INLINE = 1;
|
||||
|
||||
public static final int REPLACE = 2;
|
||||
|
||||
int value() default 0;
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\HookMode.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.TYPE})
|
||||
public @interface HookReflectClass {
|
||||
String value();
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\HookReflectClass.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.METHOD, ElementType.FIELD})
|
||||
public @interface MethodParams {
|
||||
Class<?>[] value();
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\MethodParams.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,34 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.METHOD, ElementType.FIELD})
|
||||
public @interface MethodReflectParams {
|
||||
public static final String BOOLEAN = "boolean";
|
||||
|
||||
public static final String BYTE = "byte";
|
||||
|
||||
public static final String CHAR = "char";
|
||||
|
||||
public static final String DOUBLE = "double";
|
||||
|
||||
public static final String FLOAT = "float";
|
||||
|
||||
public static final String INT = "int";
|
||||
|
||||
public static final String LONG = "long";
|
||||
|
||||
public static final String SHORT = "short";
|
||||
|
||||
String[] value();
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\MethodReflectParams.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
18
lib/src/main/java/com/swift/sandhook/annotation/Param.java
Normal file
18
lib/src/main/java/com/swift/sandhook/annotation/Param.java
Normal file
@@ -0,0 +1,18 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.PARAMETER})
|
||||
public @interface Param {
|
||||
String value() default "";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\Param.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.METHOD, ElementType.FIELD})
|
||||
public @interface SkipParamCheck {}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\SkipParamCheck.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.swift.sandhook.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.PARAMETER})
|
||||
public @interface ThisObject {}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\annotation\ThisObject.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,62 @@
|
||||
package com.swift.sandhook.blacklist;
|
||||
|
||||
import java.lang.reflect.Member;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
public class HookBlackList {
|
||||
public static Set<Class> classBlackList;
|
||||
|
||||
public static Set<String> methodBlackList = new HashSet<String>();
|
||||
|
||||
public static Set<String> methodUseInHookBridge;
|
||||
|
||||
public static Set<String> methodUseInHookStub;
|
||||
|
||||
static {
|
||||
classBlackList = (Set)new HashSet<Class<?>>();
|
||||
methodUseInHookBridge = new HashSet<String>();
|
||||
methodUseInHookStub = new HashSet<String>();
|
||||
methodBlackList.add("java.lang.reflect.Method.invoke");
|
||||
methodBlackList.add("java.lang.reflect.AccessibleObject.setAccessible");
|
||||
methodUseInHookBridge.add("java.lang.Class.getDeclaredField");
|
||||
methodUseInHookBridge.add("java.lang.reflect.InvocationTargetException.getCause");
|
||||
methodUseInHookStub.add("java.lang.Object.equals");
|
||||
methodUseInHookStub.add("java.lang.Class.isPrimitive");
|
||||
}
|
||||
|
||||
public static final boolean canNotHook(Member paramMember) {
|
||||
if (classBlackList.contains(paramMember.getDeclaringClass()))
|
||||
return true;
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append(paramMember.getDeclaringClass().getName());
|
||||
stringBuilder.append(".");
|
||||
stringBuilder.append(paramMember.getName());
|
||||
String str = stringBuilder.toString();
|
||||
return methodBlackList.contains(str);
|
||||
}
|
||||
|
||||
public static final boolean canNotHookByBridge(Member paramMember) {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append(paramMember.getDeclaringClass().getName());
|
||||
stringBuilder.append(".");
|
||||
stringBuilder.append(paramMember.getName());
|
||||
String str = stringBuilder.toString();
|
||||
return methodUseInHookBridge.contains(str);
|
||||
}
|
||||
|
||||
public static final boolean canNotHookByStub(Member paramMember) {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append(paramMember.getDeclaringClass().getName());
|
||||
stringBuilder.append(".");
|
||||
stringBuilder.append(paramMember.getName());
|
||||
String str = stringBuilder.toString();
|
||||
return methodUseInHookStub.contains(str);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\blacklist\HookBlackList.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
24
lib/src/main/java/com/swift/sandhook/lib/BuildConfig.java
Normal file
24
lib/src/main/java/com/swift/sandhook/lib/BuildConfig.java
Normal file
@@ -0,0 +1,24 @@
|
||||
package com.swift.sandhook.lib;
|
||||
|
||||
public final class BuildConfig {
|
||||
@Deprecated
|
||||
public static final String APPLICATION_ID = "com.swift.sandhook.lib";
|
||||
|
||||
public static final String BUILD_TYPE = "release";
|
||||
|
||||
public static final boolean DEBUG = false;
|
||||
|
||||
public static final String FLAVOR = "";
|
||||
|
||||
public static final String LIBRARY_PACKAGE_NAME = "com.swift.sandhook.lib";
|
||||
|
||||
public static final int VERSION_CODE = 1;
|
||||
|
||||
public static final String VERSION_NAME = "1.0";
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\lib\BuildConfig.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
13
lib/src/main/java/com/swift/sandhook/lib/R.java
Normal file
13
lib/src/main/java/com/swift/sandhook/lib/R.java
Normal file
@@ -0,0 +1,13 @@
|
||||
package com.swift.sandhook.lib;
|
||||
|
||||
public final class R {
|
||||
public static final class string {
|
||||
public static final int app_name = 2131689500;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\lib\R.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
129
lib/src/main/java/com/swift/sandhook/utils/ArtDexOptimizer.java
Normal file
129
lib/src/main/java/com/swift/sandhook/utils/ArtDexOptimizer.java
Normal file
@@ -0,0 +1,129 @@
|
||||
package com.swift.sandhook.utils;
|
||||
|
||||
import android.os.Build;
|
||||
import com.swift.sandhook.SandHook;
|
||||
import com.swift.sandhook.SandHookConfig;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.util.ArrayList;
|
||||
import java.util.concurrent.Executor;
|
||||
import java.util.concurrent.Executors;
|
||||
|
||||
public class ArtDexOptimizer {
|
||||
public static void dexoatAndDisableInline(String paramString1, String paramString2) throws IOException {
|
||||
File file = new File(paramString2);
|
||||
if (!file.exists())
|
||||
file.getParentFile().mkdirs();
|
||||
ArrayList<String> arrayList = new ArrayList();
|
||||
arrayList.add("dex2oat");
|
||||
if (SandHookConfig.SDK_INT >= 24) {
|
||||
arrayList.add("--runtime-arg");
|
||||
arrayList.add("-classpath");
|
||||
arrayList.add("--runtime-arg");
|
||||
arrayList.add("&");
|
||||
}
|
||||
StringBuilder stringBuilder2 = new StringBuilder();
|
||||
stringBuilder2.append("--dex-file=");
|
||||
stringBuilder2.append(paramString1);
|
||||
arrayList.add(stringBuilder2.toString());
|
||||
Object object = new StringBuilder();
|
||||
object.append("--oat-file=");
|
||||
object.append(paramString2);
|
||||
arrayList.add(object.toString());
|
||||
StringBuilder stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("--instruction-set=");
|
||||
if (SandHook.is64Bit()) {
|
||||
String str = "arm64";
|
||||
} else {
|
||||
object = "arm";
|
||||
}
|
||||
stringBuilder1.append((String)object);
|
||||
arrayList.add(stringBuilder1.toString());
|
||||
arrayList.add("--compiler-filter=everything");
|
||||
if (SandHookConfig.SDK_INT >= 22 && SandHookConfig.SDK_INT < 29)
|
||||
arrayList.add("--compile-pic");
|
||||
if (SandHookConfig.SDK_INT > 25) {
|
||||
arrayList.add("--inline-max-code-units=0");
|
||||
} else if (Build.VERSION.SDK_INT >= 23) {
|
||||
arrayList.add("--inline-depth-limit=0");
|
||||
}
|
||||
object = new ProcessBuilder(arrayList);
|
||||
object.redirectErrorStream(true);
|
||||
object = object.start();
|
||||
StreamConsumer.consumeInputStream(object.getInputStream());
|
||||
StreamConsumer.consumeInputStream(object.getErrorStream());
|
||||
try {
|
||||
int i = object.waitFor();
|
||||
if (i == 0)
|
||||
return;
|
||||
object = new StringBuilder();
|
||||
object.append("dex2oat works unsuccessfully, exit code: ");
|
||||
object.append(i);
|
||||
throw new IOException(object.toString());
|
||||
} catch (InterruptedException interruptedException) {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("dex2oat is interrupted, msg: ");
|
||||
stringBuilder1.append(interruptedException.getMessage());
|
||||
throw new IOException(stringBuilder1.toString(), interruptedException);
|
||||
}
|
||||
}
|
||||
|
||||
private static class StreamConsumer {
|
||||
static final Executor STREAM_CONSUMER = Executors.newSingleThreadExecutor();
|
||||
|
||||
static void consumeInputStream(final InputStream is) { STREAM_CONSUMER.execute(new Runnable() {
|
||||
public void run() {
|
||||
if (is == null)
|
||||
return;
|
||||
null = new byte[256];
|
||||
try {
|
||||
while (true) {
|
||||
int i = is.read(null);
|
||||
if (i > 0)
|
||||
continue;
|
||||
break;
|
||||
}
|
||||
} catch (IOException iOException) {
|
||||
try {
|
||||
return;
|
||||
} catch (Exception exception) {}
|
||||
} finally {
|
||||
try {
|
||||
is.close();
|
||||
} catch (Exception exception) {}
|
||||
}
|
||||
}
|
||||
}); }
|
||||
}
|
||||
|
||||
static final class null implements Runnable {
|
||||
public void run() {
|
||||
if (is == null)
|
||||
return;
|
||||
null = new byte[256];
|
||||
try {
|
||||
while (true) {
|
||||
int i = is.read(null);
|
||||
if (i > 0)
|
||||
continue;
|
||||
break;
|
||||
}
|
||||
} catch (IOException iOException) {
|
||||
try {
|
||||
return;
|
||||
} catch (Exception exception) {}
|
||||
} finally {
|
||||
try {
|
||||
is.close();
|
||||
} catch (Exception exception) {}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhoo\\utils\ArtDexOptimizer.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,62 @@
|
||||
package com.swift.sandhook.utils;
|
||||
|
||||
import com.swift.sandhook.SandHookConfig;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Member;
|
||||
import java.lang.reflect.Modifier;
|
||||
|
||||
public class ClassStatusUtils {
|
||||
static Field fieldStatusOfClass;
|
||||
|
||||
static {
|
||||
try {
|
||||
Field field = Class.class.getDeclaredField("status");
|
||||
fieldStatusOfClass = field;
|
||||
field.setAccessible(true);
|
||||
return;
|
||||
} catch (NoSuchFieldException noSuchFieldException) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public static int getClassStatus(Class paramClass, boolean paramBoolean) {
|
||||
int i = 0;
|
||||
if (paramClass == null)
|
||||
return 0;
|
||||
try {
|
||||
int k = fieldStatusOfClass.getInt(paramClass);
|
||||
i = k;
|
||||
} finally {}
|
||||
int j = i;
|
||||
if (paramBoolean)
|
||||
j = (int)(toUnsignedLong(i) >> 28);
|
||||
return j;
|
||||
}
|
||||
|
||||
public static boolean isInitialized(Class paramClass) { return (fieldStatusOfClass == null) ? true : ((SandHookConfig.SDK_INT >= 28) ? ((getClassStatus(paramClass, true) == 14)) : ((SandHookConfig.SDK_INT == 27) ? ((getClassStatus(paramClass, false) == 11)) : ((getClassStatus(paramClass, false) == 10)))); }
|
||||
|
||||
public static boolean isStaticAndNoInited(Member paramMember) {
|
||||
boolean bool2 = false;
|
||||
boolean bool1 = bool2;
|
||||
if (paramMember != null) {
|
||||
if (paramMember instanceof java.lang.reflect.Constructor)
|
||||
return false;
|
||||
Class<?> clazz = paramMember.getDeclaringClass();
|
||||
bool1 = bool2;
|
||||
if (Modifier.isStatic(paramMember.getModifiers())) {
|
||||
bool1 = bool2;
|
||||
if (!isInitialized(clazz))
|
||||
bool1 = true;
|
||||
}
|
||||
}
|
||||
return bool1;
|
||||
}
|
||||
|
||||
public static long toUnsignedLong(int paramInt) { return paramInt & 0xFFFFFFFFL; }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhoo\\utils\ClassStatusUtils.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
131
lib/src/main/java/com/swift/sandhook/utils/FileUtils.java
Normal file
131
lib/src/main/java/com/swift/sandhook/utils/FileUtils.java
Normal file
@@ -0,0 +1,131 @@
|
||||
package com.swift.sandhook.utils;
|
||||
|
||||
import android.os.Build;
|
||||
import android.system.Os;
|
||||
import android.text.TextUtils;
|
||||
import com.swift.sandhook.HookLog;
|
||||
import com.swift.sandhook.SandHookConfig;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.BufferedWriter;
|
||||
import java.io.File;
|
||||
import java.io.FileReader;
|
||||
import java.io.IOException;
|
||||
|
||||
public class FileUtils {
|
||||
public static final boolean IS_USING_PROTECTED_STORAGE;
|
||||
|
||||
static {
|
||||
boolean bool;
|
||||
if (Build.VERSION.SDK_INT >= 24) {
|
||||
bool = true;
|
||||
} else {
|
||||
bool = false;
|
||||
}
|
||||
IS_USING_PROTECTED_STORAGE = bool;
|
||||
}
|
||||
|
||||
public static void chmod(String paramString, int paramInt) throws Exception {
|
||||
Object object;
|
||||
if (SandHookConfig.SDK_INT >= 21)
|
||||
try {
|
||||
Os.chmod(paramString, paramInt);
|
||||
return;
|
||||
} catch (Exception null) {}
|
||||
if ((new File(paramString)).isDirectory()) {
|
||||
object = "chmod -R ";
|
||||
} else {
|
||||
object = "chmod ";
|
||||
}
|
||||
String str = String.format("%o", new Object[] { Integer.valueOf(paramInt) });
|
||||
Runtime runtime = Runtime.getRuntime();
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append((String)object);
|
||||
stringBuilder.append(str);
|
||||
stringBuilder.append(" ");
|
||||
stringBuilder.append(paramString);
|
||||
runtime.exec(stringBuilder.toString()).waitFor();
|
||||
}
|
||||
|
||||
public static void delete(File paramFile) throws IOException {
|
||||
for (File file : paramFile.listFiles()) {
|
||||
if (file.isDirectory()) {
|
||||
delete(file);
|
||||
} else if (!file.delete()) {
|
||||
throw new IOException();
|
||||
}
|
||||
}
|
||||
if (paramFile.delete())
|
||||
return;
|
||||
throw new IOException();
|
||||
}
|
||||
|
||||
public static String getDataPathPrefix() { return IS_USING_PROTECTED_STORAGE ? "/data/user_de/0/" : "/data/data/"; }
|
||||
|
||||
public static String getPackageName(String paramString) {
|
||||
if (TextUtils.isEmpty(paramString)) {
|
||||
HookLog.e("getPackageName using empty dataDir");
|
||||
return "";
|
||||
}
|
||||
int i = paramString.lastIndexOf("/");
|
||||
return (i < 0) ? paramString : paramString.substring(i + 1);
|
||||
}
|
||||
|
||||
public static String readLine(File paramFile) {
|
||||
try {
|
||||
BufferedReader bufferedReader = new BufferedReader(new FileReader(paramFile));
|
||||
} finally {
|
||||
paramFile = null;
|
||||
}
|
||||
}
|
||||
|
||||
public static void writeLine(File paramFile, String paramString) {
|
||||
try {
|
||||
paramFile.createNewFile();
|
||||
} catch (IOException iOException) {}
|
||||
try {
|
||||
BufferedWriter bufferedWriter;
|
||||
} finally {
|
||||
paramString = null;
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("error writing line to file ");
|
||||
stringBuilder.append(paramFile);
|
||||
stringBuilder.append(": ");
|
||||
stringBuilder.append(paramString.getMessage());
|
||||
HookLog.e(stringBuilder.toString());
|
||||
}
|
||||
}
|
||||
|
||||
public static interface FileMode {
|
||||
public static final int MODE_755 = 493;
|
||||
|
||||
public static final int MODE_IRGRP = 32;
|
||||
|
||||
public static final int MODE_IROTH = 4;
|
||||
|
||||
public static final int MODE_IRUSR = 256;
|
||||
|
||||
public static final int MODE_ISGID = 1024;
|
||||
|
||||
public static final int MODE_ISUID = 2048;
|
||||
|
||||
public static final int MODE_ISVTX = 512;
|
||||
|
||||
public static final int MODE_IWGRP = 16;
|
||||
|
||||
public static final int MODE_IWOTH = 2;
|
||||
|
||||
public static final int MODE_IWUSR = 128;
|
||||
|
||||
public static final int MODE_IXGRP = 8;
|
||||
|
||||
public static final int MODE_IXOTH = 1;
|
||||
|
||||
public static final int MODE_IXUSR = 64;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhoo\\utils\FileUtils.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
109
lib/src/main/java/com/swift/sandhook/utils/ParamWrapper.java
Normal file
109
lib/src/main/java/com/swift/sandhook/utils/ParamWrapper.java
Normal file
@@ -0,0 +1,109 @@
|
||||
package com.swift.sandhook.utils;
|
||||
|
||||
import com.swift.sandhook.SandHook;
|
||||
|
||||
public class ParamWrapper {
|
||||
private static boolean is64Bit = SandHook.is64Bit();
|
||||
|
||||
public static Object addressToObject(Class paramClass, long paramLong) { return is64Bit ? addressToObject64(paramClass, paramLong) : addressToObject32(paramClass, (int)paramLong); }
|
||||
|
||||
public static Object addressToObject32(Class<int> paramClass, int paramInt) {
|
||||
if (paramClass == null)
|
||||
return null;
|
||||
if (paramClass.isPrimitive()) {
|
||||
if (paramClass == int.class)
|
||||
return Integer.valueOf(paramInt);
|
||||
if (paramClass == short.class)
|
||||
return Short.valueOf((short)paramInt);
|
||||
if (paramClass == byte.class)
|
||||
return Byte.valueOf((byte)paramInt);
|
||||
if (paramClass == char.class)
|
||||
return Character.valueOf((char)paramInt);
|
||||
if (paramClass == boolean.class) {
|
||||
boolean bool;
|
||||
if (paramInt != 0) {
|
||||
bool = true;
|
||||
} else {
|
||||
bool = false;
|
||||
}
|
||||
return Boolean.valueOf(bool);
|
||||
}
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("unknown type: ");
|
||||
stringBuilder.append(paramClass.toString());
|
||||
throw new RuntimeException(stringBuilder.toString());
|
||||
}
|
||||
return SandHook.getObject(paramInt);
|
||||
}
|
||||
|
||||
public static Object addressToObject64(Class<int> paramClass, long paramLong) {
|
||||
if (paramClass == null)
|
||||
return null;
|
||||
if (paramClass.isPrimitive()) {
|
||||
if (paramClass == int.class)
|
||||
return Integer.valueOf((int)paramLong);
|
||||
if (paramClass == long.class)
|
||||
return Long.valueOf(paramLong);
|
||||
if (paramClass == short.class)
|
||||
return Short.valueOf((short)(int)paramLong);
|
||||
if (paramClass == byte.class)
|
||||
return Byte.valueOf((byte)(int)paramLong);
|
||||
if (paramClass == char.class)
|
||||
return Character.valueOf((char)(int)paramLong);
|
||||
if (paramClass == boolean.class) {
|
||||
boolean bool;
|
||||
if (paramLong != 0L) {
|
||||
bool = true;
|
||||
} else {
|
||||
bool = false;
|
||||
}
|
||||
return Boolean.valueOf(bool);
|
||||
}
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("unknown type: ");
|
||||
stringBuilder.append(paramClass.toString());
|
||||
throw new RuntimeException(stringBuilder.toString());
|
||||
}
|
||||
return SandHook.getObject(paramLong);
|
||||
}
|
||||
|
||||
public static long objectToAddress(Class paramClass, Object paramObject) { return is64Bit ? objectToAddress64(paramClass, paramObject) : objectToAddress32(paramClass, paramObject); }
|
||||
|
||||
public static int objectToAddress32(Class paramClass, Object paramObject) { throw new RuntimeException("d2j fail translate: java.lang.RuntimeException: can not merge I and Z\r\n\tat com.googlecode.dex2jar.ir.TypeClass.merge(TypeClass.java:100)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeRef.updateTypeClass(TypeTransformer.java:174)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.provideAs(TypeTransformer.java:780)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.enexpr(TypeTransformer.java:659)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.exExpr(TypeTransformer.java:719)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.exExpr(TypeTransformer.java:703)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.s1stmt(TypeTransformer.java:810)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.sxStmt(TypeTransformer.java:840)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer$TypeAnalyze.analyze(TypeTransformer.java:206)\r\n\tat com.googlecode.dex2jar.ir.ts.TypeTransformer.transform(TypeTransformer.java:44)\r\n\tat com.googlecode.d2j.dex.Dex2jar$2.optimize(Dex2jar.java:162)\r\n\tat com.googlecode.d2j.dex.Dex2Asm.convertCode(Dex2Asm.java:414)\r\n\tat com.googlecode.d2j.dex.ExDex2Asm.convertCode(ExDex2Asm.java:42)\r\n\tat com.googlecode.d2j.dex.Dex2jar$2.convertCode(Dex2jar.java:128)\r\n\tat com.googlecode.d2j.dex.Dex2Asm.convertMethod(Dex2Asm.java:509)\r\n\tat com.googlecode.d2j.dex.Dex2Asm.convertClass(Dex2Asm.java:406)\r\n\tat com.googlecode.d2j.dex.Dex2Asm.convertDex(Dex2Asm.java:422)\r\n\tat com.googlecode.d2j.dex.Dex2jar.doTranslate(Dex2jar.java:172)\r\n\tat com.googlecode.d2j.dex.Dex2jar.to(Dex2jar.java:272)\r\n\tat com.googlecode.dex2jar.tools.Dex2jarCmd.doCommandLine(Dex2jarCmd.java:108)\r\n\tat com.googlecode.dex2jar.tools.BaseCmd.doMain(BaseCmd.java:288)\r\n\tat com.googlecode.dex2jar.tools.Dex2jarCmd.main(Dex2jarCmd.java:32)\r\n"); }
|
||||
|
||||
public static long objectToAddress64(Class<int> paramClass, Object paramObject) {
|
||||
long l = 0L;
|
||||
if (paramObject == null)
|
||||
return 0L;
|
||||
if (paramClass.isPrimitive()) {
|
||||
if (paramClass == int.class)
|
||||
return ((Integer)paramObject).intValue();
|
||||
if (paramClass == long.class)
|
||||
return ((Long)paramObject).longValue();
|
||||
if (paramClass == short.class)
|
||||
return ((Short)paramObject).shortValue();
|
||||
if (paramClass == byte.class)
|
||||
return ((Byte)paramObject).byteValue();
|
||||
if (paramClass == char.class)
|
||||
return ((Character)paramObject).charValue();
|
||||
if (paramClass == boolean.class) {
|
||||
if (Boolean.TRUE.equals(paramObject))
|
||||
l = 1L;
|
||||
return l;
|
||||
}
|
||||
paramObject = new StringBuilder();
|
||||
paramObject.append("unknown type: ");
|
||||
paramObject.append(paramClass.toString());
|
||||
throw new RuntimeException(paramObject.toString());
|
||||
}
|
||||
return SandHook.getObjectAddress(paramObject);
|
||||
}
|
||||
|
||||
public static boolean support(Class<float> paramClass) { return is64Bit ? ((paramClass != float.class && paramClass != double.class)) : ((paramClass != float.class && paramClass != double.class && paramClass != long.class)); }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhoo\\utils\ParamWrapper.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,49 @@
|
||||
package com.swift.sandhook.utils;
|
||||
|
||||
import android.util.Log;
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
public class ReflectionUtils {
|
||||
static Method addWhiteListMethod;
|
||||
|
||||
public static Method forNameMethod;
|
||||
|
||||
public static Method getMethodMethod;
|
||||
|
||||
static Object vmRuntime;
|
||||
|
||||
static Class vmRuntimeClass;
|
||||
|
||||
static {
|
||||
try {
|
||||
getMethodMethod = Class.class.getDeclaredMethod("getDeclaredMethod", new Class[] { String.class, Class[].class });
|
||||
Method method = Class.class.getDeclaredMethod("forName", new Class[] { String.class });
|
||||
forNameMethod = method;
|
||||
Class clazz = (Class)method.invoke(null, new Object[] { "dalvik.system.VMRuntime" });
|
||||
vmRuntimeClass = clazz;
|
||||
addWhiteListMethod = (Method)getMethodMethod.invoke(clazz, new Object[] { "setHiddenApiExemptions", { String[].class } });
|
||||
vmRuntime = ((Method)getMethodMethod.invoke(vmRuntimeClass, new Object[] { "getRuntime", null })).invoke(null, new Object[0]);
|
||||
return;
|
||||
} catch (Exception exception) {
|
||||
Log.e("ReflectionUtils", "error get methods", exception);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public static void addReflectionWhiteList(String... paramVarArgs) throws Throwable { addWhiteListMethod.invoke(vmRuntime, new Object[] { paramVarArgs }); }
|
||||
|
||||
public static boolean passApiCheck() {
|
||||
try {
|
||||
return true;
|
||||
} finally {
|
||||
Exception exception = null;
|
||||
exception.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhoo\\utils\ReflectionUtils.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
109
lib/src/main/java/com/swift/sandhook/utils/Unsafe.java
Normal file
109
lib/src/main/java/com/swift/sandhook/utils/Unsafe.java
Normal file
@@ -0,0 +1,109 @@
|
||||
package com.swift.sandhook.utils;
|
||||
|
||||
import android.util.Log;
|
||||
import com.swift.sandhook.HookLog;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
public final class Unsafe {
|
||||
private static final String TAG = "Unsafe";
|
||||
|
||||
private static Method arrayBaseOffsetMethod;
|
||||
|
||||
private static Method arrayIndexScaleMethod;
|
||||
|
||||
private static Method getIntMethod;
|
||||
|
||||
private static Method getLongMethod;
|
||||
|
||||
private static Class objectArrayClass = Object[].class;
|
||||
|
||||
private static volatile boolean supported = false;
|
||||
|
||||
private static Object unsafe;
|
||||
|
||||
private static Class unsafeClass;
|
||||
|
||||
static {
|
||||
try {
|
||||
Class<?> clazz = Class.forName("sun.misc.Unsafe");
|
||||
unsafeClass = clazz;
|
||||
Field field = clazz.getDeclaredField("theUnsafe");
|
||||
field.setAccessible(true);
|
||||
unsafe = field.get(null);
|
||||
} catch (Exception exception) {
|
||||
try {
|
||||
Field field = unsafeClass.getDeclaredField("THE_ONE");
|
||||
field.setAccessible(true);
|
||||
unsafe = field.get(null);
|
||||
} catch (Exception exception1) {
|
||||
Log.w("Unsafe", "Unsafe not found o.O");
|
||||
}
|
||||
}
|
||||
if (unsafe != null)
|
||||
try {
|
||||
arrayBaseOffsetMethod = unsafeClass.getDeclaredMethod("arrayBaseOffset", new Class[] { Class.class });
|
||||
arrayIndexScaleMethod = unsafeClass.getDeclaredMethod("arrayIndexScale", new Class[] { Class.class });
|
||||
getIntMethod = unsafeClass.getDeclaredMethod("getInt", new Class[] { Object.class, long.class });
|
||||
getLongMethod = unsafeClass.getDeclaredMethod("getLong", new Class[] { Object.class, long.class });
|
||||
supported = true;
|
||||
return;
|
||||
} catch (Exception exception) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public static int arrayBaseOffset(Class paramClass) {
|
||||
try {
|
||||
return ((Integer)arrayBaseOffsetMethod.invoke(unsafe, new Object[] { paramClass })).intValue();
|
||||
} catch (Exception exception) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
public static int arrayIndexScale(Class paramClass) {
|
||||
try {
|
||||
return ((Integer)arrayIndexScaleMethod.invoke(unsafe, new Object[] { paramClass })).intValue();
|
||||
} catch (Exception exception) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
public static int getInt(Object paramObject, long paramLong) {
|
||||
try {
|
||||
return ((Integer)getIntMethod.invoke(unsafe, new Object[] { paramObject, Long.valueOf(paramLong) })).intValue();
|
||||
} catch (Exception exception) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
public static long getLong(Object paramObject, long paramLong) {
|
||||
try {
|
||||
return ((Long)getLongMethod.invoke(unsafe, new Object[] { paramObject, Long.valueOf(paramLong) })).longValue();
|
||||
} catch (Exception exception) {
|
||||
return 0L;
|
||||
}
|
||||
}
|
||||
|
||||
public static long getObjectAddress(Object paramObject) {
|
||||
try {
|
||||
Object[] arrayOfObject = new Object[1];
|
||||
arrayOfObject[0] = paramObject;
|
||||
if (arrayIndexScale(objectArrayClass) == 8)
|
||||
return getLong(arrayOfObject, arrayBaseOffset(objectArrayClass));
|
||||
int i = getInt(arrayOfObject, arrayBaseOffset(objectArrayClass));
|
||||
return i & 0xFFFFFFFFL;
|
||||
} catch (Exception exception) {
|
||||
HookLog.e("get object address error", exception);
|
||||
return -1L;
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean support() { return supported; }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhoo\\utils\Unsafe.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,13 @@
|
||||
package com.swift.sandhook.wrapper;
|
||||
|
||||
public class HookErrorException extends Exception {
|
||||
public HookErrorException(String paramString) { super(paramString); }
|
||||
|
||||
public HookErrorException(String paramString, Throwable paramThrowable) { super(paramString, paramThrowable); }
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\wrapper\HookErrorException.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
466
lib/src/main/java/com/swift/sandhook/wrapper/HookWrapper.java
Normal file
466
lib/src/main/java/com/swift/sandhook/wrapper/HookWrapper.java
Normal file
@@ -0,0 +1,466 @@
|
||||
package com.swift.sandhook.wrapper;
|
||||
|
||||
import android.text.TextUtils;
|
||||
import com.swift.sandhook.SandHook;
|
||||
import com.swift.sandhook.annotation.HookClass;
|
||||
import com.swift.sandhook.annotation.HookReflectClass;
|
||||
import com.swift.sandhook.annotation.MethodParams;
|
||||
import com.swift.sandhook.annotation.MethodReflectParams;
|
||||
import com.swift.sandhook.annotation.Param;
|
||||
import com.swift.sandhook.annotation.SkipParamCheck;
|
||||
import java.lang.annotation.Annotation;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Member;
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.reflect.Modifier;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.Map;
|
||||
|
||||
public class HookWrapper {
|
||||
public static void addHookClass(ClassLoader paramClassLoader, Class<?> paramClass) throws HookErrorException {
|
||||
Class clazz = getTargetHookClass(paramClassLoader, paramClass);
|
||||
if (clazz != null) {
|
||||
Map<Member, HookEntity> map = getHookMethods(paramClassLoader, clazz, paramClass);
|
||||
try {
|
||||
fillBackupMethod(paramClassLoader, paramClass, map);
|
||||
Iterator<HookEntity> iterator = map.values().iterator();
|
||||
return;
|
||||
} finally {
|
||||
paramClassLoader = null;
|
||||
}
|
||||
}
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("error hook wrapper class :");
|
||||
stringBuilder.append(paramClass.getName());
|
||||
throw new HookErrorException(stringBuilder.toString());
|
||||
}
|
||||
|
||||
public static void addHookClass(ClassLoader paramClassLoader, Class<?>... paramVarArgs) throws HookErrorException {
|
||||
int j = paramVarArgs.length;
|
||||
for (int i = 0; i < j; i++)
|
||||
addHookClass(paramClassLoader, paramVarArgs[i]);
|
||||
}
|
||||
|
||||
public static void addHookClass(Class<?>... paramVarArgs) throws HookErrorException { addHookClass(null, paramVarArgs); }
|
||||
|
||||
public static void checkSignature(Member paramMember, Method paramMethod, Class[] paramArrayOfClass) throws HookErrorException {
|
||||
if (Modifier.isStatic(paramMethod.getModifiers())) {
|
||||
StringBuilder stringBuilder1;
|
||||
if (paramMember instanceof java.lang.reflect.Constructor) {
|
||||
if (!paramMethod.getReturnType().equals(void.class)) {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("error return type! - ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
} else if (stringBuilder1 instanceof Method) {
|
||||
Class<?> clazz = ((Method)stringBuilder1).getReturnType();
|
||||
if (clazz != paramMethod.getReturnType() && !clazz.isAssignableFrom(clazz)) {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("error return type! - ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
}
|
||||
Class[] arrayOfClass2 = paramMethod.getParameterTypes();
|
||||
int i = 0;
|
||||
Class[] arrayOfClass1 = arrayOfClass2;
|
||||
if (arrayOfClass2 == null)
|
||||
arrayOfClass1 = new Class[0];
|
||||
arrayOfClass2 = paramArrayOfClass;
|
||||
if (paramArrayOfClass == null)
|
||||
arrayOfClass2 = new Class[0];
|
||||
if (arrayOfClass2.length == 0 && arrayOfClass1.length == 0)
|
||||
return;
|
||||
boolean bool = Modifier.isStatic(stringBuilder1.getModifiers());
|
||||
byte b = 1;
|
||||
if (!bool) {
|
||||
if (arrayOfClass1.length != 0) {
|
||||
if (arrayOfClass1[0] == stringBuilder1.getDeclaringClass() || arrayOfClass1[0].isAssignableFrom(stringBuilder1.getDeclaringClass())) {
|
||||
if (arrayOfClass1.length != arrayOfClass2.length + 1) {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("hook method pars must match the origin method! ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
} else {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("first par must be this! ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
} else {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("first par must be this! ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
} else if (arrayOfClass1.length == arrayOfClass2.length) {
|
||||
b = 0;
|
||||
} else {
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("hook method pars must match the origin method! ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
while (i < arrayOfClass2.length) {
|
||||
int j = i + b;
|
||||
if (arrayOfClass1[j] == arrayOfClass2[i] || arrayOfClass1[j].isAssignableFrom(arrayOfClass2[i])) {
|
||||
i++;
|
||||
continue;
|
||||
}
|
||||
stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("hook method pars must match the origin method! ");
|
||||
stringBuilder1.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
return;
|
||||
}
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("hook method must static! - ");
|
||||
stringBuilder.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder.toString());
|
||||
}
|
||||
|
||||
private static Class classNameToClass(String paramString, ClassLoader paramClassLoader) throws ClassNotFoundException {
|
||||
byte b;
|
||||
switch (paramString.hashCode()) {
|
||||
default:
|
||||
b = -1;
|
||||
break;
|
||||
case 109413500:
|
||||
if (paramString.equals("short")) {
|
||||
b = 7;
|
||||
break;
|
||||
}
|
||||
case 97526364:
|
||||
if (paramString.equals("float")) {
|
||||
b = 4;
|
||||
break;
|
||||
}
|
||||
case 64711720:
|
||||
if (paramString.equals("boolean")) {
|
||||
b = 0;
|
||||
break;
|
||||
}
|
||||
case 3327612:
|
||||
if (paramString.equals("long")) {
|
||||
b = 6;
|
||||
break;
|
||||
}
|
||||
case 3052374:
|
||||
if (paramString.equals("char")) {
|
||||
b = 2;
|
||||
break;
|
||||
}
|
||||
case 3039496:
|
||||
if (paramString.equals("byte")) {
|
||||
b = 1;
|
||||
break;
|
||||
}
|
||||
case 104431:
|
||||
if (paramString.equals("int")) {
|
||||
b = 5;
|
||||
break;
|
||||
}
|
||||
case -1325958191:
|
||||
if (paramString.equals("double")) {
|
||||
b = 3;
|
||||
break;
|
||||
}
|
||||
}
|
||||
switch (b) {
|
||||
default:
|
||||
return (paramClassLoader == null) ? Class.forName(paramString) : Class.forName(paramString, true, paramClassLoader);
|
||||
case 7:
|
||||
return short.class;
|
||||
case 6:
|
||||
return long.class;
|
||||
case 5:
|
||||
return int.class;
|
||||
case 4:
|
||||
return float.class;
|
||||
case 3:
|
||||
return double.class;
|
||||
case 2:
|
||||
return char.class;
|
||||
case 1:
|
||||
return byte.class;
|
||||
case 0:
|
||||
break;
|
||||
}
|
||||
return boolean.class;
|
||||
}
|
||||
|
||||
private static void fillBackupMethod(ClassLoader paramClassLoader, Class<?> paramClass, Map<Member, HookEntity> paramMap) {
|
||||
try {
|
||||
Field[] arrayOfField = paramClass.getDeclaredFields();
|
||||
} finally {
|
||||
paramClass = null;
|
||||
}
|
||||
}
|
||||
|
||||
private static Map<Member, HookEntity> getHookMethods(ClassLoader paramClassLoader, Class paramClass, Class<?> paramClass1) throws HookErrorException {
|
||||
StringBuilder stringBuilder2;
|
||||
HashMap<Object, Object> hashMap = new HashMap<Object, Object>();
|
||||
try {
|
||||
Method[] arrayOfMethod = paramClass1.getDeclaredMethods();
|
||||
} finally {
|
||||
paramClass1 = null;
|
||||
}
|
||||
StringBuilder stringBuilder1 = new StringBuilder();
|
||||
stringBuilder1.append("error hook wrapper class :");
|
||||
stringBuilder1.append(stringBuilder2.getName());
|
||||
throw new HookErrorException(stringBuilder1.toString());
|
||||
}
|
||||
|
||||
private static int getParsCount(Method paramMethod) {
|
||||
Class[] arrayOfClass = paramMethod.getParameterTypes();
|
||||
return (arrayOfClass == null) ? 0 : arrayOfClass.length;
|
||||
}
|
||||
|
||||
private static Class getRealParType(ClassLoader paramClassLoader, Class paramClass, Annotation[] paramArrayOfAnnotation, boolean paramBoolean) throws Exception {
|
||||
if (paramArrayOfAnnotation != null) {
|
||||
if (paramArrayOfAnnotation.length == 0)
|
||||
return paramClass;
|
||||
int j = paramArrayOfAnnotation.length;
|
||||
int i;
|
||||
for (i = 0; i < j; i++) {
|
||||
Annotation annotation = paramArrayOfAnnotation[i];
|
||||
if (annotation instanceof Param) {
|
||||
Param param = (Param)annotation;
|
||||
if (TextUtils.isEmpty(param.value()))
|
||||
return paramClass;
|
||||
Class<?> clazz = classNameToClass(param.value(), paramClassLoader);
|
||||
if (!paramBoolean && !clazz.equals(paramClass)) {
|
||||
if (paramClass.isAssignableFrom(clazz))
|
||||
return clazz;
|
||||
throw new ClassCastException("hook method par cast error!");
|
||||
}
|
||||
return clazz;
|
||||
}
|
||||
}
|
||||
}
|
||||
return paramClass;
|
||||
}
|
||||
|
||||
private static Class getTargetHookClass(ClassLoader paramClassLoader, Class<?> paramClass) {
|
||||
HookClass hookClass = paramClass.getAnnotation(HookClass.class);
|
||||
HookReflectClass hookReflectClass = paramClass.getAnnotation(HookReflectClass.class);
|
||||
if (hookClass != null)
|
||||
return hookClass.value();
|
||||
if (hookReflectClass != null) {
|
||||
if (paramClassLoader == null)
|
||||
try {
|
||||
return Class.forName(hookReflectClass.value());
|
||||
} catch (ClassNotFoundException classNotFoundException) {
|
||||
return null;
|
||||
}
|
||||
return Class.forName(hookReflectClass.value(), true, (ClassLoader)classNotFoundException);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private static boolean hasThisObject(Method paramMethod) {
|
||||
Annotation[][] arrayOfAnnotation = paramMethod.getParameterAnnotations();
|
||||
return (arrayOfAnnotation != null) ? ((arrayOfAnnotation.length == 0) ? false : isThisObject(arrayOfAnnotation[0])) : false;
|
||||
}
|
||||
|
||||
private static boolean isThisObject(Annotation[] paramArrayOfAnnotation) {
|
||||
if (paramArrayOfAnnotation != null) {
|
||||
if (paramArrayOfAnnotation.length == 0)
|
||||
return false;
|
||||
int j = paramArrayOfAnnotation.length;
|
||||
for (int i = 0; i < j; i++) {
|
||||
if (paramArrayOfAnnotation[i] instanceof com.swift.sandhook.annotation.ThisObject)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private static Class[] parseMethodPars(ClassLoader paramClassLoader, Field paramField) throws HookErrorException {
|
||||
Object object = paramField.getAnnotation(MethodParams.class);
|
||||
MethodReflectParams methodReflectParams = paramField.getAnnotation(MethodReflectParams.class);
|
||||
if (object != null)
|
||||
return object.value();
|
||||
object = null;
|
||||
if (methodReflectParams != null) {
|
||||
if ((methodReflectParams.value()).length == 0)
|
||||
return null;
|
||||
Class[] arrayOfClass = new Class[(methodReflectParams.value()).length];
|
||||
int i = 0;
|
||||
while (true) {
|
||||
Class[] arrayOfClass1 = arrayOfClass;
|
||||
if (i < (methodReflectParams.value()).length)
|
||||
try {
|
||||
arrayOfClass[i] = classNameToClass(methodReflectParams.value()[i], paramClassLoader);
|
||||
i++;
|
||||
continue;
|
||||
} catch (ClassNotFoundException classNotFoundException) {
|
||||
object = new StringBuilder();
|
||||
object.append("hook method pars error: ");
|
||||
object.append(paramField.getName());
|
||||
throw new HookErrorException(object.toString(), classNotFoundException);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return (Class[])object;
|
||||
}
|
||||
|
||||
private static Class[] parseMethodPars(ClassLoader paramClassLoader, Method paramMethod) throws HookErrorException {
|
||||
MethodParams methodParams = paramMethod.getAnnotation(MethodParams.class);
|
||||
MethodReflectParams methodReflectParams = paramMethod.getAnnotation(MethodReflectParams.class);
|
||||
if (methodParams != null)
|
||||
return methodParams.value();
|
||||
if (methodReflectParams != null) {
|
||||
if ((methodReflectParams.value()).length == 0)
|
||||
return null;
|
||||
Class[] arrayOfClass = new Class[(methodReflectParams.value()).length];
|
||||
int i = 0;
|
||||
while (i < (methodReflectParams.value()).length) {
|
||||
try {
|
||||
arrayOfClass[i] = classNameToClass(methodReflectParams.value()[i], paramClassLoader);
|
||||
i++;
|
||||
} catch (ClassNotFoundException classNotFoundException) {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("hook method pars error: ");
|
||||
stringBuilder.append(paramMethod.getName());
|
||||
throw new HookErrorException(stringBuilder.toString(), classNotFoundException);
|
||||
}
|
||||
}
|
||||
return arrayOfClass;
|
||||
}
|
||||
return (getParsCount(paramMethod) > 0) ? ((getParsCount(paramMethod) == 1) ? (hasThisObject(paramMethod) ? parseMethodParsNew((ClassLoader)classNotFoundException, paramMethod) : null) : parseMethodParsNew((ClassLoader)classNotFoundException, paramMethod)) : null;
|
||||
}
|
||||
|
||||
private static Class[] parseMethodParsNew(ClassLoader paramClassLoader, Method paramMethod) throws HookErrorException {
|
||||
Class[] arrayOfClass = paramMethod.getParameterTypes();
|
||||
Class clazz2 = null;
|
||||
Class clazz1 = null;
|
||||
if (arrayOfClass != null) {
|
||||
if (arrayOfClass.length == 0)
|
||||
return null;
|
||||
Annotation[][] arrayOfAnnotation = paramMethod.getParameterAnnotations();
|
||||
int i = 0;
|
||||
int j = 0;
|
||||
while (true) {
|
||||
Annotation[] arrayOfAnnotation1;
|
||||
Object[] arrayOfObject;
|
||||
clazz2 = clazz1;
|
||||
if (i < arrayOfAnnotation.length) {
|
||||
clazz2 = arrayOfClass[i];
|
||||
arrayOfAnnotation1 = arrayOfAnnotation[i];
|
||||
if (i == 0) {
|
||||
if (isThisObject(arrayOfAnnotation1)) {
|
||||
arrayOfObject = (Object[])new Class[arrayOfAnnotation.length - 1];
|
||||
} else {
|
||||
arrayOfObject = (Object[])new Class[arrayOfAnnotation.length];
|
||||
try {
|
||||
arrayOfObject[j] = getRealParType(paramClassLoader, clazz2, arrayOfAnnotation1, paramMethod.isAnnotationPresent((Class)SkipParamCheck.class));
|
||||
j++;
|
||||
continue;
|
||||
} catch (Exception exception) {
|
||||
arrayOfObject = (Object[])new StringBuilder();
|
||||
arrayOfObject.append("hook method <");
|
||||
arrayOfObject.append(paramMethod.getName());
|
||||
arrayOfObject.append("> parser pars error");
|
||||
throw new HookErrorException(arrayOfObject.toString(), exception);
|
||||
}
|
||||
}
|
||||
continue;
|
||||
}
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
try {
|
||||
arrayOfObject[j] = getRealParType((ClassLoader)exception, clazz2, arrayOfAnnotation1, paramMethod.isAnnotationPresent((Class)SkipParamCheck.class));
|
||||
j++;
|
||||
continue;
|
||||
} catch (Exception exception1) {
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
stringBuilder.append("hook method <");
|
||||
stringBuilder.append(paramMethod.getName());
|
||||
stringBuilder.append("> parser pars error");
|
||||
throw new HookErrorException(stringBuilder.toString(), exception1);
|
||||
}
|
||||
i++;
|
||||
}
|
||||
}
|
||||
return (Class[])clazz2;
|
||||
}
|
||||
|
||||
private static boolean samePars(ClassLoader paramClassLoader, Field paramField, Class[] paramArrayOfClass) {
|
||||
Class[] arrayOfClass;
|
||||
try {
|
||||
Class[] arrayOfClass1 = parseMethodPars(paramClassLoader, paramField);
|
||||
if (arrayOfClass1 == null && paramField.isAnnotationPresent((Class)SkipParamCheck.class))
|
||||
return true;
|
||||
arrayOfObject = (Object[])paramArrayOfClass;
|
||||
if (paramArrayOfClass == null)
|
||||
arrayOfObject = (Object[])new Class[0];
|
||||
arrayOfClass = arrayOfClass1;
|
||||
if (arrayOfClass1 == null)
|
||||
arrayOfClass = new Class[0];
|
||||
if (arrayOfObject.length != arrayOfClass.length)
|
||||
return false;
|
||||
} catch (HookErrorException arrayOfObject) {
|
||||
return false;
|
||||
}
|
||||
int i;
|
||||
for (i = 0; i < arrayOfObject.length; i++) {
|
||||
Object object = arrayOfObject[i];
|
||||
Class clazz = arrayOfClass[i];
|
||||
if (object != clazz)
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public static class HookEntity {
|
||||
public Method backup;
|
||||
|
||||
public boolean backupIsStub = true;
|
||||
|
||||
public Method hook;
|
||||
|
||||
public boolean hookIsStub = false;
|
||||
|
||||
public int hookMode;
|
||||
|
||||
public boolean initClass = true;
|
||||
|
||||
public Class[] pars;
|
||||
|
||||
public boolean resolveDexCache = true;
|
||||
|
||||
public Member target;
|
||||
|
||||
public HookEntity(Member param1Member) { this.target = param1Member; }
|
||||
|
||||
public HookEntity(Member param1Member, Method param1Method1, Method param1Method2) {
|
||||
this.target = param1Member;
|
||||
this.hook = param1Method1;
|
||||
this.backup = param1Method2;
|
||||
}
|
||||
|
||||
public HookEntity(Member param1Member, Method param1Method1, Method param1Method2, boolean param1Boolean) {
|
||||
this.target = param1Member;
|
||||
this.hook = param1Method1;
|
||||
this.backup = param1Method2;
|
||||
this.resolveDexCache = param1Boolean;
|
||||
}
|
||||
|
||||
public Object callOrigin(Object param1Object, Object... param1VarArgs) throws Throwable { return SandHook.callOriginMethod(this.backupIsStub, this.target, this.backup, param1Object, param1VarArgs); }
|
||||
|
||||
public boolean isCtor() { return this.target instanceof java.lang.reflect.Constructor; }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\wrapper\HookWrapper.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
@@ -0,0 +1,748 @@
|
||||
package com.swift.sandhook.wrapper;
|
||||
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.reflect.Proxy;
|
||||
|
||||
public class StubMethodsFactory {
|
||||
private static volatile int curStub = 0;
|
||||
|
||||
static final int maxStub = 300;
|
||||
|
||||
private static Method proxyGenClass;
|
||||
|
||||
static {
|
||||
try {
|
||||
Method method = Proxy.class.getDeclaredMethod("generateProxy", new Class[] { String.class, Class[].class, ClassLoader.class, Method[].class, Class[][].class });
|
||||
return;
|
||||
} finally {
|
||||
Exception exception = null;
|
||||
exception.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
public static Method getStubMethod() { // Byte code:
|
||||
// 0: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 2: monitorenter
|
||||
// 3: getstatic com/swift/sandhook/wrapper/StubMethodsFactory.curStub : I
|
||||
// 6: istore_0
|
||||
// 7: iload_0
|
||||
// 8: sipush #300
|
||||
// 11: if_icmpgt -> 64
|
||||
// 14: new java/lang/StringBuilder
|
||||
// 17: dup
|
||||
// 18: invokespecial <init> : ()V
|
||||
// 21: astore_1
|
||||
// 22: aload_1
|
||||
// 23: ldc 'stub'
|
||||
// 25: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 28: pop
|
||||
// 29: getstatic com/swift/sandhook/wrapper/StubMethodsFactory.curStub : I
|
||||
// 32: istore_0
|
||||
// 33: iload_0
|
||||
// 34: iconst_1
|
||||
// 35: iadd
|
||||
// 36: putstatic com/swift/sandhook/wrapper/StubMethodsFactory.curStub : I
|
||||
// 39: aload_1
|
||||
// 40: iload_0
|
||||
// 41: invokevirtual append : (I)Ljava/lang/StringBuilder;
|
||||
// 44: pop
|
||||
// 45: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 47: aload_1
|
||||
// 48: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 51: iconst_0
|
||||
// 52: anewarray java/lang/Class
|
||||
// 55: invokevirtual getDeclaredMethod : (Ljava/lang/String;[Ljava/lang/Class;)Ljava/lang/reflect/Method;
|
||||
// 58: astore_1
|
||||
// 59: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 61: monitorexit
|
||||
// 62: aload_1
|
||||
// 63: areturn
|
||||
// 64: getstatic com/swift/sandhook/wrapper/StubMethodsFactory.curStub : I
|
||||
// 67: iconst_1
|
||||
// 68: iadd
|
||||
// 69: putstatic com/swift/sandhook/wrapper/StubMethodsFactory.curStub : I
|
||||
// 72: getstatic com/swift/sandhook/wrapper/StubMethodsFactory.proxyGenClass : Ljava/lang/reflect/Method;
|
||||
// 75: astore_1
|
||||
// 76: new java/lang/StringBuilder
|
||||
// 79: dup
|
||||
// 80: invokespecial <init> : ()V
|
||||
// 83: astore_2
|
||||
// 84: aload_2
|
||||
// 85: ldc 'SandHookerStubClass_'
|
||||
// 87: invokevirtual append : (Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
// 90: pop
|
||||
// 91: aload_2
|
||||
// 92: getstatic com/swift/sandhook/wrapper/StubMethodsFactory.curStub : I
|
||||
// 95: invokevirtual append : (I)Ljava/lang/StringBuilder;
|
||||
// 98: pop
|
||||
// 99: aload_1
|
||||
// 100: aconst_null
|
||||
// 101: iconst_5
|
||||
// 102: anewarray java/lang/Object
|
||||
// 105: dup
|
||||
// 106: iconst_0
|
||||
// 107: aload_2
|
||||
// 108: invokevirtual toString : ()Ljava/lang/String;
|
||||
// 111: aastore
|
||||
// 112: dup
|
||||
// 113: iconst_1
|
||||
// 114: aconst_null
|
||||
// 115: aastore
|
||||
// 116: dup
|
||||
// 117: iconst_2
|
||||
// 118: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 120: invokevirtual getClassLoader : ()Ljava/lang/ClassLoader;
|
||||
// 123: aastore
|
||||
// 124: dup
|
||||
// 125: iconst_3
|
||||
// 126: iconst_1
|
||||
// 127: anewarray java/lang/reflect/Method
|
||||
// 130: dup
|
||||
// 131: iconst_0
|
||||
// 132: getstatic com/swift/sandhook/wrapper/StubMethodsFactory.proxyGenClass : Ljava/lang/reflect/Method;
|
||||
// 135: aastore
|
||||
// 136: aastore
|
||||
// 137: dup
|
||||
// 138: iconst_4
|
||||
// 139: aconst_null
|
||||
// 140: aastore
|
||||
// 141: invokevirtual invoke : (Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;
|
||||
// 144: checkcast java/lang/Class
|
||||
// 147: invokevirtual getDeclaredMethods : ()[Ljava/lang/reflect/Method;
|
||||
// 150: iconst_0
|
||||
// 151: aaload
|
||||
// 152: astore_1
|
||||
// 153: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 155: monitorexit
|
||||
// 156: aload_1
|
||||
// 157: areturn
|
||||
// 158: astore_1
|
||||
// 159: aload_1
|
||||
// 160: invokevirtual printStackTrace : ()V
|
||||
// 163: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 165: monitorexit
|
||||
// 166: aconst_null
|
||||
// 167: areturn
|
||||
// 168: astore_1
|
||||
// 169: ldc com/swift/sandhook/wrapper/StubMethodsFactory
|
||||
// 171: monitorexit
|
||||
// 172: aload_1
|
||||
// 173: athrow
|
||||
// 174: astore_1
|
||||
// 175: goto -> 3
|
||||
// Exception table:
|
||||
// from to target type
|
||||
// 3 7 168 finally
|
||||
// 14 59 174 java/lang/NoSuchMethodException
|
||||
// 14 59 168 finally
|
||||
// 64 153 158 finally
|
||||
// 159 163 168 finally }
|
||||
|
||||
public void stub0() {}
|
||||
|
||||
public void stub1() {}
|
||||
|
||||
public void stub10() {}
|
||||
|
||||
public void stub100() {}
|
||||
|
||||
public void stub101() {}
|
||||
|
||||
public void stub102() {}
|
||||
|
||||
public void stub103() {}
|
||||
|
||||
public void stub104() {}
|
||||
|
||||
public void stub105() {}
|
||||
|
||||
public void stub106() {}
|
||||
|
||||
public void stub107() {}
|
||||
|
||||
public void stub108() {}
|
||||
|
||||
public void stub109() {}
|
||||
|
||||
public void stub11() {}
|
||||
|
||||
public void stub110() {}
|
||||
|
||||
public void stub111() {}
|
||||
|
||||
public void stub112() {}
|
||||
|
||||
public void stub113() {}
|
||||
|
||||
public void stub114() {}
|
||||
|
||||
public void stub115() {}
|
||||
|
||||
public void stub116() {}
|
||||
|
||||
public void stub117() {}
|
||||
|
||||
public void stub118() {}
|
||||
|
||||
public void stub119() {}
|
||||
|
||||
public void stub12() {}
|
||||
|
||||
public void stub120() {}
|
||||
|
||||
public void stub121() {}
|
||||
|
||||
public void stub122() {}
|
||||
|
||||
public void stub123() {}
|
||||
|
||||
public void stub124() {}
|
||||
|
||||
public void stub125() {}
|
||||
|
||||
public void stub126() {}
|
||||
|
||||
public void stub127() {}
|
||||
|
||||
public void stub128() {}
|
||||
|
||||
public void stub129() {}
|
||||
|
||||
public void stub13() {}
|
||||
|
||||
public void stub130() {}
|
||||
|
||||
public void stub131() {}
|
||||
|
||||
public void stub132() {}
|
||||
|
||||
public void stub133() {}
|
||||
|
||||
public void stub134() {}
|
||||
|
||||
public void stub135() {}
|
||||
|
||||
public void stub136() {}
|
||||
|
||||
public void stub137() {}
|
||||
|
||||
public void stub138() {}
|
||||
|
||||
public void stub139() {}
|
||||
|
||||
public void stub14() {}
|
||||
|
||||
public void stub140() {}
|
||||
|
||||
public void stub141() {}
|
||||
|
||||
public void stub142() {}
|
||||
|
||||
public void stub143() {}
|
||||
|
||||
public void stub144() {}
|
||||
|
||||
public void stub145() {}
|
||||
|
||||
public void stub146() {}
|
||||
|
||||
public void stub147() {}
|
||||
|
||||
public void stub148() {}
|
||||
|
||||
public void stub149() {}
|
||||
|
||||
public void stub15() {}
|
||||
|
||||
public void stub150() {}
|
||||
|
||||
public void stub151() {}
|
||||
|
||||
public void stub152() {}
|
||||
|
||||
public void stub153() {}
|
||||
|
||||
public void stub154() {}
|
||||
|
||||
public void stub155() {}
|
||||
|
||||
public void stub156() {}
|
||||
|
||||
public void stub157() {}
|
||||
|
||||
public void stub158() {}
|
||||
|
||||
public void stub159() {}
|
||||
|
||||
public void stub16() {}
|
||||
|
||||
public void stub160() {}
|
||||
|
||||
public void stub161() {}
|
||||
|
||||
public void stub162() {}
|
||||
|
||||
public void stub163() {}
|
||||
|
||||
public void stub164() {}
|
||||
|
||||
public void stub165() {}
|
||||
|
||||
public void stub166() {}
|
||||
|
||||
public void stub167() {}
|
||||
|
||||
public void stub168() {}
|
||||
|
||||
public void stub169() {}
|
||||
|
||||
public void stub17() {}
|
||||
|
||||
public void stub170() {}
|
||||
|
||||
public void stub171() {}
|
||||
|
||||
public void stub172() {}
|
||||
|
||||
public void stub173() {}
|
||||
|
||||
public void stub174() {}
|
||||
|
||||
public void stub175() {}
|
||||
|
||||
public void stub176() {}
|
||||
|
||||
public void stub177() {}
|
||||
|
||||
public void stub178() {}
|
||||
|
||||
public void stub179() {}
|
||||
|
||||
public void stub18() {}
|
||||
|
||||
public void stub180() {}
|
||||
|
||||
public void stub181() {}
|
||||
|
||||
public void stub182() {}
|
||||
|
||||
public void stub183() {}
|
||||
|
||||
public void stub184() {}
|
||||
|
||||
public void stub185() {}
|
||||
|
||||
public void stub186() {}
|
||||
|
||||
public void stub187() {}
|
||||
|
||||
public void stub188() {}
|
||||
|
||||
public void stub189() {}
|
||||
|
||||
public void stub19() {}
|
||||
|
||||
public void stub190() {}
|
||||
|
||||
public void stub191() {}
|
||||
|
||||
public void stub192() {}
|
||||
|
||||
public void stub193() {}
|
||||
|
||||
public void stub194() {}
|
||||
|
||||
public void stub195() {}
|
||||
|
||||
public void stub196() {}
|
||||
|
||||
public void stub197() {}
|
||||
|
||||
public void stub198() {}
|
||||
|
||||
public void stub199() {}
|
||||
|
||||
public void stub2() {}
|
||||
|
||||
public void stub20() {}
|
||||
|
||||
public void stub200() {}
|
||||
|
||||
public void stub201() {}
|
||||
|
||||
public void stub202() {}
|
||||
|
||||
public void stub203() {}
|
||||
|
||||
public void stub204() {}
|
||||
|
||||
public void stub205() {}
|
||||
|
||||
public void stub206() {}
|
||||
|
||||
public void stub207() {}
|
||||
|
||||
public void stub208() {}
|
||||
|
||||
public void stub209() {}
|
||||
|
||||
public void stub21() {}
|
||||
|
||||
public void stub210() {}
|
||||
|
||||
public void stub211() {}
|
||||
|
||||
public void stub212() {}
|
||||
|
||||
public void stub213() {}
|
||||
|
||||
public void stub214() {}
|
||||
|
||||
public void stub215() {}
|
||||
|
||||
public void stub216() {}
|
||||
|
||||
public void stub217() {}
|
||||
|
||||
public void stub218() {}
|
||||
|
||||
public void stub219() {}
|
||||
|
||||
public void stub22() {}
|
||||
|
||||
public void stub220() {}
|
||||
|
||||
public void stub221() {}
|
||||
|
||||
public void stub222() {}
|
||||
|
||||
public void stub223() {}
|
||||
|
||||
public void stub224() {}
|
||||
|
||||
public void stub225() {}
|
||||
|
||||
public void stub226() {}
|
||||
|
||||
public void stub227() {}
|
||||
|
||||
public void stub228() {}
|
||||
|
||||
public void stub229() {}
|
||||
|
||||
public void stub23() {}
|
||||
|
||||
public void stub230() {}
|
||||
|
||||
public void stub231() {}
|
||||
|
||||
public void stub232() {}
|
||||
|
||||
public void stub233() {}
|
||||
|
||||
public void stub234() {}
|
||||
|
||||
public void stub235() {}
|
||||
|
||||
public void stub236() {}
|
||||
|
||||
public void stub237() {}
|
||||
|
||||
public void stub238() {}
|
||||
|
||||
public void stub239() {}
|
||||
|
||||
public void stub24() {}
|
||||
|
||||
public void stub240() {}
|
||||
|
||||
public void stub241() {}
|
||||
|
||||
public void stub242() {}
|
||||
|
||||
public void stub243() {}
|
||||
|
||||
public void stub244() {}
|
||||
|
||||
public void stub245() {}
|
||||
|
||||
public void stub246() {}
|
||||
|
||||
public void stub247() {}
|
||||
|
||||
public void stub248() {}
|
||||
|
||||
public void stub249() {}
|
||||
|
||||
public void stub25() {}
|
||||
|
||||
public void stub250() {}
|
||||
|
||||
public void stub251() {}
|
||||
|
||||
public void stub252() {}
|
||||
|
||||
public void stub253() {}
|
||||
|
||||
public void stub254() {}
|
||||
|
||||
public void stub255() {}
|
||||
|
||||
public void stub256() {}
|
||||
|
||||
public void stub257() {}
|
||||
|
||||
public void stub258() {}
|
||||
|
||||
public void stub259() {}
|
||||
|
||||
public void stub26() {}
|
||||
|
||||
public void stub260() {}
|
||||
|
||||
public void stub261() {}
|
||||
|
||||
public void stub262() {}
|
||||
|
||||
public void stub263() {}
|
||||
|
||||
public void stub264() {}
|
||||
|
||||
public void stub265() {}
|
||||
|
||||
public void stub266() {}
|
||||
|
||||
public void stub267() {}
|
||||
|
||||
public void stub268() {}
|
||||
|
||||
public void stub269() {}
|
||||
|
||||
public void stub27() {}
|
||||
|
||||
public void stub270() {}
|
||||
|
||||
public void stub271() {}
|
||||
|
||||
public void stub272() {}
|
||||
|
||||
public void stub273() {}
|
||||
|
||||
public void stub274() {}
|
||||
|
||||
public void stub275() {}
|
||||
|
||||
public void stub276() {}
|
||||
|
||||
public void stub277() {}
|
||||
|
||||
public void stub278() {}
|
||||
|
||||
public void stub279() {}
|
||||
|
||||
public void stub28() {}
|
||||
|
||||
public void stub280() {}
|
||||
|
||||
public void stub281() {}
|
||||
|
||||
public void stub282() {}
|
||||
|
||||
public void stub283() {}
|
||||
|
||||
public void stub284() {}
|
||||
|
||||
public void stub285() {}
|
||||
|
||||
public void stub286() {}
|
||||
|
||||
public void stub287() {}
|
||||
|
||||
public void stub288() {}
|
||||
|
||||
public void stub289() {}
|
||||
|
||||
public void stub29() {}
|
||||
|
||||
public void stub290() {}
|
||||
|
||||
public void stub291() {}
|
||||
|
||||
public void stub292() {}
|
||||
|
||||
public void stub293() {}
|
||||
|
||||
public void stub294() {}
|
||||
|
||||
public void stub295() {}
|
||||
|
||||
public void stub296() {}
|
||||
|
||||
public void stub297() {}
|
||||
|
||||
public void stub298() {}
|
||||
|
||||
public void stub299() {}
|
||||
|
||||
public void stub3() {}
|
||||
|
||||
public void stub30() {}
|
||||
|
||||
public void stub300() {}
|
||||
|
||||
public void stub31() {}
|
||||
|
||||
public void stub32() {}
|
||||
|
||||
public void stub33() {}
|
||||
|
||||
public void stub34() {}
|
||||
|
||||
public void stub35() {}
|
||||
|
||||
public void stub36() {}
|
||||
|
||||
public void stub37() {}
|
||||
|
||||
public void stub38() {}
|
||||
|
||||
public void stub39() {}
|
||||
|
||||
public void stub4() {}
|
||||
|
||||
public void stub40() {}
|
||||
|
||||
public void stub41() {}
|
||||
|
||||
public void stub42() {}
|
||||
|
||||
public void stub43() {}
|
||||
|
||||
public void stub44() {}
|
||||
|
||||
public void stub45() {}
|
||||
|
||||
public void stub46() {}
|
||||
|
||||
public void stub47() {}
|
||||
|
||||
public void stub48() {}
|
||||
|
||||
public void stub49() {}
|
||||
|
||||
public void stub5() {}
|
||||
|
||||
public void stub50() {}
|
||||
|
||||
public void stub51() {}
|
||||
|
||||
public void stub52() {}
|
||||
|
||||
public void stub53() {}
|
||||
|
||||
public void stub54() {}
|
||||
|
||||
public void stub55() {}
|
||||
|
||||
public void stub56() {}
|
||||
|
||||
public void stub57() {}
|
||||
|
||||
public void stub58() {}
|
||||
|
||||
public void stub59() {}
|
||||
|
||||
public void stub6() {}
|
||||
|
||||
public void stub60() {}
|
||||
|
||||
public void stub61() {}
|
||||
|
||||
public void stub62() {}
|
||||
|
||||
public void stub63() {}
|
||||
|
||||
public void stub64() {}
|
||||
|
||||
public void stub65() {}
|
||||
|
||||
public void stub66() {}
|
||||
|
||||
public void stub67() {}
|
||||
|
||||
public void stub68() {}
|
||||
|
||||
public void stub69() {}
|
||||
|
||||
public void stub7() {}
|
||||
|
||||
public void stub70() {}
|
||||
|
||||
public void stub71() {}
|
||||
|
||||
public void stub72() {}
|
||||
|
||||
public void stub73() {}
|
||||
|
||||
public void stub74() {}
|
||||
|
||||
public void stub75() {}
|
||||
|
||||
public void stub76() {}
|
||||
|
||||
public void stub77() {}
|
||||
|
||||
public void stub78() {}
|
||||
|
||||
public void stub79() {}
|
||||
|
||||
public void stub8() {}
|
||||
|
||||
public void stub80() {}
|
||||
|
||||
public void stub81() {}
|
||||
|
||||
public void stub82() {}
|
||||
|
||||
public void stub83() {}
|
||||
|
||||
public void stub84() {}
|
||||
|
||||
public void stub85() {}
|
||||
|
||||
public void stub86() {}
|
||||
|
||||
public void stub87() {}
|
||||
|
||||
public void stub88() {}
|
||||
|
||||
public void stub89() {}
|
||||
|
||||
public void stub9() {}
|
||||
|
||||
public void stub90() {}
|
||||
|
||||
public void stub91() {}
|
||||
|
||||
public void stub92() {}
|
||||
|
||||
public void stub93() {}
|
||||
|
||||
public void stub94() {}
|
||||
|
||||
public void stub95() {}
|
||||
|
||||
public void stub96() {}
|
||||
|
||||
public void stub97() {}
|
||||
|
||||
public void stub98() {}
|
||||
|
||||
public void stub99() {}
|
||||
}
|
||||
|
||||
|
||||
/* Location: C:\User\\user\Desktop\classes-dex2jar.jar!\com\swift\sandhook\wrapper\StubMethodsFactory.class
|
||||
* Java compiler version: 6 (50.0)
|
||||
* JD-Core Version: 1.1.1
|
||||
*/
|
||||
Reference in New Issue
Block a user