public static bool HasPrivateKey(this SafeCertContextHandle certificateContext) { return(certificateContext.HasProperty(WindowsX509Native.CertificateProperty.KeyProviderInfo)); }