Adding Login and Logout functionality.