package com.google.android.gms.internal.p002firebaseauthapi;

import com.google.android.gms.internal.p002firebaseauthapi.zzew;
import java.security.GeneralSecurityException;

/* JADX INFO: loaded from: classes3.dex */
public class zzex extends zzcp {
    private final zzew zza;
    private final zzzn zzb;
    private final Integer zzc;

    private zzex(zzew zzewVar, zzzn zzznVar, Integer num) {
        this.zza = zzewVar;
        this.zzb = zzznVar;
        this.zzc = num;
    }

    public static zzex zza(zzew zzewVar, Integer num) throws GeneralSecurityException {
        zzzn zzznVarZzb;
        if (zzewVar.zzc() == zzew.zzc.zzb) {
            if (num != null) {
                throw new GeneralSecurityException("For given Variant NO_PREFIX the value of idRequirement must be null");
            }
            zzznVarZzb = zzor.zza;
        } else {
            if (zzewVar.zzc() != zzew.zzc.zza) {
                throw new GeneralSecurityException("Unknown Variant: ".concat(String.valueOf(zzewVar.zzc())));
            }
            if (num == null) {
                throw new GeneralSecurityException("For given Variant TINK the value of idRequirement must be non-null");
            }
            zzznVarZzb = zzor.zzb(num.intValue());
        }
        return new zzex(zzewVar, zzznVarZzb, num);
    }

    public final zzew zzb() {
        return this.zza;
    }

    public final zzzn zzc() {
        return this.zzb;
    }

    @Override // com.google.android.gms.internal.p002firebaseauthapi.zzbo
    public final Integer zza() {
        return this.zzc;
    }
}
