柬埔寨通 v6.1.5版本的 MD5 值为:9b68581ac30883219d6a25858a099d6b

以下内容为反编译后的 a.java 源代码,内容仅作参考


package com.mobile.auth.p;

import android.content.Context;
import android.text.TextUtils;
import com.mobile.auth.a.c;
import com.mobile.auth.gatewayauth.ExceptionProcessor;
import com.mobile.auth.gatewayauth.manager.RequestCallback;
import com.mobile.auth.gatewayauth.manager.a;
import com.mobile.auth.gatewayauth.manager.base.b;
import com.mobile.auth.gatewayauth.manager.d;
import com.mobile.auth.gatewayauth.model.MonitorStruct;
import com.mobile.auth.gatewayauth.model.ctcctoken.CTCCTokenRet;
import com.mobile.auth.gatewayauth.model.ctcctoken.Data;
import com.nirvana.tools.core.ExecutorManager;

public class a extends com.mobile.auth.gatewayauth.manager.a {
    private c i;

    public a(Context context, d dVar) {
        super(context, dVar, "ct_sjl", null);
        this.i = new c() {
            @Override
            public void a(String str, String str2) {
                try {
                    a.a(a.this).a(str, str2);
                } catch (Throwable th) {
                    try {
                        ExceptionProcessor.processException(th);
                    } catch (Throwable th2) {
                        ExceptionProcessor.processException(th2);
                    }
                }
            }

            @Override
            public void a(String str, String str2, Throwable th) {
                try {
                    if (th != null) {
                        a.b(a.this).c(str, str2, ExecutorManager.getErrorInfoFromException(th));
                    } else {
                        a.c(a.this).c(str, str2);
                    }
                } catch (Throwable th2) {
                    try {
                        ExceptionProcessor.processException(th2);
                    } catch (Throwable th3) {
                        ExceptionProcessor.processException(th3);
                    }
                }
            }
        };
    }

    static com.mobile.auth.m.a a(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    private synchronized void a(final RequestCallback<a.C0116a, b> requestCallback, final MonitorStruct monitorStruct, final String str) {
        try {
            com.mobile.auth.a.a.a((int) this.c, (int) this.c, (int) this.c, this.i);
            com.mobile.auth.a.a.a(this.d, this.a, this.b, new com.mobile.auth.a.b() {
                @Override
                public void a(String str2) {
                    try {
                        monitorStruct.setCarrierReturnTime(System.currentTimeMillis());
                        a.d(a.this).a("ctcc:", "getLoginInfo:", str2);
                        if (TextUtils.isEmpty(str2)) {
                            a.a(a.this, requestCallback, "-10008", "CTCC 获得的手机授权码结果为空", "", "ct_sjl", monitorStruct, str);
                            return;
                        }
                        try {
                            CTCCTokenRet fromJson = CTCCTokenRet.fromJson(str2);
                            if (fromJson != null) {
                                monitorStruct.setCarrierTraceId(fromJson.getReqId());
                                if (fromJson.getResult() != 0 || fromJson.getData() == null) {
                                    a.d(a.this, requestCallback, String.valueOf(fromJson.getResult()), fromJson.getMsg(), str2, "ct_sjl", monitorStruct, str);
                                    return;
                                }
                                Data data = fromJson.getData();
                                String number = data.getNumber();
                                String accessCode = data.getAccessCode();
                                if (TextUtils.isEmpty(number)) {
                                    a.c(a.this, requestCallback, String.valueOf(fromJson.getResult()), fromJson.getMsg(), str2, "ct_sjl", monitorStruct, str);
                                    return;
                                }
                                requestCallback.onSuccess(a.C0116a.a().a(number).c("天翼账号认证服务条款").d("https://e.189.cn/sdk/agreement/detail.do?isWap=true&hidetop=true&appKey=8138111118").b(accessCode).a(System.currentTimeMillis() + (data.getExpiredTime() * 1000)).a());
                                monitorStruct.setPhoneNumber(number);
                                monitorStruct.setAccessCode(accessCode);
                                a.a(a.this, String.valueOf(fromJson.getResult()), "", "", true, "ct_sjl", monitorStruct);
                            }
                        } catch (Exception e) {
                            a.e(a.this).e("CTCCValidManager init exception:", ExecutorManager.getErrorInfoFromException(e));
                            a.b(a.this, requestCallback, "-10008", "JSON转换失败", str2, "ct_sjl", monitorStruct, str);
                        }
                    } catch (Throwable th) {
                        try {
                            ExceptionProcessor.processException(th);
                        } catch (Throwable th2) {
                            ExceptionProcessor.processException(th2);
                        }
                    }
                }
            });
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static void a(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static void a(a aVar, String str, String str2, String str3, boolean z, String str4, MonitorStruct monitorStruct) {
        try {
            aVar.a(str, str2, str3, z, str4, monitorStruct);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static com.mobile.auth.m.a b(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    static void b(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static void b(a aVar, String str, String str2, String str3, boolean z, String str4, MonitorStruct monitorStruct) {
        try {
            aVar.a(str, str2, str3, z, str4, monitorStruct);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static com.mobile.auth.m.a c(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    static void c(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static com.mobile.auth.m.a d(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    static void d(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static com.mobile.auth.m.a e(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    static void e(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static com.mobile.auth.m.a f(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    static void f(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static com.mobile.auth.m.a g(a aVar) {
        try {
            return aVar.h;
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    static void g(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    static void h(a aVar, RequestCallback requestCallback, String str, String str2, String str3, String str4, MonitorStruct monitorStruct, String str5) {
        try {
            aVar.a((RequestCallback<a.C0116a, b>) requestCallback, str, str2, str3, str4, monitorStruct, str5);
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    @Override
    public void a(boolean z) {
    }

    @Override
    public String b(String str, String str2) {
        try {
            if (TextUtils.isEmpty(str)) {
                return str;
            }
            try {
                Integer valueOf = Integer.valueOf(Integer.parseInt(str));
                if (valueOf.intValue() >= 10000) {
                    if (valueOf.intValue() <= 40000) {
                        return str2;
                    }
                }
            } catch (Exception unused) {
            }
            char c = 65535;
            switch (str.hashCode()) {
                case -1389750326:
                    if (str.equals("-720002")) {
                        c = 5;
                        break;
                    }
                    break;
                case 43274408:
                    if (str.equals("-8003")) {
                        c = 4;
                        break;
                    }
                    break;
                case 43274409:
                    if (str.equals("-8004")) {
                        c = '\t';
                        break;
                    }
                    break;
                case 43275366:
                    if (str.equals("-8100")) {
                        c = 6;
                        break;
                    }
                    break;
                case 53194808:
                    if (str.equals("80000")) {
                        c = 1;
                        break;
                    }
                    break;
                case 53194811:
                    if (str.equals("80003")) {
                        c = 7;
                        break;
                    }
                    break;
                case 53194812:
                    if (str.equals("80004")) {
                        c = '\b';
                        break;
                    }
                    break;
                case 53194813:
                    if (str.equals("80005")) {
                        c = 2;
                        break;
                    }
                    break;
                case 53202496:
                    if (str.equals("80800")) {
                        c = 3;
                        break;
                    }
                    break;
                case 1335041958:
                    if (str.equals("-10002")) {
                        c = 0;
                        break;
                    }
                    break;
            }
            switch (c) {
                case 0:
                    return "600025";
                case 1:
                case 2:
                case 3:
                case 4:
                case 5:
                    return "600015";
                case 6:
                case 7:
                case '\b':
                case '\t':
                    return "-10006";
                default:
                    return str2;
            }
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
                return null;
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
                return null;
            }
        }
    }

    @Override
    public void c() {
    }

    @Override
    public synchronized void d(RequestCallback<a.C0116a, b> requestCallback, a.b bVar) {
        try {
            MonitorStruct monitorStruct = new MonitorStruct();
            monitorStruct.putApiParam("timeout", String.valueOf(this.c));
            monitorStruct.setSessionId(bVar.c());
            monitorStruct.setRequestId(bVar.b());
            monitorStruct.setStartTime(System.currentTimeMillis());
            monitorStruct.setAction("ctcc.get.logincode");
            monitorStruct.setNetworkType(com.mobile.auth.gatewayauth.utils.b.a(this.d, true));
            a(requestCallback, monitorStruct, "600012");
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    @Override
    public synchronized void e(RequestCallback<a.C0116a, b> requestCallback, a.b bVar) {
        try {
            MonitorStruct monitorStruct = new MonitorStruct();
            monitorStruct.putApiParam("timeout", String.valueOf(this.c));
            monitorStruct.setSessionId(bVar.c());
            monitorStruct.setRequestId(bVar.b());
            monitorStruct.setStartTime(System.currentTimeMillis());
            monitorStruct.setAction("ctcc.get.logintoken");
            monitorStruct.setNetworkType(com.mobile.auth.gatewayauth.utils.b.a(this.d, true));
            a(requestCallback, monitorStruct, "600011");
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }

    @Override
    public synchronized void f(final RequestCallback<a.C0116a, b> requestCallback, a.b bVar) {
        try {
            final MonitorStruct monitorStruct = new MonitorStruct();
            monitorStruct.putApiParam("timeout", String.valueOf(this.c));
            monitorStruct.setSessionId(bVar.c());
            monitorStruct.setRequestId(bVar.b());
            monitorStruct.setStartTime(System.currentTimeMillis());
            monitorStruct.setAction("ctcc.getoken");
            monitorStruct.setNetworkType(com.mobile.auth.gatewayauth.utils.b.a(this.d, true));
            com.mobile.auth.a.a.a((int) this.c, (int) this.c, (int) this.c, this.i);
            com.mobile.auth.a.a.a(this.d, this.a, this.b, new com.mobile.auth.a.b() {
                @Override
                public void a(String str) {
                    try {
                        monitorStruct.setCarrierReturnTime(System.currentTimeMillis());
                        a.f(a.this).a("ctcc:", "getVerifyInfo:", str);
                        if (TextUtils.isEmpty(str)) {
                            a.e(a.this, requestCallback, "-10008", "CTCC 获得认证Token结果为空", "", "ct_sjl", monitorStruct, "600011");
                            return;
                        }
                        try {
                            CTCCTokenRet fromJson = CTCCTokenRet.fromJson(str);
                            if (fromJson != null) {
                                monitorStruct.setCarrierTraceId(fromJson.getReqId());
                                if (fromJson.getResult() != 0 || fromJson.getData() == null) {
                                    a.h(a.this, requestCallback, String.valueOf(fromJson.getResult()), fromJson.getMsg(), str, "ct_sjl", monitorStruct, "600011");
                                    return;
                                }
                                String accessCode = fromJson.getData().getAccessCode();
                                if (TextUtils.isEmpty(accessCode)) {
                                    a.g(a.this, requestCallback, String.valueOf(fromJson.getResult()), fromJson.getMsg(), str, "ct_sjl", monitorStruct, "600011");
                                    return;
                                }
                                monitorStruct.setAccessCode(accessCode);
                                a.b(a.this, String.valueOf(fromJson.getResult()), fromJson.getMsg(), "", true, "ct_sjl", monitorStruct);
                                requestCallback.onSuccess(a.C0116a.a().b(accessCode).a(System.currentTimeMillis() + (r1.getExpiredTime() * 1000)).a());
                            }
                        } catch (Exception e) {
                            a.g(a.this).e("CTCCValidManager init exception:", ExecutorManager.getErrorInfoFromException(e));
                            a.f(a.this, requestCallback, "-10008", "JSON转换失败", str, "ct_sjl", monitorStruct, "600011");
                        }
                    } catch (Throwable th) {
                        try {
                            ExceptionProcessor.processException(th);
                        } catch (Throwable th2) {
                            ExceptionProcessor.processException(th2);
                        }
                    }
                }
            });
        } catch (Throwable th) {
            try {
                ExceptionProcessor.processException(th);
            } catch (Throwable th2) {
                ExceptionProcessor.processException(th2);
            }
        }
    }
}