fix-38054
[mono.git] / mcs / class / corlib / System.Security.Cryptography / RSACryptoServiceProvider.cs
index a8ebc812da3aff1068f07cb3114b0099cdc870a0..16fdfa15e5eb7a9d3b191fa793c83a036e558b7b 100644 (file)
@@ -111,6 +111,7 @@ namespace System.Security.Cryptography {
                        store = new KeyPairPersistence (p);
                        bool exists = store.Load ();
                        bool required = (p.Flags & CspProviderFlags.UseExistingKey) != 0;
+                       privateKeyExportable = (p.Flags & CspProviderFlags.UseNonExportableKey) == 0;
 
                        if (required && !exists)
                                throw new CryptographicException ("Keyset does not exist");