Directory Permissions

Directories have the same permission bits as files, rwx for user, group, and other, but with slightly different interpretations. You cannot run directories as programs, so the execute bit takes on a different meaning: it acts like a search bit. When opening any type of file by path, the user must have execute permission on every directory mentioned in the path. The execute bit can match the user, group, or other. Read permission is different from the execute/search permission. Read permission lets you read the directory itself, like with the ls command, to obtain a list of all the file names in the directory. Execute just means that you can pass through, or execute programs in that directory. You do not need read permissions ...

Get Advanced Mac OS X Programming: The Big Nerd Ranch Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.