Exemplo n.º 1
0
        public static bool ChangePassword(BOM.User user, String pass)
        {
            String encrypted = Encrypted.GetEncrypted(pass);

            if (DAL.AuthenticationDal.UpdatePassword(user, encrypted))
            {
                String res = BOL.SendMail(user.email, "password for watershed is updated", "updated password is: " + pass);
                return(true);
            }

            return(false);
        }
Exemplo n.º 2
0
        public static String ForgetPassword(BOM.User user)
        {
            BOM.User users = DAL.AuthenticationDal.checkEmail(user);
            if (null == users)
            {
                return("fail");
            }

            String newpass = BOL.RandomNum();

            if (ChangePassword(users, newpass))
            {
                return("success");
            }

            return("fail");
        }
Exemplo n.º 3
0
 public System.Threading.Tasks.Task <bool> doRegisterAsync(BOM.User user)
 {
     return(base.Channel.doRegisterAsync(user));
 }
Exemplo n.º 4
0
 public bool doRegister(BOM.User user)
 {
     return(base.Channel.doRegister(user));
 }
Exemplo n.º 5
0
 public System.Threading.Tasks.Task <BOM.User> doLoginAsync(BOM.User user)
 {
     return(base.Channel.doLoginAsync(user));
 }
Exemplo n.º 6
0
 public BOM.User doLogin(BOM.User user)
 {
     return(base.Channel.doLogin(user));
 }
Exemplo n.º 7
0
 public static BOM.User Login(BOM.User user)
 {
     user.password = Encrypted.GetEncrypted(user.password);
     //user.ConfirmPassword = Encrypted.GetEncrypted(user.ConfirmPassword);
     return(DAL.AuthenticationDal.LoginDal(user));
 }
Exemplo n.º 8
0
 public static Boolean Register(BOM.User user)
 {
     user.password        = Encrypted.GetEncrypted(user.password);
     user.ConfirmPassword = Encrypted.GetEncrypted(user.ConfirmPassword);
     return(DAL.AuthenticationDal.RegisterDal(user));
 }
Exemplo n.º 9
0
 public System.Threading.Tasks.Task <bool> ChangePasswordAsync(BOM.User user, string pass)
 {
     return(base.Channel.ChangePasswordAsync(user, pass));
 }
Exemplo n.º 10
0
 public bool ChangePassword(BOM.User user, string pass)
 {
     return(base.Channel.ChangePassword(user, pass));
 }
Exemplo n.º 11
0
 public System.Threading.Tasks.Task <string> ForgetPasswordAsync(BOM.User users)
 {
     return(base.Channel.ForgetPasswordAsync(users));
 }
Exemplo n.º 12
0
 public string ForgetPassword(BOM.User users)
 {
     return(base.Channel.ForgetPassword(users));
 }