question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

X509SecurityKey.KeyId update breaks IdentityServer4 clients

See original GitHub issue

I’ve updated Microsoft.IdentityModel.Tokens from version 5.3.0 to 5.4.0 and the KeyId has been changed from thumbprint to base64 encoded hash of the certificate. See: https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/commit/760fa3046cc36591c9f7835031745fcd625cf6ec#diff-ad9f507af4d8334a3a5dbcafbb0ded30

I’ve got IdentityServer4 running and this changes the kid (KeyId) in the openid connect endpoint .well-known/openid-configuration/jwks which breaks JWT validation on my clients. The currently logged in users have a token from a different (now non-existing) keyid when I deploy this update.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:7
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

4reactions
brockallencommented, Apr 12, 2019

Yea, this is a breaking change in a patch. Why was this change needed?

3reactions
HitDaCacommented, Mar 28, 2019

This change will brake any existing application which uses X509SecurityKey and expects to validate certificate Thumbprints through the originally offered KeyId.

E.g. this change could likely also break Identity Server 4’s commercial SSO plugin if the receiving party validates for thumbprints.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot Validate AccessToken with IdentityServer
Any ideas why the code broke during the upgrade since the certificate, token and IdentityServer are still the same and only the client...
Read more >
Gotchas upgrading from IdentityServer 3 to IdentityServer 4
This post covers a couple of gotchas I experienced upgrading an IdentityServer 3 implementation to IdentityServer 4.
Read more >
IdentityServer4 v4.1 to Duende IdentityServer v6
This upgrade guide covers upgrading from IdentityServer4 v4.1.x to Duende ... This issue tracks the list of updates where a breaking change might...
Read more >
Orchestrator - Identity Server Troubleshooting
Navigate to the Identity Server Swagger API at https://<server>/identity/swagger .
Read more >
IdentityServer4 Documentation
Updating the client configuration in IdentityServer is straightforward - we simply need to add the api1 resource to the allowed scopes list.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found