void vortex_sasl_start_auth_sync ( VortexConnection connection,
const char *  profile,
VortexStatus status,
char **  status_message 

Perform SASL negotiation in a synchronous mode (blocking the caller until process finish).

This function does the same like vortex_sasl_start_auth but in a blocking manner. Check documentation this this function at vortex_sasl_start_auth.

Here is an example:

 // some variable declaration for SASL status
 VortexStatus   status;
 char         * status_message;
 // set required properties
 vortex_sasl_set_propertie (connection, VORTEX_SASL_AUTH_ID,  
                            "bob", NULL);
 vortex_sasl_set_propertie (connection, VORTEX_SASL_PASSWORD, 
                            "secret", NULL);
 // begin SASL negotiation
 vortex_sasl_start_auth_sync (connection, VORTEX_SASL_CRAM_MD5,
                              &status, &status_message);
 // write out error
 switch (status) {
 case VortexOk:
        printf ("OK: message reported: %s\n", status_message);
 case VortexError:
        printf ("FAIL: message reported: %s\n", status_message);

See Using SASL at client side for a detailed explanation about SASL support inside Vortex for the client side.

connection The connection where the SASL negotiation will take place.
profile The SASL profile selected.
status A reference to a VortexStatus variable to notify caller SASL finish status.
status_message A reference to notify the caller a textual diagnostic about SASL finish status.