酷狗概念版 v2.5.5版本的 MD5 值为:782d327088fca4e58310f35a56f41319

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


package com.kugou.framework.statistics.c;

import com.huawei.hms.framework.common.ContainerUtils;
import com.kugou.common.app.KGCommonApplication;
import com.kugou.common.config.ConfigKey;
import com.kugou.common.statistics.cscc.entity.CsccEntity;
import com.kugou.common.utils.as;
import com.kugou.common.utils.au;
import com.kugou.common.utils.bq;
import com.kugou.common.utils.br;
import com.kugou.common.utils.bz;
import com.kugou.framework.service.util.PlaybackServiceUtil;
import com.tencent.connect.common.Constants;
import com.tencent.stat.DeviceInfo;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.util.Hashtable;
import org.apache.http.HttpEntity;
import org.json.JSONException;
import org.json.JSONObject;

public class f {
    public void a(int i, String str) {
        com.kugou.common.statistics.c.d dVar = new com.kugou.common.statistics.c.d(12, i);
        dVar.a(str);
        if (as.f54365e) {
            as.c("大头像异常上报 content:" + str + "  eid:" + i);
        }
        com.kugou.common.statistics.h.a(new d(KGCommonApplication.getContext(), dVar));
    }

    public String a(final com.kugou.framework.lyric.k kVar) {
        final JSONObject jSONObject = new JSONObject();
        try {
            jSONObject.put("num", kVar.f58271b);
            jSONObject.put("line", kVar.f58272c);
            jSONObject.put("lyricSize", kVar.h);
            jSONObject.put("lyricName", kVar.f);
            jSONObject.put("lyricHash", kVar.g);
            jSONObject.put("hash", PlaybackServiceUtil.getCurrentHashvalue());
            jSONObject.put("songName", PlaybackServiceUtil.getDisplayName());
            jSONObject.put("duration", PlaybackServiceUtil.getDuration());
        } catch (Exception unused) {
        }
        if (com.kugou.common.config.c.a().c(com.kugou.android.app.a.a.al)) {
            au.a().a(new Runnable() {
                @Override
                public void run() {
                    f.this.a(kVar, jSONObject);
                }
            });
        }
        return jSONObject.toString();
    }

    public void a(com.kugou.framework.lyric.k kVar, JSONObject jSONObject) {
        byte[] bArr;
        HttpEntity postRequestEntity;
        Hashtable hashtable = new Hashtable(2);
        try {
            String a2 = bz.a("http://mobilecdn.kugou.com/new/app/i/krc.php?cmd=200&songName=" + String.valueOf(jSONObject.get("songName")) + ContainerUtils.FIELD_DELIMITER + "lyricHash=" + String.valueOf(kVar.g));
            com.kugou.common.entity.g N = br.N(KGCommonApplication.getContext());
            bq.k(N.f());
            hashtable.put("lyricname", bz.a(kVar.f));
            hashtable.put("lyrichash", kVar.g);
            hashtable.put("songname", bz.a(jSONObject.getString("songName")));
            hashtable.put("songhash", jSONObject.getString("hash"));
            hashtable.put("duration", jSONObject.getString("duration"));
            hashtable.put("url", a2);
            hashtable.put(DeviceInfo.TAG_VERSION, N.c());
            k kVar2 = new k(hashtable, kVar.f);
            ConfigKey a3 = kVar2.a();
            int a4 = com.kugou.common.statistics.cscc.c.a(a3);
            if (a4 == 1 || a4 == 2) {
                if (kVar2.getRequestType().equalsIgnoreCase(Constants.HTTP_POST) && (postRequestEntity = kVar2.getPostRequestEntity()) != null) {
                    ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();
                    try {
                        postRequestEntity.writeTo(byteArrayOutputStream);
                        bArr = byteArrayOutputStream.toByteArray();
                    } catch (IOException e2) {
                        as.e(e2);
                    }
                    com.kugou.common.statistics.h.a(new CsccEntity(a3.f47792a, null, kVar2.getRequestType(), kVar2.getGetRequestParams(), bArr, false, true), false);
                }
                bArr = null;
                com.kugou.common.statistics.h.a(new CsccEntity(a3.f47792a, null, kVar2.getRequestType(), kVar2.getGetRequestParams(), bArr, false, true), false);
            }
            if (a4 == 0 || a4 == 2) {
                com.kugou.common.network.f.d().a(kVar2, (com.kugou.common.network.d.h<Object>) null);
            }
        } catch (JSONException e3) {
            as.e(e3);
        } catch (Exception e4) {
            if (as.f54365e) {
                as.f("lyricfile", "异常歌词上传失败,失败原因:" + e4.getMessage());
            }
        }
    }
}