DEV Community

Discussion on: Setting up an Authorization Server with OpenIddict - Part III - Client Credentials Flow

Collapse
 
rezapouya profile image
Reza Pouya • Edited

thanks.

Machine A get token from AuthorizationServer, and try to send a request to machine B , how Machine B should connect to AuthorizationServer and validate the incoming token ?!

both Machine A and Machine B are Asp.Net Core app

Collapse
 
robinvanderknaap profile image
Robin van der Knaap • Edited

Hi Reza,

That process is called introspection, where machine B asks the Authorization Server to validate the token.

First you need to set the introspection endpoint when setting up the Authorization Server:

options
     .SetIntrospectionEndpointUris("/connect/introspect");
Enter fullscreen mode Exit fullscreen mode

You also need to give permission to Machine B (client) to use the introspection endpoint:

Permissions =
{
    OpenIddictConstants.Permissions.Endpoints.Introspection
}
Enter fullscreen mode Exit fullscreen mode

Regards,
Robin

Collapse
 
rezapouya profile image
Reza Pouya

thanks