Add listener for authentication