gunnar: server/patches/cyrus-imapd/cyrus-imapd-2.3.13 KOLAB_cyrus-imapd-2.3.13_Groups2.patch, 1.1, 1.2

cvs at kolab.org cvs at kolab.org
Thu Apr 23 22:17:18 CEST 2009


Author: gunnar

Update of /kolabrepository/server/patches/cyrus-imapd/cyrus-imapd-2.3.13
In directory doto:/tmp/cvs-serv16898

Modified Files:
	KOLAB_cyrus-imapd-2.3.13_Groups2.patch 
Log Message:
Merge from branch (kolab/issue2535 (group:distributionlist at example.com doesn't work for Cyrus IMAP ACLs), cvs diff -u -d -r1.1 -r1.1.2.1 KOLAB_cyrus-imapd-2.3.13_Groups2.patch | patch  KOLAB_cyrus-imapd-2.3.13_Groups2.patch).

Index: KOLAB_cyrus-imapd-2.3.13_Groups2.patch
===================================================================
RCS file: /kolabrepository/server/patches/cyrus-imapd/cyrus-imapd-2.3.13/KOLAB_cyrus-imapd-2.3.13_Groups2.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- KOLAB_cyrus-imapd-2.3.13_Groups2.patch	27 Oct 2008 17:53:01 -0000	1.1
+++ KOLAB_cyrus-imapd-2.3.13_Groups2.patch	23 Apr 2009 20:17:16 -0000	1.2
@@ -1,6 +1,6 @@
 diff -r 0d5aacd84718 lib/auth_unix.c
 --- a/lib/auth_unix.c	Mon Oct 27 18:37:49 2008 +0100
-+++ b/lib/auth_unix.c	Mon Oct 27 18:43:28 2008 +0100
++++ b/lib/auth_unix.c	Wed Apr 01 18:19:19 2009 +0200
 @@ -46,12 +46,133 @@
  #include <stdlib.h>
  #include <pwd.h>
@@ -17,7 +17,7 @@
 +/*
 + * __getgrent.c - This file is part of the libc-8086/grp package for ELKS,
 + * Copyright (C) 1995, 1996 Nat Friedman <ndf at linux.mit.edu>.
-+ * 
++ *
 + *  This library is free software; you can redistribute it and/or
 + *  modify it under the terms of the GNU Library General Public
 + *  License as published by the Free Software Foundation; either
@@ -119,7 +119,7 @@
 +    group.gr_mem = members;
 +    return &group;
 +}
-+    
++
 +static char *line_buff = NULL;
 +static char **members  = NULL;
 +
@@ -148,7 +148,7 @@
 +    if (!groupfile) groupfile = fopen("/etc/group", "r");
 +    if (groupfile) {
 +       while ((grp = fgetgrent(groupfile))) {
-+         if (strcasecmp(grp->gr_name, name) == 0) {
++         if (strcmp(grp->gr_name, name) == 0) {
 +           fclose(groupfile);
 +           return grp;
 +         }
@@ -170,7 +170,13 @@
  	if (!grp) return NULL;
  	if (strlen(grp->gr_name) >= sizeof(retbuf)-6)
  		return NULL;
-@@ -228,6 +368,7 @@
+@@ -223,11 +363,12 @@
+     struct auth_state *newstate;
+     struct passwd *pwd;
+     struct group *grp;
+-#if defined(HAVE_GETGROUPLIST) && defined(__GLIBC__)
++#if 0 && defined(HAVE_GETGROUPLIST) && defined(__GLIBC__)
+     gid_t gid, *groupids = NULL;
      int ret, ngroups = 10;
  #else
      char **mem;
@@ -178,6 +184,15 @@
  #endif
  
      identifier = mycanonifyid(identifier, 0);
+@@ -245,7 +386,7 @@
+ 
+     pwd = getpwnam(identifier);
+ 
+-#if defined(HAVE_GETGROUPLIST) && defined(__GLIBC__)
++#if 0 && defined(HAVE_GETGROUPLIST) && defined(__GLIBC__)
+     gid = pwd ? pwd->pw_gid : (gid_t) -1;
+ 
+     /* get the group ids */
 @@ -283,20 +424,23 @@
      if (groupids) free(groupids);
  
@@ -192,7 +207,7 @@
 +    if (groupfile) {
 +       while ((grp = fgetgrent(groupfile))) {
 +         for (mem = grp->gr_mem; *mem; mem++) {
-+            if (!strcasecmp(*mem, identifier)) break;
++            if (!strcmp(*mem, identifier)) break;
 +         }
  
 -	if (*mem || (pwd && pwd->pw_gid == grp->gr_gid)) {





More information about the commits mailing list