Use CERT_PKEY pointer instead of index