相关疑难解决方法(0)

IdentityServer4 PostLogoutRedirectUri

我对如何使用它感到困惑。

我见过的大多数示例都将其指定为“ / signout-callback-oidc”。这似乎表明它在此过程中使用了OIDC中间件。如果我想返回特定的客户页面怎么办?

当我将IdentityServer的AutomaticRedirectAfterSignOut的AccountOptions.cs属性设置为true时,自动重定向不起作用。此外,在注销期间,我没有收到客户端的PostLogoutRedirectUri。

那么,该链接应该转到OIDC中间件,还是可以用于重定向到客户端?

identityserver4

7
推荐指数
2
解决办法
7331
查看次数

为什么 Identity Server GetLogoutContextAsync() 方法总是为 PostLogoutRedirectUri 返回 null?

身份服务器正在按预期工作。我可以登录用户并注销用户。然而,对象PostLogoutRedirectUri的属性LogoutRequest总是返回为空。

我的 SPA 客户端配置:

    {
        ClientId = "pokemon",
        ClientName = "Angular Pokemon Client",
    
        AllowedGrantTypes = GrantTypes.Code,
        RequireClientSecret = false,
        RedirectUris =           { "http://localhost:4200/login" },
        PostLogoutRedirectUris = { "http://localhost:4200" },
        AllowedCorsOrigins =     { "http://localhost:4200" },
        AllowOfflineAccess = true,
        AllowAccessTokensViaBrowser = true,
        AllowRememberConsent = false,
        RequireConsent = true,
    
         AllowedScopes = 
         {
             IdentityServerConstants.StandardScopes.OpenId,
             IdentityServerConstants.StandardScopes.Profile,
             "scope1"
         }
}
Run Code Online (Sandbox Code Playgroud)

对象的设置AccountOptions为:

public static bool AllowLocalLogin = true;
public static bool AllowRememberLogin = true;
/.../
public static bool ShowLogoutPrompt = false; …
Run Code Online (Sandbox Code Playgroud)

identityserver4

6
推荐指数
1
解决办法
2820
查看次数

标签 统计

identityserver4 ×2