Complete the login and logout function.