Пример #1
0
        public bool SSO_InternalKeepAlive()
        {
            var    ttlsession = getSession();
            var    sessionID  = GetCurrentSessionID();
            string userID     = null;

            if (ttlsession != null && ttlsession.clientID != null)
            {
                userID = ttlsession.clientID;
            }

            if (sessionID != null && userID != null)
            {
                if (ttlsession != null && ttlsession.clientID != null && ttlsession.sessionID != null)
                {
                    // TODO: KEEP ALIVE TTL SHOULD BLOCK LOGIN...
                    new SessionController().keepalive_ttl_internal(ttlsession.clientID, ttlsession.sessionID);
                }

                SessionController.TryKeepaliveSessionLogin(sessionID, userID);

                if (Session["jsessionID"] != null)
                {
                    string jsessionID        = (string)Session["jsessionID"];
                    var    sessionController = new SessionController();
                    bool   success           = sessionController.keepAliveQPI(jsessionID);
                    Session["jsessionIDkeepAlive"] = success;
                    return(success);
                }
            }
            return(false);
        }
Пример #2
0
        public bool InternalKeepAlive()
        {
            Session["keepaliveTime"] = DateTime.Now;

            if (Session["jsessionID"] != null)
            {
                string jsessionID        = (string)Session["jsessionID"];
                var    sessionController = new SessionController();
                bool   success           = sessionController.keepAliveQPI(jsessionID);
                Session["jsessionIDkeepAlive"] = success;
                return(success);
            }
            return(false);
        }