idmap_ldap.8: Add example with readonly backend
[Samba/gebeck_regimport.git] / docs-xml / manpages-3 / idmap_ldap.8.xml
blobe77aec091588003e110f0dd1bbaf6077d2daacf3
1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//Samba-Team//DTD DocBook V4.2-Based Variant V1.0//EN" "http://www.samba.org/samba/DTD/samba-doc">
3 <refentry id="idmap_ldap.8">
5 <refmeta>
6         <refentrytitle>idmap_ldap</refentrytitle>
7         <manvolnum>8</manvolnum>
8         <refmiscinfo class="source">Samba</refmiscinfo>
9         <refmiscinfo class="manual">System Administration tools</refmiscinfo>
10         <refmiscinfo class="version">3.6</refmiscinfo>
11 </refmeta>
14 <refnamediv>
15         <refname>idmap_ldap</refname>
16         <refpurpose>Samba's idmap_ldap Backend for Winbind</refpurpose>
17 </refnamediv>
19 <refsynopsisdiv>
20         <title>DESCRIPTION</title>
22         <para>The idmap_ldap plugin provides a means for Winbind to
23         store and retrieve SID/uid/gid mapping tables in an LDAP directory
24         service.
25         </para>
27         <para>
28         In contrast to read only backends like idmap_rid, it is an allocating
29         backend: This means that it needs to allocate new user and group IDs in
30         order to create new mappings.
31         </para>
33 </refsynopsisdiv>
35 <refsect1>
36         <title>IDMAP OPTIONS</title>
38         <variablelist>
39                 <varlistentry>
40                 <term>ldap_base_dn = DN</term>
41                 <listitem><para>
42                         Defines the directory base suffix to use for
43                         SID/uid/gid mapping entries.  If not defined, idmap_ldap will default
44                         to using the &quot;ldap idmap suffix&quot; option from smb.conf.
45                 </para></listitem>
46                 </varlistentry>
48                 <varlistentry>
49                 <term>ldap_user_dn = DN</term>
50                 <listitem><para>
51                         Defines the user DN to be used for authentication. If absent an
52                         anonymous bind will be performed.
53                 </para></listitem>
54                 </varlistentry>
56                 <varlistentry>
57                 <term>ldap_url = ldap://server/</term>
58                 <listitem><para>
59                         Specifies the LDAP server to use for
60                         SID/uid/gid map entries. If not defined, idmap_ldap will
61                         assume that ldap://localhost/ should be used.
62                 </para></listitem>
63                 </varlistentry>
65                 <varlistentry>
66                 <term>range = low - high</term>
67                 <listitem><para>
68                         Defines the available matching uid and gid range for which the
69                         backend is authoritative.
70                 </para></listitem>
71                 </varlistentry>
72         </variablelist>
73 </refsect1>
75 <refsect1>
76         <title>EXAMPLES</title>
78         <para>
79         The following example shows how an ldap directory is used as the 
80         default idmap backend. It also configures the idmap range and base 
81         directory suffix.
82         </para>
84         <programlisting>
85         [global]
86         idmap config * : backend      = ldap
87         idmap config * : range        = 1000000-1999999
88         idmap config * : ldap_url     = ldap://localhost/
89         idmap config * : ldap_base_dn = ou=idmap,dc=example,dc=com
90         </programlisting>
92         <para>
93         This example shows how ldap can be used as a readonly backend while
94         tdb is the default backend used to store the mappings.
95         It adds an explicit configuration for some domain DOM1, that
96         uses the ldap idmap backend. Note that a range disjoint from the
97         default range is used.
98         </para>
100         <programlisting>
101         [global]
102         # "backend = tdb" is redundant here since it is the default
103         idmap config * : backend = tdb
104         idmap config * : range = 1000000-1999999
106         idmap config DOM1 : backend = ldap
107         idmap config DOM1 : range = 2000000-2999999
108         idmap config DOM1 : read only = yes
109         idmap config DOM1 : ldap_url = ldap://server/
110         idmap config DOM1 : ldap_base_dn = ou=idmap,dc=dom1,dc=example,dc=com
111         idmap config DOM1 : ldap_user_dn = cn=idmap_admin,dc=dom1,dc=example,dc=com
112         </programlisting>
113 </refsect1>
115 <refsynopsisdiv>
116         <title>NOTE</title>
118         <para>In order to use authentication against ldap servers you may
119         need to provide a DN and a password. To avoid exposing the password
120         in plain text in the configuration file we store it into a security
121         store. The &quot;net idmap &quot; command is used to store a secret
122         for the DN specified in a specific idmap domain.
123         </para>
124 </refsynopsisdiv>
126 <refsect1>
127         <title>AUTHOR</title>
129         <para>
130         The original Samba software and related utilities
131         were created by Andrew Tridgell. Samba is now developed
132         by the Samba Team as an Open Source project similar
133         to the way the Linux kernel is developed.
134         </para>
135 </refsect1>
137 </refentry>