UWP 中的 X509Certificates

X509Certificates in UWP

是否可以在 UWP 应用程序中使用 System.Security.Cryptography.X509Certificates?我收到参考错误,但似乎无法找到包含此内容的任何现有库?也许是 NuGet 包?

您不能在通用 Windows 平台应用程序中使用 System.Security.Cryptography。它包含在完整的 .NET(桌面 .NET)中,而 UWP 的 .NET 没有。

正如 CryptoGuy 所建议的,您可以使用 Windows 运行时组件提供的 Certificate class

更新(2016 年 11 月 2 日)

根据最新文档.NET for UWP Apps,X509Certificates 包含在 .NET for UWP 中。