]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#9647 Treat glue entries as missing
authorOndřej Kuzník <ondra@mistotebe.net>
Wed, 13 Oct 2021 15:11:43 +0000 (16:11 +0100)
committerQuanah Gibson-Mount <quanah@openldap.org>
Mon, 13 Dec 2021 17:04:19 +0000 (17:04 +0000)
We're using MANAGE_DSAIT control so we get to see them, but they don't
really exist (except for their CSN sometimes).

servers/slapd/overlays/syncprov.c
servers/slapd/syncrepl.c

index 75ef1ae4a7a3e7b68fadf8d247b5446d1f8a3fbb..e60884d7e063632ee1da4856420f860d01d81176 100644 (file)
@@ -1411,7 +1411,8 @@ syncprov_matchops( Operation *op, opcookie *opc, int saveit )
                        }
                }
 
-               if ( fc.fscope ) {
+               rc = LDAP_COMPARE_FALSE;
+               if ( !is_entry_glue( e ) && fc.fscope ) {
                        ldap_pvt_thread_mutex_lock( &ss->s_mutex );
                        op2 = *ss->s_op;
                        oh = *op->o_hdr;
@@ -2949,6 +2950,9 @@ syncprov_search_response( Operation *op, SlapReply *rs )
                                "bogus referral in context\n", op->o_log_prefix );
                        return SLAP_CB_CONTINUE;
                }
+               if ( is_entry_glue( rs->sr_entry ) ) {
+                       return LDAP_SUCCESS;
+               }
                a = attr_find( rs->sr_entry->e_attrs, slap_schema.si_ad_entryCSN );
                if ( a == NULL && rs->sr_operational_attrs != NULL ) {
                        a = attr_find( rs->sr_operational_attrs, slap_schema.si_ad_entryCSN );
index 4600f50bce13fc7374ffde472bf9850b22bc0511..9f72b33bcc8a98f8a5eb2f9b30d908b529c2cf6e 100644 (file)
@@ -5719,6 +5719,10 @@ nonpresent_callback(
                        if ( a == NULL ) return 0;
                }
 
+               if ( is_entry_glue( rs->sr_entry ) ) {
+                       return LDAP_SUCCESS;
+               }
+
                if ( present_uuid == NULL ) {
                        int covered = 1; /* covered by our new contextCSN? */