Added user authentication and new user registration