user group other [ ][ ][ ] [ ][ ][ ] [ ][ ][ ] r - read (can do ls) w - write x - search (can access files given their name)
[r][-][x] |
write-protect for safety annoying? |
[r][w][x] | normal |
[r][w][x] |
shared writable directory can create/delete files |
[r][-][x] |
shared read-only directory can do ls |
[-][-][x] |
shared read-only dir can't do ls can access file if know its name can't explore without filenames
Example: "share" in my home dir.
Example: web dir |
[-][-][-] | normal - hidden |
# take a look at the permissions: ls -ld /users/tutors/mhumphrysdculab # you are "other" which is "--x" ls -ld /users/tutors/mhumphrysdculab/share # you are "other" which is "r-x" cd /users/tutors/mhumphrysdculab # (works) ls # (fails) cd share # (works) ls # (works)
# I am "--x" # In fact, all accounts (including students) are "--x" drwx-----x 22 mhumphrysdculab tutors 4096 Feb 11 11:53 /users/tutors/mhumphrysdculab drwx-----x 4 SOMENAME student 4096 Aug 21 17:00 /users/student/SOMENAME
Q. So how come you can get into my dir but not into other students' dirs?
drwx-----x executabledir drwx---r-x readabledirCommand-line shows they both have files in them.
drwx-----x