The Samba-Bugzilla – Attachment 236 Details for
Bug 703
Lookup of Windows userids in UNIX netgroups uses wrong case
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Proposed patch.
look (text/plain), 1.31 KB, created by
Jeremy Allison
on 2003-11-04 10:23:25 UTC
(
hide
)
Description:
Proposed patch.
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2003-11-04 10:23:25 UTC
Size:
1.31 KB
patch
obsolete
>Index: lib/username.c >=================================================================== >RCS file: /data/cvs/samba/source/lib/username.c,v >retrieving revision 1.66.2.12 >diff -u -r1.66.2.12 username.c >--- lib/username.c 25 Jul 2003 16:03:46 -0000 1.66.2.12 >+++ lib/username.c 4 Nov 2003 18:21:53 -0000 >@@ -293,13 +293,16 @@ > } > > /**************************************************************************** >- Check if a user is in a netgroup user list. >+ Check if a user is in a netgroup user list. If at first we don't succeed, >+ try lower case. > ****************************************************************************/ > > static BOOL user_in_netgroup_list(const char *user, const char *ngname) > { > #ifdef HAVE_NETGROUP > static char *mydomain = NULL; >+ fstring lowercase_user, lowercase_ngname; >+ > if (mydomain == NULL) > yp_get_default_domain(&mydomain); > >@@ -315,6 +318,20 @@ > > if (innetgr(ngname, NULL, user, mydomain)) > return (True); >+ >+ /* >+ * Ok, innetgr is case sensitive. Try once more with lowercase >+ * just in case. Attempt to fix #703. JRA. >+ */ >+ >+ fstrcpy(lowercase_user, user); >+ strlower_m(lowercase_user); >+ fstrcpy(lowercase_ngname, ngname); >+ strlower_m(lowercase_ngname); >+ >+ if (innetgr(lowercase_ngname, NULL, lowercase_user, mydomain)) >+ return (True); >+ > #endif /* HAVE_NETGROUP */ > return False; > }
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 703
: 236