Updated for SASL authentication.