Adding support for authentication.