fixes authentication.