more logic for authentication with the Front End.