Validators.ValidateTokenReplay Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
ValidateTokenReplay(Nullable<DateTime>, String, TokenValidationParameters) |
Validates if a token has been replayed. |
ValidateTokenReplay(String, Nullable<DateTime>, TokenValidationParameters) |
Validates if a token has been replayed. |
ValidateTokenReplay(Nullable<DateTime>, String, TokenValidationParameters)
Validates if a token has been replayed.
public static void ValidateTokenReplay (DateTime? expirationTime, string securityToken, Microsoft.IdentityModel.Tokens.TokenValidationParameters validationParameters);
static member ValidateTokenReplay : Nullable<DateTime> * string * Microsoft.IdentityModel.Tokens.TokenValidationParameters -> unit
Public Shared Sub ValidateTokenReplay (expirationTime As Nullable(Of DateTime), securityToken As String, validationParameters As TokenValidationParameters)
Parameters
- securityToken
- String
The SecurityToken being validated.
- validationParameters
- TokenValidationParameters
TokenValidationParameters required for validation.
Exceptions
If 'validationParameters' is null or whitespace.
If TokenReplayCache is not null and expirationTime.HasValue is false. When a TokenReplayCache is set, tokens require an expiration time.
If the 'securityToken' is found in the cache.
If the 'securityToken' could not be added to the TokenReplayCache.
Applies to
ValidateTokenReplay(String, Nullable<DateTime>, TokenValidationParameters)
Validates if a token has been replayed.
public static void ValidateTokenReplay (string securityToken, DateTime? expirationTime, Microsoft.IdentityModel.Tokens.TokenValidationParameters validationParameters);
static member ValidateTokenReplay : string * Nullable<DateTime> * Microsoft.IdentityModel.Tokens.TokenValidationParameters -> unit
Public Shared Sub ValidateTokenReplay (securityToken As String, expirationTime As Nullable(Of DateTime), validationParameters As TokenValidationParameters)
Parameters
- securityToken
- String
The SecurityToken being validated.
- validationParameters
- TokenValidationParameters
TokenValidationParameters required for validation.
Exceptions
If 'validationParameters' is null or whitespace.
If TokenReplayCache is not null and expirationTime.HasValue is false. When a TokenReplayCache is set, tokens require an expiration time.
If the 'securityToken' is found in the cache.
If the 'securityToken' could not be added to the TokenReplayCache.