示例#1
0
        public static IDictionary <string, string> DecryptSessionObject(string sessionString)
        {
            IDictionary <string, string> localObject = new Dictionary <string, string>();

            if (!string.IsNullOrWhiteSpace(sessionString))
            {
                // get the decrypted text from session string
                var decrytText = SessionEncryption.DecryptCipherTextToPlainText(sessionString);
                // change the string
                localObject = (Dictionary <string, string>)StringToObject(decrytText);
            }
            return(localObject);
        }
示例#2
0
 public static int GetRoleIDFromSession()
 {
     return(GetInt(SessionEncryption.GetValueFromSession(SessionItemKey.RoleID)));
 }
示例#3
0
 public static string GetEamilAddressFromSession()
 {
     return(SessionEncryption.GetValueFromSession(SessionItemKey.EmailAddress));
 }
示例#4
0
 public static string GetUserNameFromSession()
 {
     return(SessionEncryption.GetValueFromSession(SessionItemKey.UserName));
 }
示例#5
0
 public static long GetUserIdFromSession()
 {
     return(GetLong(SessionEncryption.GetValueFromSession(SessionItemKey.UserId)));
 }