我正在经历this Example。此示例(对于Facebook)是否使用显式身份验证流程或隐式身份验证流程?
答案 0 :(得分:1)
查看Katana FacebookAuthenticationHandler.ApplyResponseChallengeAsync()
命名空间中的Microsoft.Owin.Security.Facebook
代码,看起来总是启动"授权代码"遇到HTTP 401时流动。
string authorizationEndpoint =
"https://www.facebook.com/dialog/oauth" +
"?response_type=code" +
"&client_id=" + Uri.EscapeDataString(Options.AppId) +
"&redirect_uri=" + Uri.EscapeDataString(redirectUri) +
"&scope=" + Uri.EscapeDataString(scope) +
"&state=" + Uri.EscapeDataString(state);
这就是为什么你必须在配置中提供clientId和secret的原因。对于隐式流,你不会在任何地方使用秘密。