AI Chat v1.1.8版本的 MD5 值为:1bcdce875f86738c8cfbf1e5f4064353

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


package com.mbridge.msdk.foundation.same.net.f;

import android.text.TextUtils;
import com.mbridge.msdk.foundation.download.core.DownloadCommon;
import com.mbridge.msdk.foundation.tools.r;
import com.mbridge.msdk.foundation.tools.x;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.regex.Pattern;
public final class d {
    public String A;
    public String B;
    public String C;
    public int D;
    public int E;
    public boolean F;
    public ArrayList<String> G;
    public ArrayList<String> H;
    private final String I;
    private boolean J;
    private int K;
    private String L;
    private String M;
    private String N;
    private String O;
    private String P;
    private String Q;
    private String R;
    private String S;
    private String T;
    private String U;
    private String V;
    private String W;
    public String a;
    public String b;
    public String c;
    public String f1583d;
    public String e;
    public String f;
    public int g;
    public int h;
    public boolean i;
    public int j;
    public String k;
    public String l;
    public String m;
    public String n;
    public String o;
    public String p;
    public String q;
    public String r;
    public String s;
    public String t;
    public String u;
    public String v;
    public String w;
    public String x;
    public String y;
    public String z;

    public static class a {
        private static final d a = new d();
    }

    public static d a() {
        return a.a;
    }

    public final int b() {
        return this.K;
    }

    public final void c() {
        HashMap<String, String> aA;
        com.mbridge.msdk.c.a b = com.mbridge.msdk.c.b.a().b(com.mbridge.msdk.foundation.controller.a.d().g());
        if (b != null) {
            this.i = b.aG() == 2;
            this.j = b.aG();
            this.J = !b.i(2);
            if (b.aA() != null && b.aA().size() > 0 && (aA = b.aA()) != null && aA.size() > 0) {
                if (aA.containsKey("v") && !TextUtils.isEmpty(aA.get("v")) && a(aA.get("v"))) {
                    this.b = aA.get("v");
                    this.m = this.b + this.O;
                    this.n = this.b + this.P;
                    this.o = this.b + this.Q;
                    this.p = this.b + this.R;
                }
                if (aA.containsKey("hb") && !TextUtils.isEmpty(aA.get("hb")) && a(aA.get("hb"))) {
                    this.L = aA.get("hb");
                    this.k = this.L + this.M;
                    this.l = this.L + this.N;
                }
                if (aA.containsKey("lg") && !TextUtils.isEmpty(aA.get("lg"))) {
                    String str = aA.get("lg");
                    if (a(str)) {
                        this.a = str;
                    } else {
                        this.f = str;
                    }
                }
                if (aA.containsKey(DownloadCommon.DOWNLOAD_REPORT_DOWNLOAD_RATE) && !TextUtils.isEmpty(aA.get(DownloadCommon.DOWNLOAD_REPORT_DOWNLOAD_RATE)) && a(aA.get(DownloadCommon.DOWNLOAD_REPORT_DOWNLOAD_RATE))) {
                    this.B = aA.get(DownloadCommon.DOWNLOAD_REPORT_DOWNLOAD_RATE);
                }
                if (aA.containsKey("df") && !TextUtils.isEmpty(aA.get("df")) && a(aA.get("df"))) {
                    this.A = aA.get("df");
                }
            }
            String z = b.z();
            if (!TextUtils.isEmpty(z)) {
                this.c = z;
                e();
                this.G.add(0, z);
            }
            String A = b.A();
            if (TextUtils.isEmpty(A)) {
                return;
            }
            this.f1583d = A;
            f();
            this.H.add(0, A);
        }
    }

    public final boolean d() {
        try {
            if (!this.i) {
                ArrayList<String> arrayList = this.G;
                if (arrayList != null && this.D <= arrayList.size() - 1) {
                    this.c = this.G.get(this.D);
                    e();
                    return true;
                }
            } else {
                ArrayList<String> arrayList2 = this.H;
                if (arrayList2 != null && this.E <= arrayList2.size() - 1) {
                    if (!a(this.H.get(this.E))) {
                        this.f1583d = this.H.get(this.E);
                        f();
                    }
                    return true;
                }
            }
            if (this.F) {
                this.D = 0;
                this.E = 0;
            }
            return false;
        } catch (Throwable th) {
            x.a("RequestUrlUtil", th.getMessage());
            return false;
        }
    }

    public final void e() {
        this.q = this.c + this.T;
        this.r = this.c + this.U;
        this.s = this.c + this.V;
        this.t = this.c + this.S;
        this.u = this.c + this.W;
    }

    public final void f() {
        this.v = this.f1583d + this.T;
        this.w = this.f1583d + this.U;
        this.x = this.f1583d + this.V;
        this.y = this.f1583d + this.S;
        this.z = this.f1583d + this.W;
    }

    private d() {
        this.I = "RequestUrlUtil";
        this.J = true;
        this.K = 0;
        this.L = "https://{}hb.rayjump.com";
        this.a = "https://analytics.rayjump.com";
        this.b = "https://net.rayjump.com";
        this.c = "https://configure.rayjump.com";
        this.f1583d = "configure-tcp.rayjump.com";
        this.e = "https://cn-magnet.rayjump.com/mini/scheme";
        this.f = r.b("DkPtYdQTLkfAW+xUhoPwLkPTHkJBDkM/Yr5T");
        this.g = 9377;
        this.h = 9377;
        this.i = false;
        this.j = 1;
        this.M = "/bid";
        this.N = "/load";
        this.O = "/openapi/ad/v3";
        this.P = "/openapi/ad/v4";
        this.Q = "/openapi/ad/v5";
        this.R = "/image";
        this.S = "/mapping";
        this.T = "/setting";
        this.U = "/sdk/customid";
        this.V = "/rewardsetting";
        this.W = "/appwall/setting";
        this.k = this.L + this.M;
        this.l = this.L + this.N;
        this.m = this.b + this.O;
        this.n = this.b + this.P;
        this.o = this.b + this.Q;
        this.p = this.b + this.R;
        this.q = this.c + this.T;
        this.r = this.c + this.U;
        this.s = this.c + this.V;
        this.t = this.c + this.S;
        this.u = this.c + this.W;
        this.v = this.f1583d + this.T;
        this.w = this.f1583d + this.U;
        this.x = this.f1583d + this.V;
        this.y = this.f1583d + this.S;
        this.z = this.f1583d + this.W;
        this.A = "https://detect.rayjump.com/mapi/find";
        this.B = "https://detect.rayjump.com/mapi/result";
        this.C = "https://d1tru86qrby720.cloudfront.net/hostsetting";
        this.D = 0;
        this.E = 0;
        this.F = false;
        this.G = new ArrayList<>(Arrays.asList("https://configure.rayjump.com", "https://policy.rayjump.com", "https://lazy.rayjump.com", "https://check.rayjump.com"));
        this.H = new ArrayList<>(Arrays.asList("configure-tcp.rayjump.com", "policy-tcp.rayjump.com", "lazy-tcp.rayjump.com", "check-tcp.rayjump.com"));
    }

    public final void a(int i) {
        this.K = i;
    }

    public final String a(String str, int i) {
        try {
            if (!TextUtils.isEmpty(str)) {
                String[] split = str.split("_");
                if (split.length > 1) {
                    return a(true, split[1]);
                }
                return a(true, "");
            }
        } catch (Exception e) {
            x.d("RequestUrlUtil", e.getMessage());
        }
        return i % 2 == 0 ? this.o : this.m;
    }

    public final String a(boolean z, String str) {
        if (z) {
            if (this.l.contains("{}") && !TextUtils.isEmpty(str)) {
                String str2 = this.l;
                return str2.replace("{}", str + "-");
            }
            return this.l.replace("{}", "");
        }
        return this.k.replace("{}", "");
    }

    private boolean a(String str) {
        if (TextUtils.isEmpty(str)) {
            return false;
        }
        return Pattern.compile("(https|http)://[-A-Za-z0-9{}+&@#/%?=~_|!:,.;]+[-A-Za-z0-9+&@#/%=~_|]").matcher(str.trim()).matches();
    }
}