I am using a custom STS for SP.The site is SAML token enabled with SSO implmentation. The logout is not working properly.How do i implement custom Signout .do i need to clear the SP session or clear cookies?
I've just tackled this exact task this morning. You'll need your Custom STS to keep track of the sites that are logged in, and in the wsignout1.0 handler, you'll need to go through the list and sign them out.
Full description of this method, a helper class to keep track of the RPs logged into, and code to add to your wsignout handler are all here:
I made one modification to the helper class though, I added a CleanUp method to remove the cookie that keeps track of the RPs once you're signed out:
And then, at the end if your signout handler, just call it. Here's my signout handler block:
Works like a charm. Remember to create an asp:Label called lblSignoutText and a div called SignOutLinks on your Default.aspx
The only thing you'll have to figure out yourself, is that each SharePoint site's logout link will need to be hidden, and you'll have to create your own signout link which points to:
(I was actually Googling for a clever way of doing this when I came across this question. Hope my answer helps!)