正在查看: 品质商城 v1.0 应用的 a.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: 品质商城 v1.0 应用的 a.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package G0;
import K0.b;
import M0.j;
import android.content.Context;
import android.os.Process;
import android.text.TextUtils;
import android.util.Base64;
import g.C0179a;
import i.C0237A;
import java.nio.charset.Charset;
import java.security.SecureRandom;
import java.util.HashMap;
import java.util.Objects;
import k0.AbstractC0309b;
import m0.AbstractC0318b;
import org.json.JSONObject;
import q0.AbstractC0346a;
import s0.C0355a;
import w0.AbstractC0417b;
import w0.c;
import w0.d;
import w0.e;
import w0.f;
public final class a extends j {
public final int f274b;
public a(int i2) {
this.f274b = i2;
}
@Override
public final String f(b bVar, HashMap hashMap, HashMap hashMap2) {
String str;
int i2;
switch (this.f274b) {
case 1:
HashMap hashMap3 = new HashMap();
try {
C0355a d2 = c.d();
JSONObject jSONObject = new JSONObject();
Context context = bVar != null ? bVar.f344c : null;
if (context == null) {
context = C0179a.c().f3332a.getApplicationContext();
}
String c2 = AbstractC0318b.c(context, bVar);
String g2 = AbstractC0417b.g(context, bVar);
String str2 = "";
if (d2 != null) {
byte[] bArr = (byte[]) d2.f136a;
SecureRandom secureRandom = AbstractC0346a.f4741a;
str = Base64.encodeToString(bArr, 3);
} else {
str = "";
}
jSONObject.put("ap_q", str);
jSONObject.put("ap_link_token", bVar != null ? bVar.f345d : "");
try {
i2 = Process.myUid();
} catch (Throwable th) {
e.d(th);
i2 = -200;
}
jSONObject.put("u_pd", String.valueOf(i2));
jSONObject.put("u_lk", String.valueOf(AbstractC0318b.p(AbstractC0318b.m())));
jSONObject.put("u_pi", String.valueOf(bVar != null ? bVar.f348g : "_"));
jSONObject.put("u_fu", c2);
jSONObject.put("u_oi", g2);
hashMap3.put("ap_req", jSONObject.toString());
StringBuilder sb = new StringBuilder();
if (d2 != null) {
byte[] bArr2 = (byte[]) d2.f136a;
SecureRandom secureRandom2 = AbstractC0346a.f4741a;
str2 = Base64.encodeToString(bArr2, 3);
}
sb.append(str2);
sb.append("|");
sb.append(c2);
f.e(bVar, "biz", "ap_q", sb.toString());
} catch (Exception e2) {
f.f(bVar, "biz", "APMEx1", e2);
}
hashMap2.putAll(hashMap3);
hashMap2.toString();
break;
}
return super.f(bVar, hashMap, hashMap2);
}
@Override
public final HashMap i(boolean z2, String str) {
switch (this.f274b) {
case 2:
HashMap hashMap = new HashMap();
hashMap.put("msp-gzip", String.valueOf(z2));
hashMap.put("content-type", "application/octet-stream");
hashMap.put("des-mode", "CBC");
return hashMap;
case 3:
return new HashMap();
default:
HashMap hashMap2 = new HashMap();
hashMap2.put("msp-gzip", String.valueOf(z2));
hashMap2.put("Operation-Type", "alipay.msp.cashier.dispatch.bytes");
hashMap2.put("content-type", "application/octet-stream");
hashMap2.put("Version", "2.0");
hashMap2.put("AppId", "TAOBAO");
String str2 = "";
if (!TextUtils.isEmpty(str)) {
String[] split = str.split("&");
if (split.length != 0) {
String str3 = null;
String str4 = null;
String str5 = null;
String str6 = null;
for (String str7 : split) {
if (TextUtils.isEmpty(str3)) {
str3 = !str7.contains("biz_type") ? null : AbstractC0309b.g(str7);
}
if (TextUtils.isEmpty(str4)) {
str4 = !str7.contains("biz_no") ? null : AbstractC0309b.g(str7);
}
if (TextUtils.isEmpty(str5)) {
str5 = (!str7.contains("trade_no") || str7.startsWith("out_trade_no")) ? null : AbstractC0309b.g(str7);
}
if (TextUtils.isEmpty(str6)) {
str6 = !str7.contains("app_userid") ? null : AbstractC0309b.g(str7);
}
}
StringBuilder sb = new StringBuilder();
if (!TextUtils.isEmpty(str3)) {
sb.append("biz_type=" + str3 + ";");
}
if (!TextUtils.isEmpty(str4)) {
sb.append("biz_no=" + str4 + ";");
}
if (!TextUtils.isEmpty(str5)) {
sb.append("trade_no=" + str5 + ";");
}
if (!TextUtils.isEmpty(str6)) {
sb.append("app_userid=" + str6 + ";");
}
String sb2 = sb.toString();
if (sb2.endsWith(";")) {
sb2 = sb2.substring(0, sb2.length() - 1);
}
str2 = sb2;
}
}
hashMap2.put("Msp-Param", str2);
hashMap2.put("des-mode", "CBC");
return hashMap2;
}
}
public final C0237A o(b bVar, Context context, String str) {
String str2;
switch (this.f274b) {
case 2:
return e(bVar, context, str, "https://mcgw.alipay.com/sdklog.do", true);
case 3:
byte[] g2 = d.g(str.getBytes(Charset.forName("UTF-8")));
HashMap hashMap = new HashMap();
hashMap.put("utdId", C0179a.c().b());
hashMap.put("logHeader", "RAW");
hashMap.put("bizCode", "alipaysdk");
hashMap.put("productId", "alipaysdk_android");
hashMap.put("Content-Encoding", "Gzip");
hashMap.put("productVersion", "15.8.14");
D0.a a2 = D0.b.a(context, new D0.a("https://loggw-exsdk.alipay.com/loggw/logUpload.do", hashMap, g2));
Objects.toString(a2);
if (a2 == null) {
throw new RuntimeException("Response is null");
}
boolean k2 = j.k(a2);
try {
byte[] bArr = a2.f114d;
if (k2) {
bArr = d.m(bArr);
}
return new C0237A("", 10, new String(bArr, Charset.forName("UTF-8")));
} catch (Exception e2) {
e.d(e2);
return null;
}
default:
int i2 = AbstractC0309b.f4058c;
if (i2 == 2) {
str2 = "https://mobilegw.alipaydev.com/mgw.htm";
} else if (i2 == 3) {
str2 = "https://mobilegw.dl.alipaydev.com/mgw.htm";
} else {
str2 = "https://mobilegw.alipay.com/mgw.htm";
if (context != null) {
TextUtils.isEmpty("https://mobilegw.alipay.com/mgw.htm");
}
}
return e(bVar, context, str, str2, true);
}
}
}