AudienceValidationError Class

Definition

Represents a validation error when the SecurityToken audience is not valid. If available, the audiences from the SecurityToken are stored in TokenAudiences. Valid audiences are stored in ValidAudiences.

public class AudienceValidationError : Microsoft.IdentityModel.Tokens.Experimental.ValidationError
type AudienceValidationError = class
    inherit ValidationError
Public Class AudienceValidationError
Inherits ValidationError
Inheritance
AudienceValidationError

Constructors

Name Description
AudienceValidationError(MessageDetail, ValidationFailureType, StackFrame, IList<String>, IList<String>, Exception)

Initializes a new instance of AudienceValidationError.

AudienceValidationError(MessageDetail, ValidationFailureType, StackFrame, IList<String>, IList<String>)

Initializes a new instance of AudienceValidationError.

Properties

Name Description
Exception

Gets or sets the exception associated with the ValidationError.

(Inherited from ValidationError)
FailureType

Gets the type of validation failure that occurred.

(Inherited from ValidationError)
InnerException

Gets the inner exception that occurred.

(Inherited from ValidationError)
Message

Gets the message that contains details of the error.

(Inherited from ValidationError)
StackFrames

Gets the stack frames where the exception occurred.

(Inherited from ValidationError)
TokenAudiences

The audiences that were in the token.

ValidAudiences

The audiences that were expected.

Methods

Name Description
AddCurrentStackFrame(String, Int32, Int32)

Adds the current stack frame to the list of stack frames and returns the updated object. If there is no cache entry for the given file path and line number, a new stack frame is created and added to the cache.

(Inherited from ValidationError)
AddStackFrame(StackFrame)

Adds a stack frame to the list of stack frames and returns the updated object.

(Inherited from ValidationError)
GetException()

Creates an instance of an SecurityTokenInvalidAudienceException.

Applies to