Asp.net 在IdentitySer4资源服务器实现中调用.ProtectKeysWithCertificate(cert)方法时出错
最后一行“.ProtectKeysWithCertificate(cert);”返回错误。然而,本教程没有。我不明白为什么方法“ProtectKeysWithCertificate()”会返回。 如果有人能放纵我,我将不胜感激Asp.net 在IdentitySer4资源服务器实现中调用.ProtectKeysWithCertificate(cert)方法时出错,asp.net,identityserver4,data-protection,Asp.net,Identityserver4,Data Protection,最后一行“.ProtectKeysWithCertificate(cert);”返回错误。然而,本教程没有。我不明白为什么方法“ProtectKeysWithCertificate()”会返回。 如果有人能放纵我,我将不胜感激 谢谢看起来.NET Core中没有ProtectKeysWithCertificate。以下是达米恩在推特上的讨论:作为后续内容。我将ASP.NETCore1.1用于一个应用程序,与该教程的思想相同。我在Microsoft.AspNetCore.DataProtectio
谢谢看起来.NET Core中没有ProtectKeysWithCertificate。以下是达米恩在推特上的讨论:作为后续内容。我将ASP.NETCore1.1用于一个应用程序,与该教程的思想相同。我在Microsoft.AspNetCore.DataProtection Version=1.1.0.0中再也找不到.ProtectKeysWithCertificate()方法。
services.AddDataProtection()
.SetApplicationName("Report Book Resource Server")
.PersistKeysToFileSystem(new DirectoryInfo(folderForKeyStore))
.ProtectKeysWithCertificate(cert);