" -p port port on LDAP server\n"
" -Q use SASL Quiet mode\n"
" -R realm SASL realm\n"
-" -U user SASL authentication identity (username)\n"
+" -U authcid SASL authentication identity\n"
" -v run in verbose mode (diagnostics to standard output)\n"
" -w passwd bind passwd (for simple authentication)\n"
" -W prompt for bind passwd\n"
" -x Simple authentication\n"
-" -X id SASL authorization identity (\"dn:<dn>\" or \"u:<user>\")\n"
+" -X authzid SASL authorization identity (\"dn:<dn>\" or \"u:<user>\")\n"
" -Y mech SASL mechanism\n"
" -Z Start TLS request (-ZZ to require successful response)\n"
, s );
{
char* p;
- for( p = optarg; *p == '\0'; p++ ) {
+ for( p = optarg; *p != '\0'; p++ ) {
*p = '\0';
}
}
{
char* p;
- for( p = optarg; *p == '\0'; p++ ) {
+ for( p = optarg; *p != '\0'; p++ ) {
*p = '\0';
}
}
{
char* p;
- for( p = optarg; *p == '\0'; p++ ) {
+ for( p = optarg; *p != '\0'; p++ ) {
*p = '\0';
}
}
if (want_bindpw && passwd.bv_val == NULL ) {
/* handle bind password */
- if( binddn != NULL ) {
- fprintf( stderr, "Bind DN: %s\n", binddn );
- }
passwd.bv_val = strdup( getpassphrase("Enter bind password: "));
passwd.bv_len = passwd.bv_val ? strlen( passwd.bv_val ) : 0;
}
}
if ( use_tls && ldap_start_tls_s( ld, NULL, NULL ) != LDAP_SUCCESS ) {
+ ldap_perror( ld, "ldap_start_tls" );
if ( use_tls > 1 ) {
- ldap_perror( ld, "ldap_start_tls" );
return( EXIT_FAILURE );
}
- fprintf( stderr, "WARNING: could not start TLS\n" );
}
if ( authmethod == LDAP_AUTH_SASL ) {
if( oldpw != NULL ) {
ber_printf( ber, "ts",
- LDAP_TAG_EXOP_X_MODIFY_PASSWD_NEW, oldpw );
+ LDAP_TAG_EXOP_X_MODIFY_PASSWD_OLD, oldpw );
free(oldpw);
}