WSFederationAuthenticationModule.FederatedSignOut Method (Uri, Uri)

.NET Framework (current version)
 

Signs out at the specified security token service (STS) by using the WS-Federation protocol.

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

public static void FederatedSignOut(
	Uri signOutUrl,
	Uri replyUrl
)

Parameters

signOutUrl
Type: System.Uri

The URL of the STS to receive the WS-Federation sign-out request message. Cannot be null.

replyUrl
Type: System.Uri

The URL to be sent as the wreply value in the sign-out request message.

Exception Condition
ArgumentException

signOutUrl is not null and is not an absolute URI.

-or-

replyUrl is not null and is not an absolute URI.

InvalidOperationException

signOutUrl is null.

Call this method to send a WS-Federation sign-out request message to the specified STS. You can optionally supply a value for the wreply parameter in the sign-out request.

The method does the following:

  1. Creates a WS-Federation sign-out request message by using the specified parameters.

  2. Calls the SessionAuthenticationModule.DeleteSessionTokenCookie method on the SAM to delete the session cookie.

  3. Redirects to the STS using the sign-out request message from the first step.

None of the sign-out events: SigningOut, SignedOut, or SignOutError are raised by this method. To delete the session without sending a sign-out request message to the STS, call one of the overloaded SignOut methods.

System_CAPS_noteNote

To perform passive sign-out by using the session token, the module relies on a value that was stored in the SessionSecurityToken.Context property during sign-in, for more information, see the GetSessionTokenContext method.

.NET Framework
Available since 4.5
Return to top
Show: