SamlSerializer.LoadAssertion Method (XmlDictionaryReader, SecurityTokenSerializer, SecurityTokenResolver)

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Reads a SAML assertion from the specified XML reader.

Namespace:   System.IdentityModel.Tokens
Assembly:  System.IdentityModel (in System.IdentityModel.dll)

public virtual SamlAssertion LoadAssertion(
	XmlDictionaryReader reader,
	SecurityTokenSerializer keyInfoSerializer,
	SecurityTokenResolver outOfBandTokenResolver
)

Parameters

reader
Type: System.Xml.XmlDictionaryReader

An XmlDictionaryReader to read the SAML assertion.

keyInfoSerializer
Type: System.IdentityModel.Selectors.SecurityTokenSerializer

A SecurityTokenSerializer that reads the KeyInfo clause of the digital signature.

outOfBandTokenResolver
Type: System.IdentityModel.Selectors.SecurityTokenResolver

A SecurityTokenResolver that determines the security token that created the digital signature.

Return Value

Type: System.IdentityModel.Tokens.SamlAssertion

A SamlAssertion that represents the SAML assertion.

Exception Condition
ArgumentNullException

reader is null

A SAML assertion is contained within a <saml:Assertion> element.

The ReadToken(XmlReader, SecurityTokenSerializer, SecurityTokenResolver) method calls the LoadAssertion(XmlDictionaryReader, SecurityTokenSerializer, SecurityTokenResolver) method to read the SAML assertion.

.NET Framework
Available since 3.0
Return to top
Show: