Beispiel #1
0
        public SsoResult Login(string user, string pwd)
        {
            SsoResult result = ClientUtil.LoginRequest(this._serverUrl, this._token, user, pwd);

            if (result.Result && !string.IsNullOrEmpty(result.Message))
            {
                string oldMsg = result.Message;
                try
                {
                    result.Message = SsoUtil.DecodeBase64(result.Message);
                }
                catch
                {
                    result.Message = oldMsg;
                }
            }
            return(result);
        }
Beispiel #2
0
        public SsoResult Logout(string sessionKey)
        {
            SsoResult result = ClientUtil.LogoutRequest(this._serverUrl, this._token, sessionKey);

            if (result.Result && !string.IsNullOrEmpty(result.Message))
            {
                string oldMsg = result.Message;
                try
                {
                    result.Message = SsoUtil.DecodeBase64(result.Message);
                }
                catch
                {
                    result.Message = oldMsg;
                }
            }
            return(result);
        }
Beispiel #3
0
 public SessionResult GetSession(string sessionKey)
 {
     return(ClientUtil.RequestSession(this._serverUrl, this._token, sessionKey));
 }