SecurityTokenHandler.ValidateToken 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
ValidateToken(String, TokenValidationParameters, SecurityToken) |
This must be overridden to validate a token passed as a string using TokenValidationParameters |
ValidateToken(XmlReader, TokenValidationParameters, SecurityToken) |
Reads and validates a token using a xmlReader and TokenValidationParameters |
ValidateToken(String, TokenValidationParameters, SecurityToken)
This must be overridden to validate a token passed as a string using TokenValidationParameters
public virtual System.Security.Claims.ClaimsPrincipal ValidateToken (string securityToken, Microsoft.IdentityModel.Tokens.TokenValidationParameters validationParameters, out Microsoft.IdentityModel.Tokens.SecurityToken validatedToken);
abstract member ValidateToken : string * Microsoft.IdentityModel.Tokens.TokenValidationParameters * SecurityToken -> System.Security.Claims.ClaimsPrincipal
override this.ValidateToken : string * Microsoft.IdentityModel.Tokens.TokenValidationParameters * SecurityToken -> System.Security.Claims.ClaimsPrincipal
Public Overridable Function ValidateToken (securityToken As String, validationParameters As TokenValidationParameters, ByRef validatedToken As SecurityToken) As ClaimsPrincipal
Parameters
- validationParameters
- TokenValidationParameters
The TokenValidationParameters to be used for validating the token.
- validatedToken
- SecurityToken
The token of type TokenType that was validated.
Returns
Implements
Applies to
ValidateToken(XmlReader, TokenValidationParameters, SecurityToken)
Reads and validates a token using a xmlReader and TokenValidationParameters
public virtual System.Security.Claims.ClaimsPrincipal ValidateToken (System.Xml.XmlReader reader, Microsoft.IdentityModel.Tokens.TokenValidationParameters validationParameters, out Microsoft.IdentityModel.Tokens.SecurityToken validatedToken);
abstract member ValidateToken : System.Xml.XmlReader * Microsoft.IdentityModel.Tokens.TokenValidationParameters * SecurityToken -> System.Security.Claims.ClaimsPrincipal
override this.ValidateToken : System.Xml.XmlReader * Microsoft.IdentityModel.Tokens.TokenValidationParameters * SecurityToken -> System.Security.Claims.ClaimsPrincipal
Public Overridable Function ValidateToken (reader As XmlReader, validationParameters As TokenValidationParameters, ByRef validatedToken As SecurityToken) As ClaimsPrincipal
Parameters
- validationParameters
- TokenValidationParameters
The TokenValidationParameters to be used for validating the token.
- validatedToken
- SecurityToken
The SecurityToken that was validated.