public ActionResult SessionTokenRaw()
        {
            var cookieHandler = FederatedAuthentication.SessionAuthenticationModule.CookieHandler;
            var cookieBytes = cookieHandler.Read();
            if (cookieBytes != null && cookieBytes.Length != 0)
            {
                var handler = new SessionSecurityTokenHandler();
                var sam = FederatedAuthentication.SessionAuthenticationModule;
                var sessionToken = sam.ReadSessionTokenFromCookie(cookieBytes);
                var sb = new StringBuilder(128);

                handler.WriteToken(XmlWriter.Create(sb, new XmlWriterSettings { OmitXmlDeclaration = true }), sessionToken);

                return new ContentResult
                {
                    ContentType = "text/xml",
                    Content = sb.ToString()
                };
            }

            return null;
        }