Пример #1
0
 public static X509Certificate2 GetCertificateByThumbprint(string certThumbprint)
 {
     foreach (StoreLocation current in CertificateStore.defaultStoreLocationsToSearch)
     {
         X509Certificate2 certificateByThumbprint = CertificateStore.GetCertificateByThumbprint(certThumbprint, current);
         if (certificateByThumbprint != null)
         {
             return(certificateByThumbprint);
         }
     }
     return(null);
 }
Пример #2
0
 public KeyVaultWrapper(string clientId, string appCertThumbprint) : this(clientId, CertificateStore.GetCertificateByThumbprint(appCertThumbprint))
 {
 }