我有一个自定义AuthenticationHandler
来绑定到ASP.NET Core中基于声明的授权。 ServiceStack是否可以重用此组件,或者我必须将其实现为自定义AuthProvider
?
答案 0 :(得分:2)
看看新的mvcidentity .NET Core template,它显示了一个使用ASP.NET身份验证Auth来保护MVC和ServiceStack Services的示例。
integration is enabled with the new NetCoreIdentityAuthProvider提供了双向适配器,可以在ASP.NET Core ClaimsPrincipal和ServiceStack用户会话之间进行转换。