mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Fix SASL automatic/quiet modes...
This commit is contained in:
parent
6393523ffa
commit
9fb680d527
@ -600,12 +600,12 @@ ldap_int_sasl_bind(
|
||||
|
||||
if( flags != LDAP_SASL_QUIET ) {
|
||||
saslrc = sasl_getprop( ctx, SASL_USERNAME, (void **) &data );
|
||||
if( saslrc == SASL_OK ) {
|
||||
if( saslrc == SASL_OK && data && *data ) {
|
||||
fprintf( stderr, "SASL username: %s\n", data );
|
||||
}
|
||||
|
||||
saslrc = sasl_getprop( ctx, SASL_REALM, (void **) &data );
|
||||
if( saslrc == SASL_OK ) {
|
||||
if( saslrc == SASL_OK && data && *data ) {
|
||||
fprintf( stderr, "SASL realm: %s\n", data );
|
||||
}
|
||||
}
|
||||
|
@ -101,7 +101,9 @@ static int interaction(
|
||||
|
||||
if( dflt && !*dflt ) dflt = NULL;
|
||||
|
||||
if( flags != LDAP_SASL_INTERACTIVE && dflt ) {
|
||||
if( flags != LDAP_SASL_INTERACTIVE &&
|
||||
( dflt || interact->id == SASL_CB_USER ) )
|
||||
{
|
||||
goto use_default;
|
||||
}
|
||||
|
||||
@ -184,7 +186,7 @@ int lutil_sasl_interact(
|
||||
{
|
||||
sasl_interact_t *interact = in;
|
||||
|
||||
if( flags != LDAP_SASL_QUIET ) {
|
||||
if( flags == LDAP_SASL_INTERACTIVE ) {
|
||||
fputs( "SASL Interaction\n", stderr );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user