added use of device authenticate_user!