我正在尝试使用OpenID从Tableau服务器使用IdentityServer4进行授权,我没有运气。我有一个为支持的OpenID授权代码流配置的IdentityServer4客户端,我能够完成重定向到IdentityServer登录页面的前几个步骤,成功登录,接受声明类型,然后当重定向回Tableau时,我得到一个User could not be found
错误。我正在使用IdentityServer安装附带的内存测试用户(bob),并在Tableau中创建了确切的用户和电子邮件地址。
我的客户如下:
new Client
{
ClientId = "tableau",
ClientSecrets =
{
new Secret("[my secret]", "tableau.secret")
{
Type = SecretTypes.SharedSecret
},
},
AllowedGrantTypes = GrantTypes.CodeAndClientCredentials,
AllowAccessTokensViaBrowser = true,
AccessTokenType = AccessTokenType.Jwt,
RedirectUris = { "http://[tableuServer]/vizportal/api/web/v1/auth/openIdLogin" },
AllowOfflineAccess = true,
AllowedScopes =
{
IdentityServerConstants.StandardScopes.OpenId,
IdentityServerConstants.StandardScopes.Profile,
IdentityServerConstants.StandardScopes.Email,
IdentityServerConstants.StandardScopes.Phone,
IdentityServerConstants.StandardScopes.Address
}
},
我真的希望有人已经有了这个工作,并且可以分享一个工作的客户或我需要做的改变。这个IdentityServer适用于其他3种客户端类型,所以我知道我在这方面做得很好。
看起来Tableau无法识别用户。验证Tableau和Identity Server中的用户名之间是否存在任何不匹配。 Identity Server在IDToken中发送唯一用户标识符(IDToken中的子声明)。 IDToken中的此子声明用于标识Tableau中的用户。很少有参考链接:https://onlinehelp.tableau.com/current/server/en-us/openid_auth_troubleshooting.htm https://onlinehelp.tableau.com/current/server/en-us/openid_auth_signing_in.htm