Visibility

FSEvents checks the permissions of directories before telling you about changes. This way you won’t be able to see another user’s directory names if they have sufficiently locked-down permissions. So if you have a directory named PinkWearsPants, and you know that Pink will be offended if you accuse him of wearing pants, then you should keep this directory in one with strict directory permissions that Pink would not be able to see into. Processes running as root will of course be able to see all events.

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.