Date: Sun, 21 Jan 2001 13:11:57 GMT From: Salvo Bartolotta <bartequi@inwind.it> To: freebsd-doc@freebsd.org Subject: Handbook, Chapter 3.2 (Unix permissions), and chmod(1) -- a suggestion Message-ID: <20010121.13115700@bartequi.ottodomain.org>
next in thread | raw e-mail | index | archive | help
Dear FreeBSD doc'ers, The description of the Unix directory permissions in this section might be a little confusing: <blockquote> The executable bit for a directory has a slightly different meaning than that of files. When a directory is marked executable, it means it can be searched into, for example, a directory listing can be done in that directory. ^^^^^^^^^^^^^^^^^^^ </blockquote> ^^^^^^^^^^^^^^^^^^^ The following examples may illustrate my (little) point. 235 1:12pm ~ >=3D=3D=3D=3D> mkdir foo 236 1:12pm ~ >=3D=3D=3D=3D> cd foo 237 1:12pm ~/foo >=3D=3D=3D=3D> mkdir bar 238 1:12pm ~/foo >=3D=3D=3D=3D> chmod 100 bar #make it searchable into = by owner 239 1:13pm ~/foo >=3D=3D=3D=3D> ls bar ls: bar: Permission denied #can't list! 240 1:13pm ~/foo >=3D=3D=3D=3D> chmod 400 bar #permission for listing 241 1:13pm ~/foo >=3D=3D=3D=3D> ls bar 242 1:13pm ~/foo >=3D=3D=3D=3D> #no complaints 242 1:14pm ~/foo >=3D=3D=3D=3D> chmod 100 bar 243 1:14pm ~/foo >=3D=3D=3D=3D> cd bar #can cd 244 1:14pm ~/foo/bar >=3D=3D=3D=3D> An equivalent description to that quoted above is found in chmod(1). Am I missing something ? If not, you may wish to consider the following <suggestion> The executable bit for a directory has a slightly different meaning than that of files. When a directory is marked executable, it means you can cd, ie "Change Directories", to it. In particular, in order for you to be able to cd to a subdirectory, the parent (sub)directories must have the executable bit set. N.B. a directory with ONLY the executable bit set allows you to perform NO other operations: you can neither list the directory contents nor create/modify/delete its file(s) or subdirectories. </suggestion> Best regards, Salvo To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010121.13115700>