Lines Matching refs:op
47 Operation *op,
70 Operation *op,
77 metainfo_t *mi = ( metainfo_t * )op->o_bd->be_private;
90 op->o_log_prefix, candidate, 0 );
117 op->o_log_prefix, candidate, buf );
131 op->o_log_prefix, candidate, buf );
146 op->o_log_prefix, candidate, buf );
155 op->o_log_prefix, candidate, (void *)mc );
157 rc = meta_back_init_one_conn( op, rs, *mcp, candidate,
185 if ( op->o_conn != NULL &&
186 !op->o_do_not_cache &&
191 rc = meta_back_proxy_authz_cred( mc, candidate, op, rs, LDAP_BACK_DONTSEND, &binddn, &cred, &method );
246 op->o_log_prefix, candidate, (void *)mc );
253 op->o_log_prefix, candidate, (void *)mc );
267 op->o_log_prefix, buf, 0 );
310 op->o_log_prefix, candidate, buf );
313 meta_clear_one_candidate( op, mc, candidate );
316 ( void )rewrite_session_delete( mt->mt_rwmap.rwm_rw, op->o_conn );
319 rc = meta_back_init_one_conn( op, rs, mc, candidate,
350 meta_clear_one_candidate( op, mc, candidate );
373 Operation *op,
380 metainfo_t *mi = ( metainfo_t * )op->o_bd->be_private;
402 meta_clear_one_candidate( op, mc, candidate );
444 Operation *op,
453 metainfo_t *mi = ( metainfo_t * )op->o_bd->be_private;
456 struct berval realbase = op->o_req_dn;
457 int realscope = op->ors_scope;
474 op->o_log_prefix, candidate,
484 Debug( LDAP_DEBUG_TRACE, "%s >>> meta_back_search_start[%d]\n", op->o_log_prefix, candidate, 0 );
489 if ( mt->mt_nsuffix.bv_len > op->o_req_ndn.bv_len ) {
490 switch ( op->ors_scope ) {
500 if ( dnIsSuffix( &mt->mt_nsuffix, &op->o_req_ndn ) ) {
519 rdn.bv_len -= op->o_req_ndn.bv_len + STRLENOF( "," );
521 && dnIsSuffix( &mt->mt_nsuffix, &op->o_req_ndn ) )
529 if ( op->ors_scope == LDAP_SCOPE_SUBORDINATE ) {
552 retcode = meta_search_dobind_init( op, rs, mcp, candidate, candidates );
554 Debug( LDAP_DEBUG_TRACE, "%s <<< meta_search_dobind_init[%d]=%d\n", op->o_log_prefix, candidate, retcode );
572 send_ldap_result( op, rs );
588 rc = ldap_back_filter_map_rewrite( dc, op->ors_filter,
589 &mfilter, BACKLDAP_MAP, op->o_tmpmemctx );
606 rc = ldap_back_map_attrs( op, &mt->mt_rwmap.rwm_at,
607 op->ors_attrs, BACKLDAP_MAP, &mapped_attrs );
616 if ( op->ors_tlimit != SLAP_NO_LIMIT ) {
617 tv.tv_sec = op->ors_tlimit > 0 ? op->ors_tlimit : 1;
623 save_ctrls = op->o_ctrls;
671 op->o_ctrls = op->o_tmpalloc( len, op->o_tmpmemctx );
675 op->o_ctrls[ dst ] = save_ctrls[ src ];
682 op->o_ctrls[ dst ] = (LDAPControl *)&op->o_ctrls[ nc + 1 ];
684 op->o_ctrls[ dst ]->ldctl_oid = LDAP_CONTROL_PAGEDRESULTS;
685 op->o_ctrls[ dst ]->ldctl_iscritical = 1;
687 op->o_ctrls[ dst ]->ldctl_value.bv_val = (char *)&op->o_ctrls[ dst ][ 1 ];
688 AC_MEMCPY( op->o_ctrls[ dst ]->ldctl_value.bv_val, val.bv_val, val.bv_len + 1 );
689 op->o_ctrls[ dst ]->ldctl_value.bv_len = val.bv_len;
695 op->o_ctrls[ dst ] = NULL;
702 ctrls = op->o_ctrls;
703 if ( meta_back_controls_add( op, rs, *mcp, candidate, &ctrls )
717 mapped_attrs, op->ors_attrsonly,
718 ctrls, NULL, tvp, op->ors_slimit, op->ors_deref,
726 if ( nretries && meta_back_retry( op, rs, mcp, candidate, LDAP_BACK_DONTSEND ) ) {
729 (void)mi->mi_ldap_extra->controls_free( op, rs, &ctrls );
746 (void)mi->mi_ldap_extra->controls_free( op, rs, &ctrls );
748 if ( save_ctrls != op->o_ctrls ) {
749 op->o_tmpfree( op->o_ctrls, op->o_tmpmemctx );
750 op->o_ctrls = save_ctrls;
755 ber_memfree_x( mapped_attrs, op->o_tmpmemctx );
757 if ( mfilter.bv_val != op->ors_filterstr.bv_val ) {
758 ber_memfree_x( mfilter.bv_val, op->o_tmpmemctx );
765 Debug( LDAP_DEBUG_TRACE, "%s <<< meta_back_search_start[%d]=%d\n", op->o_log_prefix, candidate, retcode );
771 meta_back_search( Operation *op, SlapReply *rs )
773 metainfo_t *mi = ( metainfo_t * )op->o_bd->be_private;
803 mc = meta_back_getconn( op, rs, NULL, sendok );
808 dc.conn = op->o_conn;
811 if ( candidates == NULL ) candidates = meta_back_candidates_get( op );
852 switch ( meta_back_search_start( op, rs, &dc, &mc, i, candidates, NULL, 0 ) )
870 savepriv = op->o_private;
871 op->o_private = (void *)i;
872 send_ldap_result( op, rs );
873 op->o_private = savepriv;
894 op->o_log_prefix, 0, 0 );
897 send_ldap_result( op, rs );
907 op->o_log_prefix, (void *)mc, 0 );
935 "cnd=\"%s\"\n", op->o_log_prefix, ncandidates, cnd );
949 op->o_log_prefix, op->o_req_dn.bv_val,
950 op->ors_scope );
964 send_ldap_error( op, rs, rc, NULL );
974 if ( op->ors_tlimit != SLAP_NO_LIMIT ) {
975 stoptime = op->o_time + op->ors_tlimit;
995 rc = rs->sr_err = op->o_protocol >= LDAP_VERSION3 ?
997 savepriv = op->o_private;
998 op->o_private = (void *)i;
999 send_ldap_result( op, rs );
1000 op->o_private = savepriv;
1005 if ( op->ors_tlimit != SLAP_NO_LIMIT
1010 savepriv = op->o_private;
1011 op->o_private = (void *)i;
1012 send_ldap_result( op, rs );
1013 op->o_private = savepriv;
1032 retcode = meta_search_dobind_init( op, rs, &mc, i, candidates );
1035 op->o_log_prefix, i, retcode );
1049 savepriv = op->o_private;
1050 op->o_private = (void *)i;
1051 send_ldap_result( op, rs );
1052 op->o_private = savepriv;
1069 switch ( meta_back_search_start( op, rs, &dc, &mc, i, candidates, NULL, 0 ) )
1078 savepriv = op->o_private;
1079 op->o_private = (void *)i;
1080 send_ldap_result( op, rs );
1081 op->o_private = savepriv;
1110 if ( op->o_abandon || LDAP_BACK_CONN_ABANDON( mc ) ) {
1121 op->o_log_prefix, (long)i, (void *)mc,
1154 if ( meta_back_retry( op, rs, &mc, i, LDAP_BACK_DONTSEND ) ) {
1156 switch ( meta_back_search_start( op, rs, &dc, &mc, i, candidates, NULL, 0 ) )
1167 savepriv = op->o_private;
1168 op->o_private = (void *)i;
1169 send_ldap_result( op, rs );
1170 op->o_private = savepriv;
1195 savepriv = op->o_private;
1196 op->o_private = (void *)i;
1197 send_ldap_result( op, rs );
1198 op->o_private = savepriv;
1242 savepriv = op->o_private;
1243 op->o_private = (void *)i;
1244 rs->sr_err = meta_send_entry( op, rs, mc, i, e );
1248 savepriv = op->o_private;
1249 op->o_private = (void *)i;
1250 send_ldap_result( op, rs );
1251 op->o_private = savepriv;
1263 op->o_private = savepriv;
1309 op->o_tmpmemctx );
1313 op->o_tmpmemctx );
1318 op->o_tmpmemctx );
1322 savepriv = op->o_private;
1323 op->o_private = (void *)i;
1324 ( void )send_search_reference( op, rs );
1325 op->o_private = savepriv;
1327 ber_bvarray_free_x( rs->sr_ref, op->o_tmpmemctx );
1362 slap_send_ldap_intermediate( op, rs );
1454 op->o_log_prefix,
1465 op->o_tmpmemctx );
1469 op->o_tmpmemctx );
1474 op->o_tmpmemctx );
1482 op->o_tmpmemctx );
1484 ber_memfree_x( sr_ref, op->o_tmpmemctx );
1493 op->o_log_prefix,
1508 op->o_log_prefix, i,
1579 switch ( meta_back_search_start( op, rs, &dc, &mc, i, candidates, &prcookie, prsize ) )
1590 savepriv = op->o_private;
1591 op->o_private = (void *)i;
1592 send_ldap_result( op, rs );
1593 op->o_private = savepriv;
1635 if ( rs->sr_nentries == op->ors_slimit
1639 savepriv = op->o_private;
1640 op->o_private = (void *)i;
1642 send_ldap_result( op, rs );
1644 op->o_private = savepriv;
1655 savepriv = op->o_private;
1656 op->o_private = (void *)i;
1658 send_ldap_result( op, rs );
1660 op->o_private = savepriv;
1681 retcode = meta_search_dobind_result( op, rs, &mc, i, candidates, msg );
1684 retcode = meta_back_search_start( op, rs, &dc, &mc, i, candidates, NULL, 0 );
1700 savepriv = op->o_private;
1701 op->o_private = (void *)i;
1702 send_ldap_result( op, rs );
1703 op->o_private = savepriv;
1719 op->o_log_prefix,
1734 if ( op->o_abandon || LDAP_BACK_CONN_ABANDON( mc ) ) {
1753 op->o_log_prefix, i, (void *)mc,
1759 meta_clear_one_candidate( op, mc, i );
1765 (void)meta_back_cancel( mc, op, rs,
1776 if ( op->o_abandon ) {
1813 rc = meta_back_op_result( mc, op, rs, META_TARGET_NONE,
1827 savepriv = op->o_private;
1828 op->o_private = (void *)(long)mi->mi_ntargets;
1846 && op->o_req_ndn.bv_len > mi->mi_targets[ i ]->mt_nsuffix.bv_len )
1854 rc = dnPretty( NULL, &bv, &pbv, op->o_tmpmemctx );
1863 op->o_tmpfree( pmatched.bv_val, op->o_tmpmemctx );
1866 op->o_private = (void *)i;
1869 op->o_tmpfree( pbv.bv_val, op->o_tmpmemctx );
1885 matched = op->o_bd->be_suffix[ 0 ].bv_val;
1923 send_ldap_result( op, rs );
1924 op->o_private = savepriv;
1929 if ( matched && matched != op->o_bd->be_suffix[ 0 ].bv_val ) {
1930 op->o_tmpfree( matched, op->o_tmpmemctx );
1934 ber_bvarray_free_x( rs->sr_v2ref, op->o_tmpmemctx );
1957 op->o_log_prefix, i, (void *)mc->mc_conns[i].msc_ld );
1961 meta_clear_one_candidate( op, mc, i );
1967 (void)meta_back_cancel( mc, op, rs,
1994 meta_back_quarantine( op, &candidates[ i ], i );
2004 && op->o_time > mc->mc_conns[ i ].msc_time )
2025 Operation *op,
2031 metainfo_t *mi = ( metainfo_t * )op->o_bd->be_private;
2061 dc.conn = op->o_conn;
2078 op->o_tmpmemctx );
2088 op->o_log_prefix, ent.e_name.bv_val, 0 );
2113 op->o_log_prefix, ent.e_name.bv_val, a.bv_val );
2148 op->o_log_prefix, ent.e_name.bv_val,
2399 int rc = slap_sort_vals( (Modifications *)attr, &text, &i, op->o_tmpmemctx );
2425 rs->sr_attrs = op->ors_attrs;
2429 rc = send_search_entry( op, rs );