AuthenticationService.Logout Method

Definition

Clears the authentication ticket (cookie) in the browser.

public:
 void Logout();
[System.ServiceModel.OperationContract]
public void Logout ();
[<System.ServiceModel.OperationContract>]
member this.Logout : unit -> unit
Public Sub Logout ()
Attributes

Remarks

The Logout method clears the authentication cookie from the browser's cookie collection. The user must log in again to be authenticated.

The AuthenticationService class does not store information on the server about which authentication tickets have been cleared.

Note

Do not call the Logout method from code that is executing on the Web server. You call the Logout method only as part of a WCF service. For more information, see ASP.NET Authentication.

Applies to

See also