Version 6.x has been out of support since May 14, 2024, and this corresponding section of the documentation is no longer maintained. We strongly recommend you upgrade to the latest supported version of 7.x and read the latest version of this documentation.
This solution contains a collection of common scenarios.
This sample shows how to use the client_credentials grant type. This is typically used for machine to machine communication.
Key takeaways:
This sample shows how to use the client_credentials grant type with JWT-based client authentication. This authentication method is more recommended than shared secrets.
Key takeaways:
This sample shows how to use the reference tokens instead of JWTs.
Things of interest:
Key takeaways:
This sample shows how to use the authorization_code grant type. This is typically used for interactive applications like web applications.
Key takeaways:
This sample shows how to use IdentityModel.AspNetCore to automatically manage access tokens.
The sample uses a special client ID in the sample IdentityServer with a short token lifetime (75 seconds). When repeating the API call, make sure you inspect the returned iat and exp claims to observer how the token is slides.
You can also turn on debug tracing to get more insights in the token management library.
Key takeaways:
This sample shows how to use signed authorize requests, and JWT-based authentication for clients in MVC. It also show how to integrate that technique with automatic token management.
Key takeaways:
This sample shows how to use back-channel logout notifications.
Key takeaways: