IdentityServer+WebApi+Vue+Oidc.js登录闪退问题

                new Client
                {
                    ClientId = "admin.ui",//同域同端口使用一个ClientId可以避免登录闪退,Oidc.js也用这个ClientId
                    ClientName = "admin系统设置",
                    AllowedGrantTypes = GrantTypes.Implicit,
                    //ClientSecrets = new []{ new Secret(appSettings.AdminUI.Secret.Sha256()) },
                    RequireConsent = false, //同意
                    AllowAccessTokensViaBrowser = true,
                    AccessTokenLifetime = appSettings.AdminUI.AccessTokenLifetime, //2小时 = 3600 * 2
                    //SlidingRefreshTokenLifetime = 3600 * 24, //1天 = 3600 * 24
                    //AllowOfflineAccess = true,
                    //AlwaysIncludeUserClaimsInIdToken = true,
                    RedirectUris = appSettings.AdminUI.RedirectUris,
                    PostLogoutRedirectUris = appSettings.AdminUI.PostLogoutRedirectUris,
                    AllowedCorsOrigins = appSettings.CorUrls,
                    AllowedScopes =
                    {
                        IdentityServerConstants.StandardScopes.OpenId,
                        IdentityServerConstants.StandardScopes.Profile,
                    }
                },
posted @ 2021-08-06 15:19  TTonlyV5  阅读(213)  评论(0编辑  收藏  举报