package okhttp3.n0.connection;

import g.h.a.i;
import java.security.cert.Certificate;
import java.security.cert.X509Certificate;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import kotlin.Metadata;
import kotlin.jvm.functions.Function0;
import kotlin.jvm.internal.Lambda;
import kotlin.jvm.internal.o;
import okhttp3.Handshake;

/* JADX INFO: loaded from: classes2.dex */
@Metadata(d1 = {"\u0000\f\n\u0000\n\u0002\u0010 \n\u0002\u0018\u0002\n\u0000\u0010\u0000\u001a\b\u0012\u0004\u0012\u00020\u00020\u0001H\n¢\u0006\u0002\b\u0003"}, d2 = {"<anonymous>", "", "Ljava/security/cert/X509Certificate;", "invoke"}, k = 3, mv = {1, 6, 0}, xi = 48)
public final class h extends Lambda implements Function0<List<? extends X509Certificate>> {

    /* JADX INFO: renamed from: f, reason: collision with root package name */
    public final /* synthetic */ RealConnection f9807f;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public h(RealConnection realConnection) {
        super(0);
        this.f9807f = realConnection;
    }

    @Override // kotlin.jvm.functions.Function0
    public List<? extends X509Certificate> invoke() {
        Handshake handshake = this.f9807f.f9791e;
        o.c(handshake);
        List<Certificate> listC = handshake.c();
        ArrayList arrayList = new ArrayList(i.H(listC, 10));
        Iterator<T> it = listC.iterator();
        while (it.hasNext()) {
            arrayList.add((X509Certificate) ((Certificate) it.next()));
        }
        return arrayList;
    }
}
