AuthenticationService::Logout Method ()

 

Clears the authentication ticket (cookie) in the browser.

Namespace:   System.Web.ApplicationServices
Assembly:  System.Web.Extensions (in System.Web.Extensions.dll)

public:
[OperationContractAttribute]
void Logout()

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.

System_CAPS_noteNote

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.

.NET Framework
Available since 3.5
Return to top
Show: