Class IdentityProvider
Provides Identity Provider functionality in the SSO browser profile.
Inherited Members
Namespace: ComponentSpace.SAML2.Profiles.SSOBrowser
Assembly: ComponentSpace.Saml2.dll
Syntax
public static class IdentityProvider
Remarks
Refer to the Profiles for the OASIS Security Assertion Markup Language (SAML) V2.0 specification for further details.
Methods
ReceiveArtifactByHTTPArtifact(HttpRequestBase, bool, out HTTPArtifact, out string)
Receives the artifact from the SP using HTTP artifact with the artifact being in a form or query string.
Declaration
public static void ReceiveArtifactByHTTPArtifact(HttpRequestBase httpRequest, bool artifactInForm, out HTTPArtifact httpArtifact, out string relayState)
Parameters
Type | Name | Description |
---|---|---|
HttpRequestBase | httpRequest | The HTTP request containing the artifact. |
bool | artifactInForm | If |
HTTPArtifact | httpArtifact | The returned artifact. |
string | relayState | The returned relay state or |
Exceptions
Type | Condition |
---|---|
SAMLProfileException | Thrown when the receive fails. |
ReceiveAuthnRequestByHTTPPost(HttpRequestBase, out XmlElement, out string)
Receives the authentication request from the SP using HTTP post.
Declaration
public static void ReceiveAuthnRequestByHTTPPost(HttpRequestBase httpRequest, out XmlElement authnRequest, out string relayState)
Parameters
Type | Name | Description |
---|---|---|
HttpRequestBase | httpRequest | The HTTP request containing the posted form. |
XmlElement | authnRequest | The returned authentication request message |
string | relayState | The returned relay state or |
Exceptions
Type | Condition |
---|---|
SAMLProfileException | Thrown when the receive fails. |
ReceiveAuthnRequestByHTTPRedirect(HttpRequestBase, out XmlElement, out string, out bool, AsymmetricAlgorithm)
Receives the authentication request from the SP using HTTP redirect.
Declaration
public static void ReceiveAuthnRequestByHTTPRedirect(HttpRequestBase httpRequest, out XmlElement authnRequest, out string relayState, out bool signed, AsymmetricAlgorithm key)
Parameters
Type | Name | Description |
---|---|---|
HttpRequestBase | httpRequest | The HTTP request containing the query string. |
XmlElement | authnRequest | The returned authentication request message |
string | relayState | The returned relay state or |
bool | signed | Indicates whether the SAML request is signed. |
AsymmetricAlgorithm | key | The key to verify the signature or |
Exceptions
Type | Condition |
---|---|
SAMLProfileException | Thrown when the receive fails. |
SendArtifactByHTTPArtifact(HttpResponseBase, string, HTTPArtifact, string, bool)
Sends an artifact to the SP using the HTTP artifact binding.
Declaration
public static void SendArtifactByHTTPArtifact(HttpResponseBase httpResponse, string spURL, HTTPArtifact httpArtifact, string relayState, bool sendArtifactInForm)
Parameters
Type | Name | Description |
---|---|---|
HttpResponseBase | httpResponse | The HTTP response that will send the artifact. |
string | spURL | The SP URL. |
HTTPArtifact | httpArtifact | The artifact. |
string | relayState | The relay state or |
bool | sendArtifactInForm | If |
Exceptions
Type | Condition |
---|---|
SAMLProfileException | Thrown when the send fails. |
SendSAMLResponseByHTTPPost(HttpResponseBase, string, XmlElement, string)
Sends the SAML response to the SP using HTTP post.
Declaration
public static void SendSAMLResponseByHTTPPost(HttpResponseBase httpResponse, string spURL, XmlElement samlResponse, string relayState)
Parameters
Type | Name | Description |
---|---|---|
HttpResponseBase | httpResponse | The HTTP response that will return the form to post. |
string | spURL | The SP URL. |
XmlElement | samlResponse | The SAML response. |
string | relayState | The relay state or |
Exceptions
Type | Condition |
---|---|
SAMLProfileException | Thrown when the send fails. |