identityserver3

ASP.NET Core Identity Settings Not Working

北城余情 提交于 2019-12-11 05:12:14
问题 I've an implementation of Identity Server 4 with ASP.NET Identity. I asked an earlier question about how I would apply certain login rules and received an answer explaining how I could add some options in Startup.cs . Here's what I added to the ConfigureServices method: services.AddIdentity<ApplicationUser, IdentityRole>(options => { options.Lockout.DefaultLockoutTimeSpan = TimeSpan.FromMinutes(15); options.Lockout.MaxFailedAccessAttempts = 5; options.Password.RequiredLength = 9; options

IdentityServer3 redirect Logout to the Custom URL

房东的猫 提交于 2019-12-11 05:09:15
问题 I searched in google and Stack Overflow there is no appropriate answer is available. I'm using ReactJs + Redux in the Client Application, .Net WebAPI is used for contacting the Database and other logical implementation and Finally I'm using IdentityServer3 for authenticating the User. Once I hit the Logout I'm triggering the following URL : https://localhost:123/core/connect/endsession new Client { Enabled = true, ClientName = "Super Star Application", ClientId = "SS", Flow = Flows.Implicit,

Multiple authenticaion schemes in asp .net core 2.0

时光总嘲笑我的痴心妄想 提交于 2019-12-11 02:27:47
问题 I need to support two authentication types in ASP.NET Core 2.0 MVC application: AddIdentityServerAuthentication AddOpenIdConnect It was very easy in ASP.NET Core 1.0 version. But in version 2.0 version syntax changed. This is my code: services.AddAuthentication(o => { o.DefaultSignInScheme = CookieAuthenticationDefaults.AuthenticationScheme; o.DefaultChallengeScheme = OpenIdConnectDefaults.AuthenticationScheme; o.DefaultAuthenticateScheme = OpenIdConnectDefaults.AuthenticationScheme; })

disabling SSL for identityserver3

本小妞迷上赌 提交于 2019-12-11 01:06:35
问题 new to using this framework. I have an OAuth client and I am running IdentityServer3 console app. I get an error to my client saying SSL is required. Is there a way to disable the SSL from IdentityServer3 (temporarily) so i can develop/code/test my stuff. It would be handy as other developers are working on this as well. I have changed the base-points fro https to http but still SSL required error. thanks this is my 'server code': private static string ServerURL = "http://localhost:44335";

Precompiled Azure Function throwing error on HttpClientExtensions.SetBearerToken use, CSX doesn't

こ雲淡風輕ζ 提交于 2019-12-10 23:04:32
问题 So first off, I'm using the following blog post to help me convert my CSX Azure Function to a precompiled class library - https://blogs.msdn.microsoft.com/appserviceteam/2017/03/16/publishing-a-net-class-library-as-a-function-app/?utm_source=Direct I've got it to the point where I think it should be working, but as a precompiled function it throws a 'Method Not Found' exception on SetBearerToken (which is in System.Net.Http.HttpClientExtensions) but it doesn't have any problem finding this

How to set up cookie based authentication with NancyFx and IdentityServer3 (non-API website)

眉间皱痕 提交于 2019-12-10 14:12:38
问题 We have an environment with the following: Standalone IdentityServer3 instance (issues reference tokens, not jwt) ASP.NET WebAPI resource server .NET client applications that authenticate against IdSvr (via resource owner flow) ...and now we'd like to start adding an OWIN-hosted web app that will use NancyFx to serve server-rendered pages as well as a couple AngularJS SPAs. This Nancy website will NOT host any APIs, but may consume data from our existing API. I'd like to add authentication in

Cannot Validate AccessToken with IdentityServer

那年仲夏 提交于 2019-12-10 13:49:53
问题 We are using IdentityServer for authentication and we are validating the access token using JwtSecurityTokenHandler ValidateToken. This used to work fine, but after we upgraded our client application to ASP.NET Core 1.0 RTM (from RC1), the validation fails. The received error is: IDX10501: Signature validation failed. Unable to match 'kid' When I look at the KeyID of the used certificate and the kid of the token, I can see that they are different. I checked the IdentityServer jwks-endpoint to

Change default endpoint in IdentityServer 4

青春壹個敷衍的年華 提交于 2019-12-09 06:22:38
问题 I was working around IdentityServer 4 (1.0.0-beta5). By default, the endpoint for authentication is: '/connect/token' . How can I change the default endpoints in IdentityServer, for instance to: '/api/login'? Thanks 回答1: Right now you cannot change the endpoint URLs of the protocol endpoints. If you think this is needed, please open an issue on github. 回答2: Once you setup Identity Server 4 at Startup - you could use this "hack" and update the endpoint paths: var builder = services

Thinktecture IdentityServer v3 with WindowsAuth

不问归期 提交于 2019-12-09 04:57:11
问题 I want to use Thinktecture IdentityServer as a token-provider and authenticate users against ActiveDirectory. So that token contain information about the domain user. Both Client and IdentityServer (IIS) reside inside a Windows domain. When Client authenticates with the user account in IIS it uses WindowsAuth. How can this be done? Appreciate for working code sample. 回答1: You would need to create a custom user service , see this example https://gist.github.com/tjrobinson/0ad6c790e90d7a385eb1

Is it possible to have SPA authentication without redirecting to an outside login page

*爱你&永不变心* 提交于 2019-12-08 19:26:58
问题 I am currently developing an SPA application that connects to a bunch of webAPI's. These API require that the user is logged in, so I started digging into Openid Conect and OAuth2 examples, mostly using IdentityServer. They all require, for SPA reasons, that the implicit grant should be used for retrieving access_tokens. Token refreshes are handled connecting to authentication server using hidden iframe. What I understand from this approach o renewing your access_token is that, sessions is