The Samba-Bugzilla – Attachment 8757 Details for
Bug 9784
classicupgrade: Improve handling of invalid accounts (particularly from pdb_ldap)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch for pdb_ldap NOT to skip invalid account
0001-pdb_ldap-Do-not-skip-accounts-without-a-sambaAcctFla.patch (text/plain), 1.34 KB, created by
Andrew Bartlett
on 2013-04-11 07:21:40 UTC
(
hide
)
Description:
patch for pdb_ldap NOT to skip invalid account
Filename:
MIME Type:
Creator:
Andrew Bartlett
Created:
2013-04-11 07:21:40 UTC
Size:
1.34 KB
patch
obsolete
>From 80c60a86fc0717919a907b129be8a80f065ae8c4 Mon Sep 17 00:00:00 2001 >From: Andrew Bartlett <abartlet@samba.org> >Date: Thu, 11 Apr 2013 17:21:33 +1000 >Subject: [PATCH] pdb_ldap: Do not skip accounts without a sambaAcctFlags > value > >We allow this to mean a sambaAcctFlags value of zero in other parts of the code >and by allowing these users to show up in a search, we can read and correct them >during the classicupgrade, rather than not know they exist at all. > >Most parts of the code do not look for ACB_NORMAL, which is why >these users appear to work. > >Andrew Bartlett >--- > source3/passdb/pdb_ldap.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > >diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c >index dc6a9c3..0905ab4 100644 >--- a/source3/passdb/pdb_ldap.c >+++ b/source3/passdb/pdb_ldap.c >@@ -4452,11 +4452,11 @@ static bool ldapuser2displayentry(struct ldap_search_state *state, > > vals = ldap_get_values(ld, entry, "sambaAcctFlags"); > if ((vals == NULL) || (vals[0] == NULL)) { >- DEBUG(5, ("\"sambaAcctFlags\" not found\n")); >- return False; >+ acct_flags = ACB_NORMAL; >+ } else { >+ acct_flags = pdb_decode_acct_ctrl(vals[0]); >+ ldap_value_free(vals); > } >- acct_flags = pdb_decode_acct_ctrl(vals[0]); >- ldap_value_free(vals); > > if ((state->acct_flags != 0) && > ((state->acct_flags & acct_flags) == 0)) >-- >1.7.11.7 >
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 Raw
Actions:
View
Attachments on
bug 9784
:
8754
|
8756
| 8757 |
8769