178 lines
6.4 KiB
Java
178 lines
6.4 KiB
Java
|
package com.facetec.sdk;
|
||
|
|
||
|
import com.google.common.net.HttpHeaders;
|
||
|
import java.util.ArrayList;
|
||
|
import java.util.Collections;
|
||
|
import java.util.Date;
|
||
|
import java.util.List;
|
||
|
import java.util.regex.Pattern;
|
||
|
|
||
|
/* loaded from: classes.dex */
|
||
|
public final class jq {
|
||
|
public final String a;
|
||
|
public final String c;
|
||
|
private final String f;
|
||
|
private final String h;
|
||
|
private final boolean i;
|
||
|
private final long j;
|
||
|
private final boolean k;
|
||
|
private final boolean l;
|
||
|
private final boolean n;
|
||
|
private static final Pattern d = Pattern.compile("(\\d{2,4})[^\\d]*");
|
||
|
private static final Pattern b = Pattern.compile("(?i)(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec).*");
|
||
|
private static final Pattern e = Pattern.compile("(\\d{1,2})[^\\d]*");
|
||
|
private static final Pattern g = Pattern.compile("(\\d{1,2}):(\\d{1,2}):(\\d{1,2})[^\\d]*");
|
||
|
|
||
|
private jq(String str, String str2, long j, String str3, String str4, boolean z, boolean z2, boolean z3, boolean z4) {
|
||
|
this.a = str;
|
||
|
this.c = str2;
|
||
|
this.j = j;
|
||
|
this.f = str3;
|
||
|
this.h = str4;
|
||
|
this.i = z;
|
||
|
this.n = z2;
|
||
|
this.k = z3;
|
||
|
this.l = z4;
|
||
|
}
|
||
|
|
||
|
private static boolean e(String str, String str2) {
|
||
|
if (str.equals(str2)) {
|
||
|
return true;
|
||
|
}
|
||
|
return str.endsWith(str2) && str.charAt((str.length() - str2.length()) - 1) == '.' && !km.b(str);
|
||
|
}
|
||
|
|
||
|
/* JADX WARN: Code restructure failed: missing block: B:154:0x025f, code lost:
|
||
|
|
||
|
if (r0 > 253402300799999L) goto L132;
|
||
|
*/
|
||
|
/* JADX WARN: Multi-variable type inference failed */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:158:0x0273 */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:161:0x0288 */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:169:0x02e6 A[RETURN] */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:192:0x030a */
|
||
|
/* JADX WARN: Removed duplicated region for block: B:194:0x0275 */
|
||
|
/* JADX WARN: Type inference failed for: r3v0 */
|
||
|
/* JADX WARN: Type inference failed for: r3v1, types: [int, boolean] */
|
||
|
/* JADX WARN: Type inference failed for: r3v26 */
|
||
|
/* JADX WARN: Type inference failed for: r9v24 */
|
||
|
/* JADX WARN: Type inference failed for: r9v30 */
|
||
|
/* JADX WARN: Type inference failed for: r9v6, types: [int, boolean] */
|
||
|
/*
|
||
|
Code decompiled incorrectly, please refer to instructions dump.
|
||
|
To view partially-correct add '--show-bad-code' argument
|
||
|
*/
|
||
|
private static com.facetec.sdk.jq e(long r29, com.facetec.sdk.kc r31, java.lang.String r32) {
|
||
|
/*
|
||
|
Method dump skipped, instructions count: 794
|
||
|
To view this dump add '--comments-level debug' option
|
||
|
*/
|
||
|
throw new UnsupportedOperationException("Method not decompiled: com.facetec.sdk.jq.e(long, com.facetec.sdk.kc, java.lang.String):com.facetec.sdk.jq");
|
||
|
}
|
||
|
|
||
|
private static int b(String str, int i, int i2, boolean z) {
|
||
|
while (i < i2) {
|
||
|
char charAt = str.charAt(i);
|
||
|
if (((charAt < ' ' && charAt != '\t') || charAt >= 127 || (charAt >= '0' && charAt <= '9') || ((charAt >= 'a' && charAt <= 'z') || ((charAt >= 'A' && charAt <= 'Z') || charAt == ':'))) == (!z)) {
|
||
|
return i;
|
||
|
}
|
||
|
i++;
|
||
|
}
|
||
|
return i2;
|
||
|
}
|
||
|
|
||
|
private static long e(String str) {
|
||
|
try {
|
||
|
long parseLong = Long.parseLong(str);
|
||
|
if (parseLong <= 0) {
|
||
|
return Long.MIN_VALUE;
|
||
|
}
|
||
|
return parseLong;
|
||
|
} catch (NumberFormatException e2) {
|
||
|
if (str.matches("-?\\d+")) {
|
||
|
return str.startsWith("-") ? Long.MIN_VALUE : Long.MAX_VALUE;
|
||
|
}
|
||
|
throw e2;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
public final boolean equals(Object obj) {
|
||
|
if (!(obj instanceof jq)) {
|
||
|
return false;
|
||
|
}
|
||
|
jq jqVar = (jq) obj;
|
||
|
return jqVar.a.equals(this.a) && jqVar.c.equals(this.c) && jqVar.f.equals(this.f) && jqVar.h.equals(this.h) && jqVar.j == this.j && jqVar.i == this.i && jqVar.n == this.n && jqVar.l == this.l && jqVar.k == this.k;
|
||
|
}
|
||
|
|
||
|
public final int hashCode() {
|
||
|
int hashCode = this.a.hashCode();
|
||
|
int hashCode2 = this.c.hashCode();
|
||
|
int hashCode3 = this.f.hashCode();
|
||
|
int hashCode4 = this.h.hashCode();
|
||
|
long j = this.j;
|
||
|
return ((((((((((((((((hashCode + 527) * 31) + hashCode2) * 31) + hashCode3) * 31) + hashCode4) * 31) + ((int) ((j >>> 32) ^ j))) * 31) + (!this.i ? 1 : 0)) * 31) + (!this.n ? 1 : 0)) * 31) + (!this.l ? 1 : 0)) * 31) + (!this.k ? 1 : 0);
|
||
|
}
|
||
|
|
||
|
public static List<jq> a(kc kcVar, jv jvVar) {
|
||
|
List emptyList;
|
||
|
int c = jvVar.c();
|
||
|
ArrayList arrayList = null;
|
||
|
ArrayList arrayList2 = null;
|
||
|
for (int i = 0; i < c; i++) {
|
||
|
if (HttpHeaders.SET_COOKIE.equalsIgnoreCase(jvVar.c(i))) {
|
||
|
if (arrayList2 == null) {
|
||
|
arrayList2 = new ArrayList(2);
|
||
|
}
|
||
|
arrayList2.add(jvVar.a(i));
|
||
|
}
|
||
|
}
|
||
|
if (arrayList2 != null) {
|
||
|
emptyList = Collections.unmodifiableList(arrayList2);
|
||
|
} else {
|
||
|
emptyList = Collections.emptyList();
|
||
|
}
|
||
|
int size = emptyList.size();
|
||
|
for (int i2 = 0; i2 < size; i2++) {
|
||
|
jq e2 = e(System.currentTimeMillis(), kcVar, (String) emptyList.get(i2));
|
||
|
if (e2 != null) {
|
||
|
if (arrayList == null) {
|
||
|
arrayList = new ArrayList();
|
||
|
}
|
||
|
arrayList.add(e2);
|
||
|
}
|
||
|
}
|
||
|
if (arrayList != null) {
|
||
|
return Collections.unmodifiableList(arrayList);
|
||
|
}
|
||
|
return Collections.emptyList();
|
||
|
}
|
||
|
|
||
|
public final String toString() {
|
||
|
StringBuilder sb = new StringBuilder();
|
||
|
sb.append(this.a);
|
||
|
sb.append('=');
|
||
|
sb.append(this.c);
|
||
|
if (this.l) {
|
||
|
if (this.j == Long.MIN_VALUE) {
|
||
|
sb.append("; max-age=0");
|
||
|
} else {
|
||
|
sb.append("; expires=");
|
||
|
sb.append(ld.d(new Date(this.j)));
|
||
|
}
|
||
|
}
|
||
|
if (!this.k) {
|
||
|
sb.append("; domain=");
|
||
|
sb.append(this.f);
|
||
|
}
|
||
|
sb.append("; path=");
|
||
|
sb.append(this.h);
|
||
|
if (this.i) {
|
||
|
sb.append("; secure");
|
||
|
}
|
||
|
if (this.n) {
|
||
|
sb.append("; httponly");
|
||
|
}
|
||
|
return sb.toString();
|
||
|
}
|
||
|
}
|