SamlSubject Constructors

Definition

Initializes a new instance of the SamlSubject class.

Overloads

SamlSubject()

Initializes a new instance of the SamlSubject class.

SamlSubject(String, String, String)

Initializes a new instance of the SamlSubject class using the specified name, the domain in which the name resides, and the format the name is in.

SamlSubject(String, String, String, IEnumerable<String>, String, SecurityKeyIdentifier)

Initializes a new instance of the SamlSubject class using the specified name, the domain in which the name resides, the format the name is in, authentication protocols, additional authentication information, and a key identifier.

SamlSubject()

Initializes a new instance of the SamlSubject class.

public:
 SamlSubject();
public SamlSubject ();
Public Sub New ()

Remarks

This constructor initializes the IsReadOnly property to false.

Applies to

SamlSubject(String, String, String)

Initializes a new instance of the SamlSubject class using the specified name, the domain in which the name resides, and the format the name is in.

public:
 SamlSubject(System::String ^ nameFormat, System::String ^ nameQualifier, System::String ^ name);
public SamlSubject (string nameFormat, string nameQualifier, string name);
new System.IdentityModel.Tokens.SamlSubject : string * string * string -> System.IdentityModel.Tokens.SamlSubject
Public Sub New (nameFormat As String, nameQualifier As String, name As String)

Parameters

nameFormat
String

A URI reference that represents the format that the name parameter is in. Sets the NameFormat property.

nameQualifier
String

The domain in which the name parameter resides. Sets the NameQualifier property.

name
String

The subject name. Sets the Name property.

Exceptions

name is null or is Empty.

Remarks

Although the format used to specify a name is extensible, the following table lists the formats defined by the SAML specification.

Format Description
EmailNamespace A URI that states the subject of a SAML assertion is specified as an email address.
UserNameNamespace A URI that states the subject of a SAML assertion is specified using a Windows domain account.

Applies to

SamlSubject(String, String, String, IEnumerable<String>, String, SecurityKeyIdentifier)

Initializes a new instance of the SamlSubject class using the specified name, the domain in which the name resides, the format the name is in, authentication protocols, additional authentication information, and a key identifier.

public:
 SamlSubject(System::String ^ nameFormat, System::String ^ nameQualifier, System::String ^ name, System::Collections::Generic::IEnumerable<System::String ^> ^ confirmations, System::String ^ confirmationData, System::IdentityModel::Tokens::SecurityKeyIdentifier ^ securityKeyIdentifier);
public SamlSubject (string nameFormat, string nameQualifier, string name, System.Collections.Generic.IEnumerable<string> confirmations, string confirmationData, System.IdentityModel.Tokens.SecurityKeyIdentifier securityKeyIdentifier);
new System.IdentityModel.Tokens.SamlSubject : string * string * string * seq<string> * string * System.IdentityModel.Tokens.SecurityKeyIdentifier -> System.IdentityModel.Tokens.SamlSubject
Public Sub New (nameFormat As String, nameQualifier As String, name As String, confirmations As IEnumerable(Of String), confirmationData As String, securityKeyIdentifier As SecurityKeyIdentifier)

Parameters

nameFormat
String

A URI reference that represents the format that the name parameter is in. Sets the NameFormat property.

nameQualifier
String

The domain in which the name parameter resides. Sets the NameQualifier property.

name
String

The subject name. Sets the Name property.

confirmations
IEnumerable<String>

An IEnumerable<T> of type String that contains URI references that identify the protocols to authenticate the subject. Sets the ConfirmationMethods property.

confirmationData
String

Additional authentication information that can be used by authentication protocols. Sets the SubjectConfirmationData property.

securityKeyIdentifier
SecurityKeyIdentifier

A SecurityKeyIdentifier that provides access to a cryptographic key held by the subject of the SamlSecurityToken security token. Sets the KeyIdentifier property.

Exceptions

name is null or is Empty.

confirmations contains a null or Empty member.

-or-

confirmations does not contain any members and name is null or is Empty.

-or-

confirmations does not contain any members and confirmationData or securityKeyIdentifier are not null.

Remarks

The format used to specify a name for the name parameter is extensible; the following table lists the formats defined by the SAML specification.

Format Description
EmailNamespace A URI that states the subject of a SAML assertion is specified as an email address.
UserNameNamespace A URI that states the subject of a SAML assertion is specified using a Windows domain account.

The set of authentication protocols to specify for the confirmations parameter is extensible; however the following table lists the protocols defined by the SAML specification.

Protocol Description
HolderOfKey A URI that specifies that the recipient of a SamlSecurityToken security token should use the KeyIdentifier property to confirm that the SOAP message was sent by the SAML assertion's subject.
SenderVouches A URI that specifies that additional information is not available for a recipient of a SAML security token to confirm that the SOAP message was sent by the SAML assertion's subject.

Applies to