private static ILoaderPal ImportPkcs12(
            ReadOnlySpan <byte> rawData,
            SafePasswordHandle password,
            bool exportable,
            SafeKeychainHandle keychain)
        {
            ApplePkcs12Reader reader = new ApplePkcs12Reader(rawData);

            try
            {
                reader.Decrypt(password);
                return(new ApplePkcs12CertLoader(reader, keychain, password, exportable));
            }
            catch
            {
                reader.Dispose();
                keychain.Dispose();
                throw;
            }
        }
Ejemplo n.º 2
0
 public void Dispose()
 {
     _keychainHandle?.Dispose();
     _keychainHandle = null !;
 }