- Added realracing3-community.apk (71.57 MB) - Removed 32-bit support (armeabi-v7a) - Only includes arm64-v8a libraries - Decompiled source code included - Added README-community.md with analysis
85 lines
3.3 KiB
Java
85 lines
3.3 KiB
Java
package com.fyber.inneractive.sdk.web;
|
|
|
|
import android.text.TextUtils;
|
|
import java.text.ParseException;
|
|
import java.text.SimpleDateFormat;
|
|
import java.util.Date;
|
|
import java.util.HashMap;
|
|
import java.util.Locale;
|
|
import java.util.Map;
|
|
import java.util.concurrent.TimeUnit;
|
|
import java.util.regex.Matcher;
|
|
import java.util.regex.Pattern;
|
|
|
|
/* loaded from: classes2.dex */
|
|
public final class e0 {
|
|
public static final Pattern g = Pattern.compile("max-age=(\\d+)");
|
|
public static final SimpleDateFormat h = new SimpleDateFormat("EEE, dd MMM yyyy HH:mm:ss zzz", Locale.ENGLISH);
|
|
public final byte[] a;
|
|
public final Map<String, String> b;
|
|
public final String c;
|
|
public final String d;
|
|
public final int e;
|
|
public final String f;
|
|
|
|
public e0(byte[] bArr, HashMap hashMap, String str, String str2, int i, String str3) {
|
|
this.a = bArr;
|
|
this.b = hashMap;
|
|
this.c = str;
|
|
this.d = str2;
|
|
this.e = i;
|
|
this.f = str3;
|
|
}
|
|
|
|
public final boolean a() {
|
|
boolean z;
|
|
String str;
|
|
if (TextUtils.isEmpty(this.f)) {
|
|
return false;
|
|
}
|
|
loop0: while (true) {
|
|
z = true;
|
|
for (String str2 : this.b.keySet()) {
|
|
if (!z) {
|
|
break loop0;
|
|
}
|
|
if (str2 == null || !str2.equalsIgnoreCase("Cache-Control")) {
|
|
if (str2 == null || !str2.equalsIgnoreCase("Vary")) {
|
|
if (str2 != null && str2.equalsIgnoreCase("Pragma")) {
|
|
String str3 = this.b.get(str2);
|
|
if (str3 != null) {
|
|
z = !str3.equalsIgnoreCase("no-cache");
|
|
}
|
|
} else if (str2 != null && str2.equalsIgnoreCase("Expires") && (str = this.b.get(str2)) != null) {
|
|
try {
|
|
Date parse = h.parse(str);
|
|
if (parse != null && parse.getTime() + TimeUnit.MILLISECONDS.convert(1L, TimeUnit.HOURS) > System.currentTimeMillis()) {
|
|
break;
|
|
}
|
|
} catch (ParseException unused) {
|
|
continue;
|
|
}
|
|
}
|
|
}
|
|
z = false;
|
|
} else {
|
|
String str4 = this.b.get(str2);
|
|
if (str4 != null) {
|
|
Pattern pattern = g;
|
|
Locale locale = Locale.ENGLISH;
|
|
Matcher matcher = pattern.matcher(str4.toLowerCase(locale));
|
|
int a = (matcher.find() && matcher.groupCount() == 1) ? com.fyber.inneractive.sdk.util.t.a(matcher.group(1), 0) : 0;
|
|
if ((str4.toLowerCase(locale).contains("public") || str4.toLowerCase(locale).contains("private") || a > TimeUnit.SECONDS.convert(1L, TimeUnit.HOURS)) && !str4.toLowerCase(locale).contains("no-") && !str4.toLowerCase(locale).contains("must-")) {
|
|
break;
|
|
}
|
|
z = false;
|
|
} else {
|
|
continue;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
return z;
|
|
}
|
|
}
|