skoruba / Duende.IdentityServer.Admin

The administration for the Duende IdentityServer and Asp.Net Core Identity ⚡
Apache License 2.0
556 stars 194 forks source link

OpenIdConnectProtocolException - After STS redirected back to Admin #98

Open numb69 opened 1 year ago

numb69 commented 1 year ago

Hey guys,

I am struggling already for days getting this project running via docker on my workstation. I am not really experienced with docker or IdentityServer.

What are my goals? I want to get this Skoruba Duende IdentityServer up and running in docker with the database provider Postgres and move it to azure later. I need it to test my Authentication Implementation in my project.

What I did so far?

  1. I checkout the lastest version from this github project Skoruba/Duende.IdentityServer.Admin
  2. I installed the VS Studio template for this project
  3. I created a new VS Studio project from it with customized names etc... (.NET 6 with Visual Studio 2022)
  4. I changed the database provider to Postgres in the appsettings.json files
  5. I updated the docker-compose file and provided a configuration for the postgres like this and adjusted all connectionstrings with the new infos like host name, user name and password... I also had to remove this MultipleActiveResultSets=true (only supported for MSSQL as it seems ` db: image: postgres:14.1-alpine restart: always container_name: skoruba-duende-identityserver-db environment:

    sa_password: '${db_password:-password_123}'

    • POSTGRES_USER=sa
    • POSTGRES_PASSWORD=Password_123 ports:
    • '5432:5432' volumes:
    • 'dbdata:/var/lib/postgresql/data'
      networks: identityserverui: null `
  6. I did all the configuration Docker Setup steps from the readme (DNS, Certificates, ...)
  7. All the containers are running (I just always get an exception during the MigationSeed step, but almost all data are seeded afterwards) - I am currently NOT using Azure Vault
  8. I had to register a new user (because this data were missing from the Seed step)
  9. I called https://admin.skoruba.local and was forwarded to https://sts.skoruba.local
  10. I entered my Login data successfully and got redirected back to https://admin.skoruba.local/signin-oidc
  11. Here I got the following error: image
  12. I checked some endpoints on https://sts.skoruba.local/.well-known/openid-configuration - for example token_endpoint, where I got an invalid_request error

This are the error logs from step 6: LogFile_SkorubaDuendeIdentity_STS.txt

This is the complete log from https://sts.skoruba.local: LogFile_SkorubaDuendeIdentity_STS_Complete.txt

This is the complete log from https://admin.skoruba.local: LogFile_SkorubaDuendeIdentity_Admin.txt

Pleeease can anyone help me with this problem? What did I do wrong? Thank you sooo much!

Best regards, Michael