Class PushedAuthorizationRequestValidator
- Namespace
- Fdyay.IdentityServer.Validation
- Assembly
- Fdyay.IdentityServer.AspNetCore.dll
Duende's default pushed authorization request validator.
public class PushedAuthorizationRequestValidator : IPushedAuthorizationRequestValidator
- Inheritance
-
PushedAuthorizationRequestValidator
- Implements
- Inherited Members
Remarks
In the ASP.NET Core assembly rather than with its interface, because the DPoP proof is checked against this endpoint's URL, read off the request, and the request object is resolved by this assembly's request object validator.
Constructors
PushedAuthorizationRequestValidator(IAuthorizeRequestValidator, IRequestObjectValidator, IDPoPProofValidator, IHttpContextAccessor, IOptions<IdentityServerOptions>)
A validator whose pushes carry no issuer: the constructor before 0.155.0, kept so no host's build breaks.
public PushedAuthorizationRequestValidator(IAuthorizeRequestValidator authorizeRequests, IRequestObjectValidator requestObjects, IDPoPProofValidator dpop, IHttpContextAccessor httpContextAccessor, IOptions<IdentityServerOptions> options)
Parameters
authorizeRequestsIAuthorizeRequestValidatorThe authorize request validator, which every push must pass.
requestObjectsIRequestObjectValidatorResolves a pushed request object.
dpopIDPoPProofValidatorValidates a proof pushed with the request.
httpContextAccessorIHttpContextAccessorThe push in flight, for the proof's URL.
optionsIOptions<IdentityServerOptions>This server's options.
PushedAuthorizationRequestValidator(IAuthorizeRequestValidator, IRequestObjectValidator, IDPoPProofValidator, IHttpContextAccessor, IOptions<IdentityServerOptions>, IIssuerNameService)
A validator whose pushes carry the issuer they were made to; the one the container builds.
public PushedAuthorizationRequestValidator(IAuthorizeRequestValidator authorizeRequests, IRequestObjectValidator requestObjects, IDPoPProofValidator dpop, IHttpContextAccessor httpContextAccessor, IOptions<IdentityServerOptions> options, IIssuerNameService issuers)
Parameters
authorizeRequestsIAuthorizeRequestValidatorThe authorize request validator, which every push must pass.
requestObjectsIRequestObjectValidatorResolves a pushed request object.
dpopIDPoPProofValidatorValidates a proof pushed with the request.
httpContextAccessorIHttpContextAccessorThe push in flight, for the proof's URL and the issuer.
optionsIOptions<IdentityServerOptions>This server's options.
issuersIIssuerNameServiceThe issuer the push is made to, for IssuerName.
Remarks
An overload rather than an optional parameter on the constructor above, which would change that constructor's signature and break a host compiled against it.
Methods
ValidateAsync(PushedAuthorizationRequestValidationContext, CancellationToken)
Validates a pushed authorization request as IPushedAuthorizationRequestValidator describes; a refusal is a result carrying the error, not an exception.
public virtual Task<PushedAuthorizationValidationResult> ValidateAsync(PushedAuthorizationRequestValidationContext context, CancellationToken ct)
Parameters
contextPushedAuthorizationRequestValidationContextThe client, its pushed parameters, and any DPoP proof pushed with them.
ctCancellationTokenCancels the validation.
Returns
- Task<PushedAuthorizationValidationResult>
The validated request, or the error the client is answered with.
Exceptions
- ArgumentNullException
contextis null.