add the following functions:authtoen,user registration(not completed)