Search code examples
c#securityauthenticationasp.net-web-api2thinktecture-ident-server

How to run IdentityServer3 samples?


It is hard for me to complitly uderstand how works identoty server 3. Even when I spent lot of time to investigate. Now I am trying to run IdentityServer3 samples.

I can run client (for example: WPF Implicit Client), but I cannot login when I run this.

I assume that I have to run two more projects

  • Project which host identity server (place where clients and scopes are registred)
  • and also api project.

When I try to run 'Sample Web API' project I get error:

An exception of type 'System.InvalidOperationException' occurred in IdentityServer3.AccessTokenValidation.dll but was not handled in user code

Additional information: IDX10803: Unable to create to obtain configuration from: 'https://localhost:44333/core/.well-known/openid-configuration'.

  • So probably still missing identity server project but I don’t know where is this project? (I am talking about project with localhost:44333).

  • Also do I need to set certificate somehow?

I tryied so many things and still nothig. Can you please help me to run this examples. Because this does not work when just download solution.

It would be great if someone knows steps what need to be done to make semples work.

Thanks for help.


Solution

  • Samples will not work, without Identiy server host.

    For that I had to download Identity Server 3, and than run 'Host.Console' project (probably will also work with 'Host.Web' project)

    Samples and Host console should be open in separate visual studio instances and run at the same time.