Skip to main content

TokenValidationContext Class

Abblix.Oidc.Server

Abblix.Oidc.Server.Endpoints.Token.Validation

TokenValidationContext Class

Encapsulates the context required for validating token requests, including client and authorization grant details.

public record TokenValidationContext : System.IEquatable<Abblix.Oidc.Server.Endpoints.Token.Validation.TokenValidationContext>

Inheritance System.Object → TokenValidationContext

Implements System.IEquatable<TokenValidationContext>

Constructors

TokenValidationContext(TokenRequest, ClientRequest) Constructor

Encapsulates the context required for validating token requests, including client and authorization grant details.

public TokenValidationContext(Abblix.Oidc.Server.Model.TokenRequest Request, Abblix.Oidc.Server.Model.ClientRequest ClientRequest);

Parameters

Request TokenRequest
ClientRequest ClientRequest

Properties

TokenValidationContext.AuthorizedGrant Property

Represents the result of an authorized grant, containing both the session and context of the authorization. This object is essential for ensuring that the grant is valid and for extracting any additional information needed for token generation.

public Abblix.Oidc.Server.Endpoints.Token.Interfaces.AuthorizedGrant AuthorizedGrant { get; set; }

Property Value

AuthorizedGrant

TokenValidationContext.ClientInfo Property

Information about the client making the request, derived from the client authentication process.

public Abblix.Oidc.Server.Features.ClientInformation.ClientInfo ClientInfo { get; set; }

Property Value

ClientInfo

Exceptions

System.InvalidOperationException
Thrown when trying to access this property before it is set.

TokenValidationContext.ProofKeyThumbprint Property

RFC 7638 base64url-encoded JWK thumbprint of the DPoP proof-of-possession key (RFC 9449 §6.1) populated by the DPoP validator step when a valid proof accompanies the request. Surfaces to the processor so the issued access token can carry cnf.jkt. null when no proof was presented or DPoP is not in use.

public string? ProofKeyThumbprint { get; set; }

Property Value

System.String

TokenValidationContext.Resources Property

Specifies additional resources that the client has requested or that have been included in the authorization. These definitions provide context on the resources that are accessible with the issued token, enhancing the token's utility for fine-grained access control.

public Abblix.Oidc.Server.Common.Constants.ResourceDefinition[] Resources { get; set; }

Property Value

ResourceDefinition[]

TokenValidationContext.Scope Property

Defines the scope of access requested or authorized. This array of scope definitions helps in determining the extent of access granted to the client and any constraints or conditions applied to the token.

public Abblix.Oidc.Server.Common.Constants.ScopeDefinition[] Scope { get; set; }

Property Value

ScopeDefinition[]