/[smeserver]/rpms/e-smith-ldap/sme8/e-smith-ldap-5.2.0-group-attrs.patch
ViewVC logotype

Contents of /rpms/e-smith-ldap/sme8/e-smith-ldap-5.2.0-group-attrs.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (show annotations) (download)
Fri Nov 5 05:13:58 2010 UTC (13 years, 6 months ago) by slords
Branch: MAIN
CVS Tags: e-smith-ldap-5_2_0-76_el5_sme, e-smith-ldap-5_2_0-71_el5_sme, e-smith-ldap-5_2_0-77_el5_sme, e-smith-ldap-5_2_0-78_el5_sme, e-smith-ldap-5_2_0-61_el5_sme, e-smith-ldap-5_2_0-66_el5_sme, e-smith-ldap-5_2_0-70_el5_sme, e-smith-ldap-5_2_0-79_el5_sme, e-smith-ldap-5_2_0-81_el5_sme, e-smith-ldap-5_2_0-75_el5_sme, e-smith-ldap-5_2_0-73_el5_sme, e-smith-ldap-5_2_0-69_el5_sme, e-smith-ldap-5_2_0-72_el5_sme, e-smith-ldap-5_2_0-65_el5_sme, e-smith-ldap-5_2_0-80_el5_sme, e-smith-ldap-5_2_0-74_el5_sme, e-smith-ldap-5_2_0-63_el5_sme, e-smith-ldap-5_2_0-62_el5_sme, e-smith-ldap-5_2_0-68_el5_sme, e-smith-ldap-5_2_0-67_el5_sme, e-smith-ldap-5_2_0-64_el5_sme, HEAD
Changes since 1.1: +35 -2 lines
* Thu Nov 4 2010 Shad L. Lords <slords@mail.com> 5.2.0-61.sme
- Apply correct patch for group descriptions/password [SME: 6337]

1 diff -up e-smith-ldap-5.2.0/root/etc/e-smith/events/actions/ldap-update.group-attrs e-smith-ldap-5.2.0/root/etc/e-smith/events/actions/ldap-update
2 diff -up e-smith-ldap-5.2.0/root/etc/e-smith/templates/home/e-smith/db/ldap/ldif/template-begin.group-attrs e-smith-ldap-5.2.0/root/etc/e-smith/templates/home/e-smith/db/ldap/ldif/template-begin
3 diff -up e-smith-ldap-5.2.0/root/etc/e-smith/events/actions/ldap-update.group-attrs e-smith-ldap-5.2.0/root/etc/e-smith/events/actions/ldap-update
4 --- e-smith-ldap-5.2.0/root/etc/e-smith/events/actions/ldap-update.group-attrs 2010-11-04 23:03:07.000000000 -0600
5 +++ e-smith-ldap-5.2.0/root/etc/e-smith/events/actions/ldap-update 2010-11-04 23:05:21.000000000 -0600
6 @@ -207,8 +207,7 @@ foreach my $group (qw/nobody shared www/
7 $updates->{$dn}->{objectClass} = ['posixGroup'];
8
9 # Read information from getent group
10 - @{$updates->{$dn}}{'cn','userPassword','gidNumber','memberUid'} = getgrnam($group);
11 - $updates->{$dn}->{userPassword} =~ s/^/{CRYPT}/ unless $updates->{$dn}->{userPassword} =~ m/^{/;
12 + @{$updates->{$dn}}{'cn','junk','gidNumber','memberUid'} = getgrnam($group);
13 $updates->{$dn}->{memberUid} = [ split /\s+/, $updates->{$dn}->{memberUid} ];
14
15 # Ensure groups have the needed properties
16 @@ -311,9 +310,7 @@ foreach my $acct (@accounts)
17 $updates->{$dn}->{objectClass} = ['posixGroup'];
18
19 # Read information from getent group
20 - @{$updates->{$dn}}{'cn','userPassword','gidNumber','memberUid'} = getgrnam($key);
21 - $updates->{$dn}->{userPassword} =~ s/^/{CRYPT}/ unless $updates->{$dn}->{userPassword} =~ m/^{/;
22 - $updates->{$dn}->{description} = $desc if $desc;
23 + @{$updates->{$dn}}{'cn','junk','gidNumber','memberUid'} = getgrnam($key);
24 $updates->{$dn}->{memberUid} = [ split /\s+/, $updates->{$dn}->{memberUid} ];
25
26 # Ensure groups have the needed properties
27 @@ -321,6 +318,7 @@ foreach my $acct (@accounts)
28 {
29 push @{$updates->{$dn}->{objectClass}}, 'mailboxRelatedObject';
30 $updates->{$dn}->{mail} = "$key\@$domain";
31 + $updates->{$dn}->{description} = $desc if $desc;
32 }
33
34 # Samba parameters if we find the samba.schema
35 diff -up e-smith-ldap-5.2.0/root/etc/e-smith/templates/home/e-smith/db/ldap/ldif/template-begin.group-attrs e-smith-ldap-5.2.0/root/etc/e-smith/templates/home/e-smith/db/ldap/ldif/template-begin
36 --- e-smith-ldap-5.2.0/root/etc/e-smith/templates/home/e-smith/db/ldap/ldif/template-begin.group-attrs 2010-11-04 23:03:07.000000000 -0600
37 +++ e-smith-ldap-5.2.0/root/etc/e-smith/templates/home/e-smith/db/ldap/ldif/template-begin 2010-11-04 23:04:08.000000000 -0600
38 @@ -97,7 +97,7 @@
39 endpwent();
40
41 # Read in group details
42 - while(my ($key,$pwd,$gid,$members) = getgrent())
43 + while(my ($key,undef,$gid,$members) = getgrent())
44 {
45 # skip non sme groups
46 $account = $a->get($key) || next;
47 @@ -111,15 +111,14 @@
48
49 $ldif->{$dn}->{objectClass} = [ qw(posixGroup) ];
50 $ldif->{$dn}->{cn} = $key;
51 - $ldif->{$dn}->{userPassword} = ($pwd =~ m/^\{/) ? $pwd : "\{CRYPT\}$pwd";
52 $ldif->{$dn}->{gidNumber} = $gid;
53 - $ldif->{$dn}->{description} = $ldif->{$dnmap->{$key}->{user}}->{cn} if exists $ldif->{$dnmap->{$key}->{user}}->{cn};
54 $ldif->{$dn}->{memberUid} = [ split /\s+/, $members ];
55
56 if ($type eq 'group')
57 {
58 push @{$ldif->{$dn}->{objectClass}}, 'mailboxRelatedObject';
59 $ldif->{$dn}->{mail} = "$key\@$DomainName";
60 + $ldif->{$dn}->{description} = $ldif->{$dnmap->{$key}->{user}}->{cn} if exists $ldif->{$dnmap->{$key}->{user}}->{cn};
61 }
62 }
63 endgrent();
64 @@ -133,9 +132,7 @@
65 $dnmap->{$group}->{group} = $dn;
66
67 $ldif->{$dn}->{objectClass} = [ qw(posixGroup) ];
68 - @{$ldif->{$dn}}{'cn','userPassword','gidNumber','memberUid'} = getgrnam($group);
69 - $ldif->{$dn}->{userPassword} =~ s/^/{CRYPT}/ unless $ldif->{$dn}->{userPassword} =~ m/^\{/;
70 - $ldif->{$dn}->{description} = $ldif->{$dnmap->{$key}->{user}}->{cn} if exists $ldif->{$dnmap->{$key}->{user}}->{cn};
71 + @{$ldif->{$dn}}{'cn','junk','gidNumber','memberUid'} = getgrnam($group);
72 $ldif->{$dn}->{memberUid} = [ split /\s+/, $ldif->{$dn}->{memberUid} ];
73
74 if ($group eq 'shared'){

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed