Lines Matching defs:dn

223 	static char	dn[256], passwd[256];
227 getaline( dn, sizeof(dn), stdin,
229 if (( *authmethodp = atoi( dn )) == 3 ) {
238 getaline( dn, sizeof(dn), stdin, "re-bind dn? " );
239 strcat( dn, dnsuffix );
240 *dnp = dn;
242 if ( *authmethodp == LDAP_AUTH_SIMPLE && dn[0] != '\0' ) {
262 char passwd[64], dn[256], rdn[64], attr[64], value[256];
401 getaline( dn, sizeof(dn), stdin, "dn? " );
402 strcat( dn, dnsuffix );
407 if ((err = ldap_add_ext( ld, dn, attrs, NULL, NULL, &id )) != LDAP_SUCCESS )
413 if ( (id = ldap_add( ld, dn, attrs )) == -1 )
442 getaline( dn, sizeof(dn), stdin, "dn? " );
443 strcat( dn, dnsuffix );
445 if ( method == LDAP_AUTH_SIMPLE && dn[0] != '\0' )
451 if ( ldap_bind( ld, dn, passwd, method ) == -1 ) {
489 getaline( dn, sizeof(dn), stdin, "dn? " );
490 strcat( dn, dnsuffix );
492 if ( dn[0] != '\0' )
499 if ( ldap_bind_s( ld, dn, passwd, method ) !=
512 if ( ldap_sasl_cram_md5_bind_s(ld, dn, &cred, NULL, NULL) != LDAP_SUCCESS ){
520 if (ldap_sasl_bind_s(ld, dn, mechanism, &cred, NULL, NULL, &srvcrds ) != LDAP_SUCCESS){
529 getaline( dn, sizeof(dn), stdin, "dn? " );
530 strcat( dn, dnsuffix );
537 if ((err = ldap_compare_ext( ld, dn, attr, &bv, NULL, NULL, &id )) != LDAP_SUCCESS )
542 if ( (id = ldap_compare( ld, dn, attr, value )) == -1 )
561 case 'E': /* explode a dn */
562 getaline( line, sizeof(line), stdin, "dn? " );
582 getaline( dn, sizeof(dn), stdin, "dn? " );
583 strcat( dn, dnsuffix );
590 if ((err = ldap_modify_ext( ld, dn, mods, NULL, NULL, &id )) != LDAP_SUCCESS )
596 if ( (id = ldap_modify( ld, dn, mods )) == -1 )
602 getaline( dn, sizeof(dn), stdin, "dn? " );
603 strcat( dn, dnsuffix );
608 if ((err = ldap_rename(ld, dn, rdn, NULL, delrdn, NULL,NULL, &id)) != LDAP_SUCCESS){
615 if ( (id = ldap_modrdn( ld, dn, rdn, delrdn )) == -1 )
621 printf( "Possibilities: [modi]fy, [modr]dn\n" );
665 getaline( dn, sizeof(dn), stdin, "dn? " );
666 strcat( dn, dnsuffix );
668 if ((err = ldap_delete_ext( ld, dn, NULL, NULL, &id )) != LDAP_SUCCESS )
673 if ( (id = ldap_delete( ld, dn )) == -1 )
687 getaline( dn, sizeof(dn), stdin, "searchbase? " );
688 strcat( dn, dnsuffix );
703 if ( cldap_search_s( ld, dn, scope, filter, types,
730 if (( err = ldap_search_ext(ld, dn, scope, filter, types, attrsonly, NULL, NULL,
737 if (( id = ldap_search( ld, dn, scope, filter,
759 getaline( dn, sizeof(dn), stdin, "ufn? " );
760 strcat( dn, dnsuffix );
767 id = ldap_ufn_search_c( ld, dn, types,
771 id = ldap_ufn_search_s( ld, dn, types,
814 printf( "\t dn: <%s>\n", ludp->lud_dn );
839 case 'n': /* set dn suffix, for convenience */
993 printf( " [modi]fy [modr]dn [rem]ove\n" );
1000 printf( " [E]xplode dn [p]arse LDAP URL\n" );
1108 char *a, *dn, *ufn;
1118 dn = ldap_get_dn( ld, e );
1119 printf( "\tDN: %s\n", dn );
1121 ufn = ldap_dn2ufn( dn );
1123 free( dn );