ch4. Permissions & Ownership Flashcards

1
Q

ls -l

A

Bash command to list files and directories in present working directory in descriptive format, including: the permission string, (find the rest)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

. (in a file system)

A

self directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

.. (in a file system)

A

parent directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Anatomy of a permission string

A

11 characters
1st char is ‘d’ for directory or ‘-‘ for file
2nd, 3rd, 4th chars are the owner’s absolute permissions
5th, 6th, 7th chars are the group’s absolute permissions
8th, 9th, 10th chars are the other’s absolute permissions
11th char is SELinux security context +Alternative access methods

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

what command can also be used to modify the permissions of a file or directory?

A

chmod
-c
-f
-v
-R
(get descriptions for these options)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

what are symbolic permissions?

A

way to add or subtract permissions without looking at the absolute value of the permissions (probably expand on this?)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

what are absolute permissions?

Solve some made up absolute permissions

(advanced) Solve some made up permissions strings

A

1 = execute
2 = write
3 = write, execute
4 = read
5 = read, execute
6 = read, write
7 = read, write, execute

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

umask
umask -S
umask -p

A

(I don’t think this is a Bash command. I think this is a programing function that some Bash commands implement, like mkdir)
used to set the default permissions for newly created files and directories
-S umask as a symbolic value
-p umask as an absolute value

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

chown

A

used to change the owner, group, or both of a file or directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

chown syntax

A

chown [user name] : [group name] [file/directory name]

if you don’t wish to change the owner or the group, just leave the unchanged blank like:
chown [user name] : [file/directory name]
to only change the owner, or
chown : [group name] [file/directory name]
to only change the group name

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

chgrp

A

Bash command (find) I think to reassign the group of a file or directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

ls -ld

A

Bash command to print the permissions of the current working directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

SUID

A

?

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

SGID

A

?

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

sticky bit

A

flags a file so that only an owner of the stick bit’s file or directory or the root user can delete the file

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

attribute set

A

goes beyond typical permissions to be much more granular

17
Q

immutable flag

A

prevents modification by even a root user

18
Q

lsattr

A

Bash command to list the attributes of a file or directory

19
Q

access control list (ACL)

A

even more granular permission controls

20
Q

getfacl

A

Bash command to retrieve ACL info of a file or directory

21
Q

setfacl

A

Bash command to change the permissions of an ACL of a file or directory

22
Q

setfacl -
setfacl -

A
23
Q

setfacl -r
setfacl -s
setfacl -m
setfacl -x
setfacl -b

A
24
Q

chattr

A

Bash command to change the attributes (of a file or directory?)