reworked Authentication