Class DefaultResourceValidator
- Namespace
- Duende.IdentityServer.Validation
- Assembly
- Duende.IdentityServer.dll
Default implementation of IResourceValidator.
public class DefaultResourceValidator : IResourceValidator
- Inheritance
-
DefaultResourceValidator
- Implements
- Inherited Members
Constructors
DefaultResourceValidator(IResourceStore, IScopeParser, ILogger<DefaultResourceValidator>)
Initializes a new instance of the DefaultResourceValidator class.
public DefaultResourceValidator(IResourceStore store, IScopeParser scopeParser, ILogger<DefaultResourceValidator> logger)
Parameters
store
IResourceStoreThe store.
scopeParser
IScopeParserlogger
ILogger<DefaultResourceValidator>The logger.
Methods
IsClientAllowedApiScopeAsync(Client, ApiScope)
Determines if client is allowed access to the API scope.
protected virtual Task<bool> IsClientAllowedApiScopeAsync(Client client, ApiScope apiScope)
Parameters
client
ClientapiScope
ApiScope
Returns
IsClientAllowedIdentityResourceAsync(Client, IdentityResource)
Determines if client is allowed access to the identity scope.
protected virtual Task<bool> IsClientAllowedIdentityResourceAsync(Client client, IdentityResource identity)
Parameters
client
Clientidentity
IdentityResource
Returns
IsClientAllowedOfflineAccessAsync(Client)
Validates if the client is allowed offline_access.
protected virtual Task<bool> IsClientAllowedOfflineAccessAsync(Client client)
Parameters
client
Client
Returns
ValidateRequestedResourcesAsync(ResourceValidationRequest)
public virtual Task<ResourceValidationResult> ValidateRequestedResourcesAsync(ResourceValidationRequest request)
Parameters
request
ResourceValidationRequest
Returns
ValidateScopeAsync(Client, Resources, ParsedScopeValue, ResourceValidationResult)
Validates that the requested scopes is contained in the store, and the client is allowed to request it.
protected virtual Task ValidateScopeAsync(Client client, Resources resourcesFromStore, ParsedScopeValue requestedScope, ResourceValidationResult result)
Parameters
client
ClientresourcesFromStore
ResourcesrequestedScope
ParsedScopeValueresult
ResourceValidationResult