LinkFromCertificateCollection() public static method

Note: this factory method creates the store using links to the original certificates rather than copies. This means that any changes to certificate properties in the store changes the original.
public static LinkFromCertificateCollection ( X509Certificate2Collection certificates ) : IExportPal
certificates System.Security.Cryptography.X509Certificates.X509Certificate2Collection
return IExportPal
        private static SafeCertStoreHandle ConvertExtraStoreToSafeHandle(X509Certificate2Collection extraStore)
        {
            if (extraStore == null || extraStore.Count == 0)
            {
                return(SafeCertStoreHandle.InvalidHandle);
            }

            return(((StorePal)StorePal.LinkFromCertificateCollection(extraStore)).SafeCertStoreHandle);
        }
Beispiel #2
0
 internal FindPal(X509Certificate2Collection findFrom, X509Certificate2Collection copyTo, bool validOnly)
 {
     _storePal  = (StorePal)StorePal.LinkFromCertificateCollection(findFrom);
     _copyTo    = copyTo;
     _validOnly = validOnly;
 }