I had to draw this up for a co-worker today. I didn’t want to waste his time with metaphors and other nonsense. I wanted it to ‘click’. He wanted to know how
drwx------ came out to ‘700’. This is what I came up with.
Linux permissions are displayed in 10 characters, like this:
The first character is the type of resource. Here are 3 common types you might encounter.1
The last nine are really groups of three.
rwx have integers attached to them.
How it adds up
|because||4 + 2 + 1 = 7|
|because||4 + 2 = 6|
|because||4 + 1 = 5|
1Special thanks to cantonboy329. I re-phrased this so that it can be accurate without going into too much detail.