Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 299521 Details for
Bug 439450
memberOf: A circular grouping causes groups to be listed as memberOf themselves
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
CVS Diffs
diffs.txt (text/plain), 2.85 KB, created by
Nathan Kinder
on 2008-03-28 21:07:08 UTC
(
hide
)
Description:
CVS Diffs
Filename:
MIME Type:
Creator:
Nathan Kinder
Created:
2008-03-28 21:07:08 UTC
Size:
2.85 KB
patch
obsolete
>Index: memberof.c >=================================================================== >RCS file: /cvs/dirsec/ldapserver/ldap/servers/plugins/memberof/memberof.c,v >retrieving revision 1.3 >diff -u -5 -t -r1.3 memberof.c >--- memberof.c 28 Mar 2008 20:45:22 -0000 1.3 >+++ memberof.c 28 Mar 2008 20:57:47 -0000 >@@ -944,10 +944,31 @@ > ll = 0; > } > } > /* continue with operation */ > { >+ Slapi_Value *to_dn_val = slapi_value_new_string(op_to); >+ Slapi_Value *this_dn_val = slapi_value_new_string(op_this); >+ >+ /* We want to avoid listing a group as a memberOf itself >+ * in case someone set up a circular grouping. >+ */ >+ if (0 == memberof_compare(&this_dn_val, &to_dn_val)) >+ { >+ slapi_log_error( SLAPI_LOG_PLUGIN, >+ MEMBEROF_PLUGIN_SUBSYSTEM, >+ "memberof_modop_one_r: not processing memberOf " >+ "operations on self entry: %s\n", this_dn_val); >+ slapi_value_free(&to_dn_val); >+ slapi_value_free(&this_dn_val); >+ goto bail; >+ } >+ >+ /* We don't need the Slapi_Value copies of the DN's anymore */ >+ slapi_value_free(&to_dn_val); >+ slapi_value_free(&this_dn_val); >+ > if(stack && LDAP_MOD_DELETE == mod_op) > { > if(memberof_is_legit_member(pb, group_dn, > op_this, op_to, stack)) > { >@@ -1010,24 +1031,16 @@ > memberof_test_membership_callback(e, 0); > } > > if(LDAP_MOD_ADD == mod_op) > { >- Slapi_Value *to_dn_val = slapi_value_new_string(op_to); >- Slapi_Value *this_dn_val = slapi_value_new_string(op_this); >- > /* If we failed to update memberOf for op_to, we shouldn't >- * try to fix up membership for parent groups. We also want >- * to avoid going into an endless loop if we've hit a >- * circular grouping. */ >- if ((rc == 0) && (0 != memberof_compare(&this_dn_val, &to_dn_val))) { >+ * try to fix up membership for parent groups. */ >+ if (rc == 0) { > /* fix up membership for groups that are now in scope */ > memberof_add_membership(pb, op_this, op_to); > } >- >- slapi_value_free(&to_dn_val); >- slapi_value_free(&this_dn_val); > } > } > > bail: > return rc;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 439450
: 299521