Made some changes for authentication.