blob: 080efc6d613ca42d43adbf7b7dbd3456a52b433c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
|
'\" t
.\" Title: idmap_autorid
.\" Author: [see the "AUTHOR" section]
.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
.\" Date: 02/21/2015
.\" Manual: System Administration tools
.\" Source: Samba 4.0
.\" Language: English
.\"
.TH "IDMAP_AUTORID" "8" "02/21/2015" "Samba 4\&.0" "System Administration tools"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
idmap_autorid \- Samba\*(Aqs idmap_autorid Backend for Winbind
.SH "DESCRIPTION"
.PP
The idmap_autorid backend provides a way to use an algorithmic mapping scheme to map UIDs/GIDs and SIDs that is more deterministic than idmap_tdb and easier to configure than idmap_rid\&.
.PP
The module works similar to idmap_rid, but it automatically configures the range to be used for each domain, so there is no need to specify a specific range for each domain in the forest, the only configuration that is needed is the range of uid/gids that shall be used for user/group mappings and an optional size of the ranges to be used\&.
.PP
The mappings of which domain is mapped to which range is stored in autorid\&.tdb, thus you should backup this database regularly\&.
.PP
Due to the algorithm being used, it is the module that is most easy to use as it only requires a minimal configuration\&.
.SH "IDMAP OPTIONS"
.PP
rangesize = numberofidsperdomain
.RS 4
Defines the number of uids/gids available per domain range\&. The minimum needed value is 2000\&. SIDs with RIDs larger than this value will be mapped into extension ranges depending upon number of available ranges\&. If the autorid backend runs out of available ranges, mapping requests for new domains (or new extension ranges for domains already known) are ignored and the corresponding map is discarded\&.
.sp
Example: with rangesize set to 10000, users/groups with a RID up to 10000 will be put into the first range for the domain\&. When attempting to map the an object with a RID of 25000, an extension range will be allocated that will then be used to map all RIDs from 20000\-29999\&.
.sp
One range will be used for local users and groups and for non\-domain well\-known SIDs like Everyone (S\-1\-1\-0) or Creator Owner (S\-1\-3\-0)\&. A chosen list of well\-known SIDs will be preallocated on first start to create deterministic mappings for those\&.
.sp
Thus the number of local users and groups that can be created is limited by this option as well\&. If you plan to create a large amount of local users or groups, you will need set this parameter accordingly\&.
.sp
The default value is 100000\&.
.RE
.PP
read only = [ yes | no ]
.RS 4
Turn the module into read\-only mode\&. No new ranges will be allocated nor will new mappings be created in the idmap pool\&. Defaults to no\&.
.RE
.PP
ignore builtin = [ yes | no ]
.RS 4
Ignore any mapping requests for the BUILTIN domain\&. Defaults to no\&.
.RE
.SH "THE MAPPING FORMULAS"
.PP
The Unix ID for a RID is calculated this way:
.sp
.if n \{\
.RS 4
.\}
.nf
ID = REDUCED RID + IDMAP RANGE LOW VALUE + RANGE NUMBER * RANGE SIZE
.fi
.if n \{\
.RE
.\}
.sp
where REDUCED RID = RID % RANGE_SIZE and a DOMAIN RANGE INDEX = RID / RANGE_SIZE is used together with the domain sid to determine the RANGE NUMBER (stored in the database)\&.
.PP
Correspondingly, the formula for calculating the RID for a given Unix ID is this:
.sp
.if n \{\
.RS 4
.\}
.nf
RID = (ID \- LOW ID) % RANGE SIZE + DOMAIN RANGE INDEX * RANGE SIZE
.fi
.if n \{\
.RE
.\}
.sp
Where the DOMAIN RANGE INDEX is retrieved from the database along with the domain sid by the RANGE NUMBER = (ID \- LOW ID) / RANGE SIZE \&.
.SH "EXAMPLES"
.PP
This example shows you the minimal configuration that will work for the principal domain and 19 trusted domains / range extensions\&.
.sp
.if n \{\
.RS 4
.\}
.nf
[global]
security = ads
workgroup = CUSTOMER
realm = CUSTOMER\&.COM
idmap config * : backend = autorid
idmap config * : range = 1000000\-1999999
.fi
.if n \{\
.RE
.\}
.PP
This example shows how to configure idmap_autorid as default for all domains with a potentially large amount of users plus a specific configuration for a trusted domain that uses the SFU mapping scheme\&. Please note that idmap ranges and sfu ranges are not allowed to overlap\&.
.sp
.if n \{\
.RS 4
.\}
.nf
[global]
security = ads
workgroup = CUSTOMER
realm = CUSTOMER\&.COM
idmap config * : backend = autorid
idmap config * : range = 1000000\-19999999
idmap config * : rangesize = 1000000
idmap config TRUSTED : backend = ad
idmap config TRUSTED : range = 50000 \- 99999
idmap config TRUSTED : schema_mode = sfu
.fi
.if n \{\
.RE
.\}
.SH "AUTHOR"
.PP
The original Samba software and related utilities were created by Andrew Tridgell\&. Samba is now developed by the Samba Team as an Open Source project similar to the way the Linux kernel is developed\&.
|