.NET Framework Bookmark and Share   
 index > Claims based access platform (CBA), code-named Geneva > Not storing custom claims in session
 

Not storing custom claims in session

I'm following the FederationForWebApps-VS2008 sample from the Geneva Beta 2 SDK. I'm trying to implement my own STS for an intranet. The STS is hosted in the same web app as the intranet. I have everything working great except for after my user is authenticated and a cookie is saved with the security token, none of my custom claims issued by my STS get saved.

The process goes like this: The user requests a page (http://intranet/secure/index. If the user doesn't have the required claim, a security exception is thrown. The web app catches the security exception and if the user is not authenticated (IsAuthenticated == false), they are redirected to the STS (http://intranet/sts). The STS checks if the user is authenticated and if not redirects them to a login page (http://intranet/login). After authenticated the login page redirects (with all the querystring parameters) back to the STS (http://intranet/sts). The STS issues the claims and redirects back to the requested page (http://intranet/secure/index). The user can now access the page and all the claims on the IClaimsIdentity from my STS are present. If the user refreshes the page, they are denied access because the claims I set in my STS are no longer present on the IClaimsIdentity. I thought the SessionAuthenticationModule is supposed to take care of writing the security token as a cookie with all the claims, but it doesn't appear to be doing that.

I have the SessionAuthenticationModule and WSFederatedAuthenticationModule set up in the web.config. Could someone please shed some light on what I might be doing wrong?
awilinsk
Nevermind I found my answer. You have to set the requireSSL attribute on the cookieHandler element to false in the web.config if you are not using SSL.
  • Marked As Answer byawilinsk Wednesday, September 09, 2009 8:24 PM
  •  
awilinsk
Nevermind I found my answer. You have to set the requireSSL attribute on the cookieHandler element to false in the web.config if you are not using SSL.
  • Marked As Answer byawilinsk Wednesday, September 09, 2009 8:24 PM
  •  
awilinsk

You can use google to search for other answers

Custom Search

More Threads

• Geneva Server client certificate validation
• Custom STS hosted on IIS 7.0 - mex endpoint - 400 error
• Symmetric proof-of-procession key
• Where can I download Beta 1?
• July CTP throwing an error and webrole not starting
• HTTP Error 401.2 - Unauthorized
• Certificates used in Identity Training Kit
• Saml 2.0 Serialization Issue
• STS and Forms Authentication
• ASP.NET MVC SecurityToken Post Back error