Log in/log out functionality and redirects for authorization.