7 CONTENT="Modular DocBook HTML Stylesheet Version 1.57"></HEAD
27 >smbcacls -- Set or get ACLs on an NT file or directory names</DIV
29 CLASS="REFSYNOPSISDIV"
39 > {//server/share} {filename} [-U username] [-A acls] [-M acls] [-D acls] [-S acls] [-C name] [-G name] [-n] [-h]</P
49 >This tool is part of the <A
58 > program manipulates NT Access Control Lists
59 (ACLs) on SMB file shares. </P
69 >The following options are available to the <B
73 The format of ACLs is described in the section ACL FORMAT </P
83 >Add the ACLs specified to the ACL list. Existing
84 access control entries are unchanged. </P
90 >Modify the mask value (permissions) for the ACLs
91 specified on the command line. An error will be printed for each
92 ACL specified that was not already present in the ACL list
99 >Delete any ACLs specified on the command line.
100 An error will be printed for each ACL specified that was not
101 already present in the ACL list. </P
107 >This command sets the ACLs on the file with
108 only the ones specified on the command line. All other ACLs are
109 erased. Note that the ACL specified must contain at least a revision,
110 type, owner and group for the call to succeed. </P
116 >Specifies a username used to connect to the
117 specified service. The username may be of the form "username" in
118 which case the user is prompted to enter in a password and the
119 workgroup specified in the <TT
123 used, or "username%password" or "DOMAIN\username%password" and the
124 password and workgroup names are used as provided. </P
130 >The owner of a file or directory can be changed
131 to the name given using the <TT
137 The name can be a sid in the form S-1-x-y-z or a name resolved
138 against the server specified in the first argument. </P
140 >This command is a shortcut for -M OWNER:name.
147 >The group owner of a file or directory can
148 be changed to the name given using the <TT
154 option. The name can be a sid in the form S-1-x-y-z or a name
155 resolved against the server specified n the first argument.
158 >This command is a shortcut for -M GROUP:name.</P
164 >This option displays all ACL information in numeric
165 format. The default is to convert SIDs to names and ACE types
166 and masks to a readable string format. </P
172 >Print usage information on the <B
189 >The format of an ACL is one or more ACL entries separated by
190 either commas or newlines. An ACL entry is one of the following: </P
199 CLASS="PROGRAMLISTING"
201 REVISION:<revision number>
202 OWNER:<sid or name>
203 GROUP:<sid or name>
204 ACL:<sid or name>:<type>/<flags>/<mask>
211 >The revision of the ACL specifies the internal Windows
212 NT ACL revision for the security descriptor.
213 If not specified it defaults to 1. Using values other than 1 may
214 cause strange behaviour. </P
216 >The owner and group specify the owner and group sids for the
217 object. If a SID in the format CWS-1-x-y-z is specified this is used,
218 otherwise the name specified is resolved using the server on which
219 the file or directory resides. </P
221 >ACLs specify permissions granted to the SID. This SID again
222 can be specified in CWS-1-x-y-z format or as a name in which case
223 it is resolved against the server on which the file or directory
224 resides. The type, flags and mask values determine the type of
225 access granted to the SID. </P
227 >The type can be either 0 or 1 corresponding to ALLOWED or
228 DENIED access to the SID. The flags values are generally
229 zero for file ACLs and either 9 or 2 for directory ACLs. Some
230 common flags are: </P
236 >#define SEC_ACE_FLAG_OBJECT_INHERIT 0x1</P
240 >#define SEC_ACE_FLAG_CONTAINER_INHERIT 0x2</P
244 >#define SEC_ACE_FLAG_NO_PROPAGATE_INHERIT 0x4
249 >#define SEC_ACE_FLAG_INHERIT_ONLY 0x8</P
253 >At present flags can only be specified as decimal or
254 hexadecimal values.</P
256 >The mask is a value which expresses the access right
257 granted to the SID. It can be given as a decimal or hexadecimal value,
258 or by using one of the following text strings which map to the NT
259 file permissions of the same name. </P
267 > - Allow read access </P
273 > - Allow write access</P
279 > - Execute permission on the object</P
285 > - Delete the object</P
291 > - Change permissions</P
297 > - Take ownership</P
301 >The following combined permissions can be specified:</P
309 > - Equivalent to 'RX'
316 > - Equivalent to 'RXWD' permissions
323 > - Equivalent to 'RWXDPO'
339 > program sets the exit status
340 depending on the success or otherwise of the operations performed.
341 The exit status may be one of the following values. </P
343 >If the operation succeeded, smbcacls returns and exit
347 > couldn't connect to the specified server,
348 or there was an error getting or setting the ACLs, an exit status
349 of 1 is returned. If there was an error parsing any command line
350 arguments, an exit status of 2 is returned. </P
360 >This man page is correct for version 2.2 of
371 >The original Samba software and related utilities
372 were created by Andrew Tridgell. Samba is now developed
373 by the Samba Team as an Open Source project similar
374 to the way the Linux kernel is developed.</P
379 > was written by Andrew Tridgell
382 >The conversion to DocBook for Samba 2.2 was done