示例#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);
        }
示例#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);
        }
示例#3
0
 public SessionResult GetSession(string sessionKey)
 {
     return(ClientUtil.RequestSession(this._serverUrl, this._token, sessionKey));
 }