Add Login and Authentication messages, use them in displayErrorOnStatus.
Clean up indentation of new code.