我有一个使用加密技术的ASP.Net Core 1.0.0应用程序,需要使用
RSACryptoServiceProvider
解密密钥。Visual Studio建议将System.Security.Cryptography.Csp
版本4.0.0添加到我的依赖项中。我接受了,并且在Windows上一切正常。但是当我将其部署在Ubuntu 16.04上时,RSACryptoServiceProvider
的方法开始抛出PlatformNotSupportedException
异常。我是否使用了错误的程序集?
我在https://github.com/dotnet/corefx/tree/v1.0.0/src/System.Security.Cryptography.Csp找到了1.0.0版本。这就是我需要的吗?我该如何将它添加到我的项目中?
RSA
运行良好。但我仍然不明白为什么要在Net Standart包中包含Windows特定工具的意义所在... - SlipRSACryptoServiceProvider
、RSACng
或RSAOpenSsl
,从而实现高级方案(例如,在使用RSACng
时可以使用依赖特定密钥存储提供程序的CngKey
)。 - Kévin Chalet