Aller au contenu
Abblix
Cette page n'a pas encore été traduite.

IJsonWebTokenValidator Interface

Defines the contract for a service that validates JSON Web Tokens (JWTs).

C#
public interface IJsonWebTokenValidator

Properties

IJsonWebTokenValidator.EncryptionAlgorithmsSupported Property

Indicates which JWE key-management algorithms (the alg header values, e.g. "RSA-OAEP-256") the validator can use to decrypt incoming encrypted JWTs, such as JWE-wrapped request objects.

C#
System.Collections.Generic.IEnumerable<string> EncryptionAlgorithmsSupported { get; }

Property Value

System.Collections.Generic.IEnumerable<System.String>

IJsonWebTokenValidator.EncryptionMethodsSupported Property

Indicates which JWE content-encryption algorithms (the enc header values, e.g. "A256GCM") the validator can use to decrypt incoming encrypted JWTs, such as JWE-wrapped request objects.

C#
System.Collections.Generic.IEnumerable<string> EncryptionMethodsSupported { get; }

Property Value

System.Collections.Generic.IEnumerable<System.String>

IJsonWebTokenValidator.SigningAlgorithmsSupported Property

Indicates which algorithms are accepted by the validator for verifying the signatures of incoming JWTs, ensuring that only tokens signed with recognized and secure algorithms are considered valid.

C#
System.Collections.Generic.IEnumerable<string> SigningAlgorithmsSupported { get; }

Property Value

System.Collections.Generic.IEnumerable<System.String>

Methods

IJsonWebTokenValidator.ValidateAsync(string, ValidationParameters) Method

Asynchronously validates a JWT against a set of specified parameters.

C#
System.Threading.Tasks.Task<Abblix.Utils.Result<Abblix.Jwt.JsonWebToken,Abblix.Jwt.JwtValidationError>> ValidateAsync(string jwt, Abblix.Jwt.ValidationParameters parameters);

Parameters

jwt System.String

The JWT as a string to be validated.

parameters ValidationParameters

The parameters against which the JWT will be validated.

Returns

System.Threading.Tasks.Task<Abblix.Utils.Result<JsonWebToken,JwtValidationError>>
A Task representing the asynchronous validation operation, which yields a Result containing either a validated JsonWebToken or a JwtValidationError.