From a Windows computer I logged into My Mac after updating it to Lion. I have noticed that I am able to access all files on the Mac (including /dev /usr etc)
Is there a way to deny such access?
If you want a file to only be accessible by one user, you use: chown user foldername to assign that folder to that owner, then restrict access using the chmod 700 foldername command. Of course, you can achieve a lot of this by calling up a file's info and just setting it so that other people no longer have access to it under the privileges tab. I once had a folder that I assigned a chmod 000 (meaning nobody could access it, not even the user) and then used su (super-user) commands to bring it up if I needed it. Another option is to use chown root filename after locking down all the privs, so that you'll have to chown it back to your own username to use it.
The vital thing is to make sure that no-body else has administrator privileges, as they will be able to access anything from anywhere, as long as they know the right commands.
You can also keep a file in your root directory hidden by adding its name to the /.hidden file. Then, you can call it up with Apple-~ in Finder, enter its name, and Voila! Make sure you clear this out afterward, as someone might stumble across it.
And be careful. If you're not sure what I just said means, just stick to using the privs menu in the file-info box, and make sure no-one else has Admin access.
Check your System Preferences » Sharing. It could be that you have your Macintosh HD shared, which would expose its root filesystem, e.g.
There's no other possible reason for your whole file system being shared I can think of.