解决办法:
在服务端的Clients中加入
RedirectUris = new List<string>()
{
"http://localhost:49795/"
}
例如:
new Client
{
Enabled = true,
ClientName = "SSO",
ClientId = "mvc",
Flow = Flows.Implicit,
RequireConsent=false,
ClientSecrets=new List<Secret> {new Secret("21B5F798-BE55-42BC-8AA8-0025B903DC3B".Sha256())},
AllowedScopes = new List<string> {
Constants.StandardScopes.OpenId,
Constants.StandardScopes.Profile},
RedirectUris = new List<string>()
{
"http://localhost:49795/"
},
AllowedCorsOrigins = new List<string>
{
"http://localhost:49795/"
}
}
IdentityServer3中出现Invalid redirect_uri的问题:
原文:https://www.cnblogs.com/nirvanan/p/13098226.html