1 ## Some notes about the architecture
4 Global Architecture for smbdlap-tools
5 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
7 smbldap-tools help you manage users and groups for Unix and Samba,
8 using LDAP. They may be used in any context, and are kept relatively
9 simplier enought to let you customize them to you needs.
11 They need the following objectClasses to work:
12 . sambaAccount: from samba.schema for Samba 2.2 branch
13 . posixAccount and posixGroup : from nis.schema
14 . organizationalUnit and dcObject: from core.schema
16 They will probably use in a near future some additional objectClasses
18 . mail features (sendmail/postfix/qmail/courier).
19 . conform to RFC2307 best practices (and so some maps too like merging
20 Netbios computers (sambaAccounts) with ipHosts
22 For ease of visualization of the LDAP objects by human standards, we
23 used a DIT like this one :
24 . dc=IDEALX,dc=org : the company/organization suffix
25 . ou=Users : to store users accounts
26 . ou=Computers : to store computers accounts
27 . ou=Groups : to store system groups
28 Of course, you're free to use a different naming scheme and DIT (see
32 Built in groups initial population
33 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
35 smbldap-populate.pl populate the LDAP directory with some built in groups
36 using gidNumber according to Well Know RID of Windows NT4 Srv. In fact, As
37 far a Samba 2.2.x is concerned, only the 'Domain Admins' (gidNumber 512) have
38 real inpact on the Samba and Windows population. To activate this group as
39 the Domain Administrators Group, use the following smb.conf directive (see
40 man smb.conf for more):
42 domain admin group = " @"Domain Admins" "
44 Other built in groups are really cosmetic ones with Samba 2.2.x. We did not
45 removed them because one of these days, we whish to use Samba 3.0 where
46 Windows Group Support should be operational.
48 Why these specific gidNumbers ?
49 It's about unix/windows mapping of numerical ids with Samba. Ids below 1024
50 are NT special ids. In fact, 512 is the RID (Windows uid/gid) for the
51 "Domain Administrators" NT group. The magic number is found in Samba sources
52 and possibly other Samba/Windows documentations.
54 The goal is to have a set of Unix users who are Domain Administrators and can
55 modify Samba datas (eg. LDAP content), with commandline tools or within
58 Say you want to add a NT4 ws to an NT domain (controlled by a samba/ldap
59 server). You give the domain administrator's login and password in the
60 appropriate ws settings, then the ws contacts the samba server, which checks
61 the credentials and use them as unix user to run the smbldap-tools (if I
62 remember). Giving 512 as a RID to a LDAP entry marks it as a domain admin
63 for Samba (thus Windows). Using nss_ldap, you also have an account with
67 Known BUGS and WORKAROUND used
68 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
70 The 2.2.2 has at least a bug : rid/primaryGroupID are read as hex in LDAP,
71 but written as decimal. Fixed in CVS by reading as decimal. By default
72 smbldap-useradd.pl writes decimal to LDAP. Use -x to support the odd
75 The samba-2.2.4-ldapbindnotuid0.patch is not a perfect solution however
76 as the check is there because Samba store admin credentials to establish the
77 LDAP connection. The uid == 0 check was to ensure that a normal user could
78 not get write access to the LDAP backend. A more logical situation should be
79 done for 2.2.5 by checking if the user is a member of the domain admin group
80 (reported to Jerremy and Gerald 2002-05-28).