change the algorithm of login in