lderr = op_ldap_add( ri, re, errmsg );
if ( lderr != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( " ldap_op", LDAP_LEVEL_ERR, "do_ldap: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_ldap: "
"Error: ldap_add_s failed adding \"%s\": %s\n",
*errmsg ? *errmsg : ldap_err2string( lderr ), re->re_dn ));
#else
lderr = op_ldap_modify( ri, re, errmsg );
if ( lderr != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( " ldap_op", LDAP_LEVEL_ERR, "do_ldap: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_ldap: "
"Error: ldap_modify_s failed modifying \"%s\": %s\n",
*errmsg ? *errmsg : ldap_err2string( lderr ), re->re_dn ));
#else
lderr = op_ldap_delete( ri, re, errmsg );
if ( lderr != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( " ldap_op", LDAP_LEVEL_ERR, "do_ldap: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_ldap: "
"Error: ldap_delete_s failed deleting \"%s\": %s\n",
*errmsg ? *errmsg : ldap_err2string( lderr ), re->re_dn ));
#else
lderr = op_ldap_modrdn( ri, re, errmsg );
if ( lderr != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( " ldap_op", LDAP_LEVEL_ERR, "do_ldap: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_ldap: "
"Error: ldap_modrdn_s failed modifying %s: %s\n",
*errmsg ? *errmsg : ldap_err2string( lderr ), re->re_dn ));
#else
default:
#ifdef NEW_LOGGING
- LDAP_LOG (( " ldap_op", LDAP_LEVEL_ERR, "do_ldap: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_ldap: "
"Error: bad op \"%d\", dn = \"%s\"\n",
re->re_changetype, re->re_dn ));
#else
/* Perform the operation */
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ARGS,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ARGS,
"op_ldap_add: replica %s:%d - add dn \"%s\"\n",
ri->ri_hostname, ri->ri_port, re->re_dn ));
#else
} else {
*errmsg = "No modifications to do";
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_add: Error: no mods to do (%s)!\n", re->re_dn ));
#else
Debug( LDAP_DEBUG_ANY,
if ( re->re_mods == NULL ) {
*errmsg = "No arguments given";
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modify: Error: no arguments\n" ));
#else
Debug( LDAP_DEBUG_ANY, "Error: op_ldap_modify: no arguments\n",
default:
if ( state == AWAITING_OP ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modify: Error: unknown mod type \"%s\"\n", type ));
#else
Debug( LDAP_DEBUG_ANY,
*/
if ( strcasecmp( type, ldm->mod_type )) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modify: Error: "
"malformed modify op, %s: %s (expecting \"%s\")\n",
type, value, ldm->mod_type ));
if ( nops > 0 ) {
/* Actually perform the LDAP operation */
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_DETAIL1,
+ LDAP_LOG (( "operation", LDAP_LEVEL_DETAIL1,
"op_ldap_modify: replica %s:%d - modify dn \"%s\"\n",
ri->ri_hostname, ri->ri_port, re->re_dn ));
#else
int rc;
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ARGS,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ARGS,
"op_ldap_delete: replica %s:%d - delete dn \"%s\"\n",
ri->ri_hostname, ri->ri_port, re->re_dn ));
#else
if ( re->re_mods == NULL ) {
*errmsg = "No arguments given";
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: no arguments\n" ));
#else
Debug( LDAP_DEBUG_ANY, "Error: op_ldap_modrdn: no arguments\n",
if ( !strcmp( mi[ i ].mi_type, T_NEWRDNSTR )) {
if( state & GOT_NEWRDN ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: multiple newrdn arg \"%s\"\n",
mi[ i ].mi_val ));
#else
} else if ( !strcmp( mi[ i ].mi_type, T_DELOLDRDNSTR )) {
if( state & GOT_DELOLDRDN ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: multiple deleteoldrdn arg \"%s\"\n",
mi[ i ].mi_val ));
#else
drdnflag = 1;
} else {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: bad deleteoldrdn arg \"%s\"\n",
mi[ i ].mi_val ));
#else
} else if ( !strcmp( mi[ i ].mi_type, T_NEWSUPSTR )) {
if( state & GOT_NEWSUP ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: multiple newsuperior arg \"%s\"\n",
mi[ i ].mi_val ));
#else
} else {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: bad type \"%s\"\n",
mi[ i ].mi_type ));
#else
*/
if ( !GOT_ALL_MODDN(state) ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"op_ldap_modrdn: Error: missing arguments\n" ));
#else
Debug( LDAP_DEBUG_ANY, "Error: op_ldap_modrdn: missing arguments\n",
snprintf( buf2, buf2len, "(\"%s\" -> \"%s\")", re->re_dn, mi->mi_val );
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ARGS,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ARGS,
"op_ldap_modrdn: replica %s - modify rdn %s (flag: %d)\n",
buf, buf2, drdnflag ));
#else
rc = ldap_unbind( ri->ri_ldp );
if ( rc != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"do_unbind: ldap_unbind failed for %s:%d: %s\n",
ri->ri_hostname, ri->ri_port, ldap_err2string( rc ) ));
#else
if ( ri == NULL ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: null ri ptr\n" ));
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: null ri ptr\n" ));
#else
Debug( LDAP_DEBUG_ANY, "Error: do_bind: null ri ptr\n", 0, 0, 0 );
#endif
ldrc = ldap_unbind( ri->ri_ldp );
if ( ldrc != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"do_bind: ldap_unbind failed: %s\n", ldap_err2string( ldrc ) ));
#else
Debug( LDAP_DEBUG_ANY,
}
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ARGS,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ARGS,
"do_bind: Initializing session to %s:%d\n",
ri->ri_hostname, ri->ri_port ));
#else
ri->ri_ldp = ldap_init( ri->ri_hostname, ri->ri_port );
if ( ri->ri_ldp == NULL ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR,
"do_bind: ldap_init (%s, %d) failed: %s\n",
ri->ri_hostname, ri->ri_port, sys_errlist[ errno ] ));
#else
if( err != LDAP_OPT_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: ",
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: ",
"Error: ldap_set_option(%s, LDAP_OPT_VERSION, 3) failed!\n",
ri->ri_hostname ));
#else
if( err != LDAP_OPT_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: ",
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: ",
"Error: ldap_set_option(%s, REFERRALS, OFF) failed!\n",
ri->ri_hostname ));
#else
if( err != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: ",
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: ",
"%s: ldap_start_tls failed: %s (%d)\n",
ri->ri_tls == TLS_CRITICAL ? "Error" : "Warning",
ldap_err2string( err ), err ));
* Bind with a plaintext password.
*/
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ARGS,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ARGS,
"do_bind: bind to %s:%d as %s (simple)\n",
ri->ri_hostname, ri->ri_port, ri->ri_bind_dn ));
#else
ri->ri_password );
if ( ldrc != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: "
"Error: ldap_simple_bind_s for %s:%d failed: %s\n",
ri->ri_hostname, ri->ri_port, ldap_err2string( ldrc ) ));
#else
case AUTH_SASL:
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ARGS,
+ LDAP_LOG (( "operation", LDAP_LEVEL_ARGS,
"do_bind: bind to %s as %s via %s (SASL)\n",
ri->ri_hostname, ri->ri_authcId, ri->ri_saslmech ));
#else
if( err != LDAP_OPT_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: "
"Error: ldap_set_option(%s,SECPROPS,\"%s\") failed!\n",
ri->ri_hostname, ri->ri_secprops ));
#else
LDAP_SASL_QUIET, lutil_sasl_interact, defaults );
if ( ldrc != LDAP_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: "
"Error: LDAP SASL for %s:%d failed: %s\n",
ri->ri_hostname, ri->ri_port, ldap_err2string( ldrc ) ));
#else
break;
#else
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: "
"Error: do_bind: SASL not supported %s:%d\n",
ri->ri_hostname, ri->ri_port ));
#else
default:
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: "
"Error: do_bind: unknown auth type \"%d\" for %s:%d\n",
ri->ri_bind_method, ri->ri_hostname, ri->ri_port ));
#else
if( err != LDAP_OPT_SUCCESS ) {
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_ERR, "do_bind: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_ERR, "do_bind: "
"ldap_set_option(%s, SERVER_CONTROLS, ManageDSAit) failed!\n",
ri->ri_hostname ));
#else
for ( i = 0; ldmarr[ i ] != NULL; i++ ) {
ldm = ldmarr[ i ];
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_INFO, "dump_ldm_array: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_INFO, "dump_ldm_array: "
"Trace (%ld): *** ldmarr[ %d ] contents:\n",
(long) getpid(), i ));
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_INFO, "dump_ldm_array: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_INFO, "dump_ldm_array: "
"Trace (%ld): *** ldm->mod_op: %d\n",
(long) getpid(), ldm->mod_op ));
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_INFO, "dump_ldm_array: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_INFO, "dump_ldm_array: "
"Trace (%ld): *** ldm->mod_type: %s\n",
(long) getpid(), ldm->mod_type ));
#else
sprintf( msgbuf, "***** bv[ %d ] len = %ld, val = <%s>",
j, b->bv_len, b->bv_val );
#ifdef NEW_LOGGING
- LDAP_LOG (( "ldap_op", LDAP_LEVEL_INFO, "dump_ldm_array: "
+ LDAP_LOG (( "operation", LDAP_LEVEL_INFO, "dump_ldm_array: "
"Trace (%ld):%s\n", (long) getpid(), msgbuf ));
#else
Debug( LDAP_DEBUG_TRACE,