APK反编译源代码展示 - 南明离火平台提供

应用版本信息
应用名称:Music Player
版本号:1.0
包名称:music.downloader.mp3player.downloadmusic

MD5 校验值:61e58c10a11e4adec8760ee3854e996a

反编译源代码说明

g.java 文件包含反编译后的源代码,请注意,该内容仅供学习和参考使用,不得用于非法用途。


package w5;

import F5.o;
import F5.q;
import F5.s;
import F5.y;
import I2.C0042n;
import a.AbstractC0209a;
import com.google.android.gms.internal.ads.C1690za;
import f0.AbstractC1761a;
import io.reactivex.rxjava3.annotations.SchedulerSupport;
import java.io.IOException;
import java.net.ConnectException;
import java.net.Proxy;
import java.net.Socket;
import java.security.MessageDigest;
import java.security.Principal;
import java.security.PublicKey;
import java.security.cert.X509Certificate;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.concurrent.TimeUnit;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.SSLPeerUnverifiedException;
import javax.net.ssl.SSLSession;
import javax.net.ssl.SSLSocket;
import javax.net.ssl.SSLSocketFactory;
import l3.AbstractC2026e;
import org.apache.http.HttpStatus;
import org.apache.http.protocol.HTTP;
import org.schabi.newpipe.extractor.utils.ManifestCreatorCache;
import s5.C2262a;
import s5.C2263b;
import s5.C2265d;
import s5.C2268g;
import s5.C2271j;
import s5.C2272k;
import s5.C2273l;
import s5.C2274m;
import s5.C2278q;
import s5.C2280s;
import s5.C2281t;
import s5.C2282u;
import s5.C2284w;
import s5.EnumC2279r;
import t5.AbstractC2342a;
import v5.C2375c;
import z5.C2447A;
import z5.p;
import z5.w;
import z5.x;

public final class g extends z5.i {

    public Socket f19301b;

    public Socket f19302c;
    public C2271j d;
    public EnumC2279r e;

    public p f19303f;

    public q f19304g;

    public o f19305h;

    public boolean f19306i;

    public int f19307j;

    public int f19308k;

    public int f19309l;

    public int f19310m;

    public final ArrayList f19311n;

    public long f19312o;

    public final i f19313p;

    public final C2284w f19314q;

    public g(i iVar, C2284w c2284w) {
        F4.f.g(iVar, "connectionPool");
        F4.f.g(c2284w, "route");
        this.f19313p = iVar;
        this.f19314q = c2284w;
        this.f19310m = 1;
        this.f19311n = new ArrayList();
        this.f19312o = Long.MAX_VALUE;
    }

    @Override
    public final void a(p pVar, C2447A c2447a) {
        int i5;
        F4.f.g(pVar, "connection");
        F4.f.g(c2447a, "settings");
        synchronized (this.f19313p) {
            if ((c2447a.f19714a & 16) != 0) {
                i5 = c2447a.f19715b[4];
            } else {
                i5 = ManifestCreatorCache.DEFAULT_MAXIMUM_SIZE;
            }
            this.f19310m = i5;
        }
    }

    @Override
    public final void b(w wVar) {
        F4.f.g(wVar, "stream");
        wVar.c(8, null);
    }

    public final void c(int i5, int i6, C2280s c2280s, C2263b c2263b) {
        Socket socket;
        int i7;
        C2284w c2284w = this.f19314q;
        Proxy proxy = c2284w.f18466b;
        C2262a c2262a = c2284w.f18465a;
        Proxy.Type type = proxy.type();
        if (type == null || ((i7 = e.f19298a[type.ordinal()]) != 1 && i7 != 2)) {
            socket = new Socket(proxy);
        } else {
            socket = c2262a.e.createSocket();
            if (socket == null) {
                F4.f.j();
                throw null;
            }
        }
        this.f19301b = socket;
        F4.f.g(this.f19314q.f18467c, "inetSocketAddress");
        socket.setSoTimeout(i6);
        try {
            A5.k kVar = A5.k.f193a;
            A5.k.f193a.g(socket, this.f19314q.f18467c, i5);
            try {
                this.f19304g = new q(AbstractC0209a.o(socket));
                this.f19305h = new o(AbstractC0209a.m(socket));
            } catch (NullPointerException e) {
                if (!F4.f.a(e.getMessage(), "throw with null exception")) {
                } else {
                    throw new IOException(e);
                }
            }
        } catch (ConnectException e7) {
            ConnectException connectException = new ConnectException("Failed to connect to " + this.f19314q.f18467c);
            connectException.initCause(e7);
            throw connectException;
        }
    }

    public final void d(int i5, int i6, int i7, C2280s c2280s, C2263b c2263b) {
        C0042n c0042n = new C0042n(23);
        C2284w c2284w = this.f19314q;
        C2274m c2274m = c2284w.f18465a.f18309a;
        F4.f.g(c2274m, "url");
        c0042n.e = c2274m;
        c0042n.i("CONNECT", null);
        C2262a c2262a = c2284w.f18465a;
        c0042n.f("Host", AbstractC2342a.u(c2262a.f18309a, true));
        c0042n.f("Proxy-Connection", HTTP.CONN_KEEP_ALIVE);
        c0042n.f("User-Agent", "okhttp/4.3.1");
        R4.b b7 = c0042n.b();
        C2281t c2281t = new C2281t();
        c2281t.f18439a = b7;
        c2281t.f18440b = EnumC2279r.HTTP_1_1;
        c2281t.f18441c = HttpStatus.SC_PROXY_AUTHENTICATION_REQUIRED;
        c2281t.d = "Preemptive Authenticate";
        c2281t.f18443g = AbstractC2342a.f18679c;
        c2281t.f18447k = -1L;
        c2281t.f18448l = -1L;
        C2272k c2272k = c2281t.f18442f;
        c2272k.getClass();
        com.bumptech.glide.e.d("Proxy-Authenticate");
        com.bumptech.glide.e.e("OkHttp-Preemptive", "Proxy-Authenticate");
        c2272k.d("Proxy-Authenticate");
        c2272k.a("Proxy-Authenticate", "OkHttp-Preemptive");
        c2281t.a();
        c2262a.f18315i.getClass();
        c(i5, i6, c2280s, c2263b);
        String str = "CONNECT " + AbstractC2342a.u((C2274m) b7.f2854k, true) + " HTTP/1.1";
        q qVar = this.f19304g;
        if (qVar != null) {
            o oVar = this.f19305h;
            if (oVar != null) {
                i iVar = new i(null, null, qVar, oVar);
                TimeUnit timeUnit = TimeUnit.MILLISECONDS;
                qVar.f659f.c().g(i6, timeUnit);
                oVar.f656f.c().g(i7, timeUnit);
                iVar.o((C2273l) b7.e, str);
                iVar.c();
                C2281t g4 = iVar.g(false);
                if (g4 != null) {
                    g4.f18439a = b7;
                    C2282u a6 = g4.a();
                    long j5 = AbstractC2342a.j(a6);
                    if (j5 != -1) {
                        y5.d j6 = iVar.j(j5);
                        AbstractC2342a.s(j6, ManifestCreatorCache.DEFAULT_MAXIMUM_SIZE, timeUnit);
                        j6.close();
                    }
                    int i8 = a6.f18452j;
                    if (i8 != 200) {
                        if (i8 == 407) {
                            c2262a.f18315i.getClass();
                            throw new IOException("Failed to authenticate with proxy");
                        }
                        throw new IOException(AbstractC1761a.e(i8, "Unexpected response code for CONNECT: "));
                    }
                    if (qVar.f658b.j() && oVar.f655b.j()) {
                        return;
                    } else {
                        throw new IOException("TLS tunnel buffered too many bytes!");
                    }
                }
                F4.f.j();
                throw null;
            }
            F4.f.j();
            throw null;
        }
        F4.f.j();
        throw null;
    }

    public final void e(C1690za c1690za, C2280s c2280s, C2263b c2263b) {
        C2262a c2262a = this.f19314q.f18465a;
        SSLSocketFactory sSLSocketFactory = c2262a.f18312f;
        EnumC2279r enumC2279r = EnumC2279r.HTTP_1_1;
        if (sSLSocketFactory == null) {
            List list = c2262a.f18310b;
            EnumC2279r enumC2279r2 = EnumC2279r.H2_PRIOR_KNOWLEDGE;
            if (list.contains(enumC2279r2)) {
                this.f19302c = this.f19301b;
                this.e = enumC2279r2;
                h();
                return;
            } else {
                this.f19302c = this.f19301b;
                this.e = enumC2279r;
                return;
            }
        }
        SSLSocket sSLSocket = null;
        String str = null;
        try {
            if (sSLSocketFactory != null) {
                Socket socket = this.f19301b;
                C2274m c2274m = c2262a.f18309a;
                Socket createSocket = sSLSocketFactory.createSocket(socket, c2274m.e, c2274m.f18379f, true);
                if (createSocket != null) {
                    SSLSocket sSLSocket2 = (SSLSocket) createSocket;
                    try {
                        C2268g e = c1690za.e(sSLSocket2);
                        if (e.f18355b) {
                            A5.k kVar = A5.k.f193a;
                            A5.k.f193a.e(sSLSocket2, c2262a.f18309a.e, c2262a.f18310b);
                        }
                        sSLSocket2.startHandshake();
                        SSLSession session = sSLSocket2.getSession();
                        C2263b c2263b2 = C2271j.f18368f;
                        F4.f.b(session, "sslSocketSession");
                        c2263b2.getClass();
                        C2271j e7 = C2263b.e(session);
                        HostnameVerifier hostnameVerifier = c2262a.f18313g;
                        if (hostnameVerifier != null) {
                            if (!hostnameVerifier.verify(c2262a.f18309a.e, session)) {
                                List a6 = e7.a();
                                if (!a6.isEmpty()) {
                                    Object obj = a6.get(0);
                                    if (obj == null) {
                                        throw new ClassCastException("null cannot be cast to non-null type java.security.cert.X509Certificate");
                                    }
                                    X509Certificate x509Certificate = (X509Certificate) obj;
                                    StringBuilder sb = new StringBuilder("\n              |Hostname ");
                                    sb.append(c2262a.f18309a.e);
                                    sb.append(" not verified:\n              |    certificate: ");
                                    C2265d c2265d = C2265d.f18332c;
                                    F5.i iVar = F5.i.f639j;
                                    PublicKey publicKey = x509Certificate.getPublicKey();
                                    F4.f.b(publicKey, "publicKey");
                                    byte[] encoded = publicKey.getEncoded();
                                    F4.f.b(encoded, "publicKey.encoded");
                                    byte[] digest = MessageDigest.getInstance("SHA-256").digest(s.c(encoded).f641f);
                                    F4.f.b(digest, "MessageDigest.getInstance(algorithm).digest(data)");
                                    sb.append("sha256/".concat(new F5.i(digest).a()));
                                    sb.append("\n              |    DN: ");
                                    Principal subjectDN = x509Certificate.getSubjectDN();
                                    F4.f.b(subjectDN, "cert.subjectDN");
                                    sb.append(subjectDN.getName());
                                    sb.append("\n              |    subjectAltNames: ");
                                    sb.append(E5.c.a(x509Certificate));
                                    sb.append("\n              ");
                                    throw new SSLPeerUnverifiedException(L4.d.B(sb.toString()));
                                }
                                throw new SSLPeerUnverifiedException("Hostname " + c2262a.f18309a.e + " not verified (no certificates)");
                            }
                            C2265d c2265d2 = c2262a.f18314h;
                            if (c2265d2 != null) {
                                this.d = new C2271j(e7.f18370b, e7.f18371c, e7.d, new f(c2265d2, e7, c2262a));
                                F4.f.g(c2262a.f18309a.e, "hostname");
                                Iterator it = c2265d2.f18333a.iterator();
                                if (!it.hasNext()) {
                                    if (e.f18355b) {
                                        A5.k kVar2 = A5.k.f193a;
                                        str = A5.k.f193a.h(sSLSocket2);
                                    }
                                    this.f19302c = sSLSocket2;
                                    this.f19304g = new q(AbstractC0209a.o(sSLSocket2));
                                    this.f19305h = new o(AbstractC0209a.m(sSLSocket2));
                                    if (str != null) {
                                        enumC2279r = AbstractC2026e.l(str);
                                    }
                                    this.e = enumC2279r;
                                    A5.k kVar3 = A5.k.f193a;
                                    A5.k.f193a.a(sSLSocket2);
                                    if (this.e == EnumC2279r.HTTP_2) {
                                        h();
                                        return;
                                    }
                                    return;
                                }
                                AbstractC1761a.r(it.next());
                                throw null;
                            }
                            F4.f.j();
                            throw null;
                        }
                        F4.f.j();
                        throw null;
                    } catch (Throwable th) {
                        th = th;
                        sSLSocket = sSLSocket2;
                        if (sSLSocket != null) {
                            A5.k kVar4 = A5.k.f193a;
                            A5.k.f193a.a(sSLSocket);
                        }
                        if (sSLSocket != null) {
                            AbstractC2342a.d(sSLSocket);
                        }
                        throw th;
                    }
                }
                throw new ClassCastException("null cannot be cast to non-null type javax.net.ssl.SSLSocket");
            }
            F4.f.j();
            throw null;
        } catch (Throwable th2) {
            th = th2;
        }
    }

    public final x5.d f(C2278q c2278q, x5.f fVar) {
        Socket socket = this.f19302c;
        if (socket != null) {
            q qVar = this.f19304g;
            if (qVar != null) {
                o oVar = this.f19305h;
                if (oVar != null) {
                    p pVar = this.f19303f;
                    if (pVar != null) {
                        return new z5.q(c2278q, this, fVar, pVar);
                    }
                    int i5 = fVar.f19507i;
                    socket.setSoTimeout(i5);
                    y c7 = qVar.f659f.c();
                    long j5 = i5;
                    TimeUnit timeUnit = TimeUnit.MILLISECONDS;
                    c7.g(j5, timeUnit);
                    oVar.f656f.c().g(fVar.f19508j, timeUnit);
                    return new i(c2278q, this, qVar, oVar);
                }
                F4.f.j();
                throw null;
            }
            F4.f.j();
            throw null;
        }
        F4.f.j();
        throw null;
    }

    public final void g() {
        i iVar = this.f19313p;
        byte[] bArr = AbstractC2342a.f18677a;
        synchronized (iVar) {
            this.f19306i = true;
        }
    }

    public final void h() {
        int i5;
        int i6;
        Socket socket = this.f19302c;
        if (socket != null) {
            q qVar = this.f19304g;
            if (qVar != null) {
                o oVar = this.f19305h;
                if (oVar != null) {
                    socket.setSoTimeout(0);
                    C2375c c2375c = C2375c.f18998h;
                    F4.f.g(c2375c, "taskRunner");
                    ?? obj = new Object();
                    obj.f8871g = c2375c;
                    obj.f8870f = z5.i.f19742a;
                    String str = this.f19314q.f18465a.f18309a.e;
                    F4.f.g(str, "peerName");
                    obj.f8869c = socket;
                    obj.f8868b = "OkHttp ".concat(str);
                    obj.d = qVar;
                    obj.e = oVar;
                    obj.f8870f = this;
                    obj.f8867a = 0;
                    p pVar = new p(obj);
                    this.f19303f = pVar;
                    C2447A c2447a = p.f19758H;
                    if ((c2447a.f19714a & 16) != 0) {
                        i5 = c2447a.f19715b[4];
                    } else {
                        i5 = ManifestCreatorCache.DEFAULT_MAXIMUM_SIZE;
                    }
                    this.f19310m = i5;
                    x xVar = pVar.f19763E;
                    synchronized (xVar) {
                        try {
                            if (!xVar.f19821f) {
                                if (xVar.f19824l) {
                                    Logger logger = x.f19819m;
                                    if (logger.isLoggable(Level.FINE)) {
                                        logger.fine(AbstractC2342a.h(">> CONNECTION " + z5.f.f19738a.c(), new Object[0]));
                                    }
                                    xVar.f19823k.k(z5.f.f19738a);
                                    xVar.f19823k.flush();
                                }
                            } else {
                                throw new IOException("closed");
                            }
                        } catch (Throwable th) {
                            throw th;
                        }
                    }
                    x xVar2 = pVar.f19763E;
                    C2447A c2447a2 = pVar.f19781x;
                    synchronized (xVar2) {
                        try {
                            F4.f.g(c2447a2, "settings");
                            if (!xVar2.f19821f) {
                                xVar2.h(0, Integer.bitCount(c2447a2.f19714a) * 6, 4, 0);
                                for (int i7 = 0; i7 < 10; i7++) {
                                    if (((1 << i7) & c2447a2.f19714a) != 0) {
                                        if (i7 != 4) {
                                            if (i7 != 7) {
                                                i6 = i7;
                                            } else {
                                                i6 = 4;
                                            }
                                        } else {
                                            i6 = 3;
                                        }
                                        xVar2.f19823k.writeShort(i6);
                                        xVar2.f19823k.writeInt(c2447a2.f19715b[i7]);
                                    }
                                }
                                xVar2.f19823k.flush();
                            } else {
                                throw new IOException("closed");
                            }
                        } catch (Throwable th2) {
                            throw th2;
                        }
                    }
                    if (pVar.f19781x.a() != 65535) {
                        pVar.f19763E.w(r2 - 65535, 0);
                    }
                    new Thread(pVar.f19764F, pVar.f19767j).start();
                    return;
                }
                F4.f.j();
                throw null;
            }
            F4.f.j();
            throw null;
        }
        F4.f.j();
        throw null;
    }

    public final boolean i(C2274m c2274m) {
        F4.f.g(c2274m, "url");
        C2274m c2274m2 = this.f19314q.f18465a.f18309a;
        if (c2274m.f18379f != c2274m2.f18379f) {
            return false;
        }
        String str = c2274m2.e;
        String str2 = c2274m.e;
        if (F4.f.a(str2, str)) {
            return true;
        }
        C2271j c2271j = this.d;
        if (c2271j == null) {
            return false;
        }
        Object obj = c2271j.a().get(0);
        if (obj != null) {
            if (!E5.c.c(str2, (X509Certificate) obj)) {
                return false;
            }
            return true;
        }
        throw new ClassCastException("null cannot be cast to non-null type java.security.cert.X509Certificate");
    }

    public final String toString() {
        Object obj;
        StringBuilder sb = new StringBuilder("Connection{");
        C2284w c2284w = this.f19314q;
        sb.append(c2284w.f18465a.f18309a.e);
        sb.append(':');
        sb.append(c2284w.f18465a.f18309a.f18379f);
        sb.append(", proxy=");
        sb.append(c2284w.f18466b);
        sb.append(" hostAddress=");
        sb.append(c2284w.f18467c);
        sb.append(" cipherSuite=");
        C2271j c2271j = this.d;
        if (c2271j == null || (obj = c2271j.f18371c) == null) {
            obj = SchedulerSupport.NONE;
        }
        sb.append(obj);
        sb.append(" protocol=");
        sb.append(this.e);
        sb.append('}');
        return sb.toString();
    }
}