#include <sasl/sasl.h>
int sasl_user_exists( sasl_conn_t *conn,
                      const char *service, const char *user_realm,
                      const char *user)
 
sasl_user_exists will check if a user exists on the server.
conn a connection context
service Service name or NULL (for service name of connection context)
user_realm Realm to check in or NULL (for default realm)
user User name to check for existence of.