changes to authentication from scratch