Fixes for authentication.