Take Control of Permissions in OS X
Set permissions using third-party tools
The Info window is adequate for most day-to-day, basic permissions editing. However, it has a limited feature set and cannot handle many permissions-related tasks. Fortunately, several third-party tools perform these missing tasks. I cover three popular ones here: FileXaminer, Super Get Info, and XRay.
All three tools do what the Info window does and more, and provide finer control over permissions. The interfaces and features—at least as far as permissions are concerned—are very similar, and they all provide good help documentation and contextual menus.
The $10 FileXaminer from Gideon Softworks has several advantages over the Info window. A partial list of its permissions-related features includes:
• Batch edit: You can change permissions (and other settings) on multiple items simultaneously.
• Manage groups: This feature simplifies the management of Unix groups considerably. (At the time of this writing, the current version of FileXaminer did not manage groups in Tiger reliably, though it works fine in Panther. Hopefully the problem has been resolved by the time you read this.)
• Manipulate the Set UID, Set GID, and Sticky Bit: I cover these advanced file attributes elsewhere in this ebook.
• Change ownership recursively: While the Info window will allow you to apply permission changes to items enclosed within a folder, it will not allow you to apply ownership changes to all items enclosed within a folder. FileXaminer will.
• View the Unix command equivalent: When you set permissions, FileXaminer displays the syntax for the equivalent chmod command.
Figure 3: Ownership and permissions in FileXaminer. Note that you can set all the basic permissions settings individually.
• Set individual Unix permissions: The Info window allows you to set only predefined combinations of Unix permissions. You cannot change the individual permissions one by one. FileXaminer, while also providing preset combinations, allows you to set Unix permissions individually (see Figure 3 on the right).
In addition to permissions-related tasks, FileXaminer handles many other tasks, such as changing the modification and creation dates of items, editing icons, editing configuration text files as root, and copying paths of selected items to the clipboard.
You can set permissions with FileXaminer in many ways; here are the steps for changing basic permissions on a single item:
• Use the Owner/Group pop-up menus to change the user owner or group owner.
• Use the grid of checkboxes to set permissions, or choose from among the options in the Presets pop-up menu.
Super Get Info
Figure 4: Ownership and permissions as seen in Super Get Info. You can set all the basic permissions settings individually.
Super Get Info costs $20 and comes from Bare Bones Software, makers of BBEdit (See Figure 4 on the right).
In addition to the capabilities of the Info window, features of Super Get Info include:
• Multiple Super Get Info windows: In versions of Mac OS X before Tiger, if you select multiple items in the Finder and then choose Get Info, you will get one Info window. If you open multiple items with Super Get Info, you get a Super Get Info window for each item, thus allowing you to change ownership and permissions settings individually.
• Set individual Unix permissions: The Info window allows you to set only predefined combinations of Unix permissions, but Super Get Info allows you to set Unix permissions individually.
The sgi command line tool is an interesting additional item. Optionally installable, it allows you to open files in Super Get Info directly from the Mac OS X command line.
To set permissions with Super Get Info, simply follow these steps:
• Use the pop-up menus to choose Owner and Group.
• Use the grid of checkboxes to set permissions.
The $10 XRay is the brainchild of Rainer Brokerhoff (see Figure 5).
Figure 5: The XRay interface for changing ownership and permissions lets you set all the basic permissions settings individually, and it displays the Unix equivalents.
Like FileXaminer and Super Get Info, XRay augments the function of the Info window in a number of ways, including:
• Set individual Unix permissions: The Info window allows you to set only predefined combinations of Unix permissions. You cannot change the individual permissions one by one. XRay allows you to set Unix permissions individually.
• Change obscure attributes: Not only can you set the set UID, set GID, and sticky bit, you can also set attributes, such as immutability, ordinarily only accessible via the Unix chflags command.
• View Unix command equivalent: When you set permissions, XRay displays the syntax for the equivalent chmod command. I talk about chmod in Change Permissions with chmod.
To set permissions with XRay, follow these steps:
• Use the pop-up menus to choose owner and group.
• Use the grid of checkboxes to set permissions.
I talk about chmod in “Change Permissions with chmod” in the full ebook.
[ Brian Tanaka provides Unix and open source technologies consulting. His writing has appeared in Linux Journal and Sysadmin Magazine ; his latest is Take Control of Permissions in Mac OS X ( TidBits Electronic Publishing, 2005). ]