Topic 5: Security and File Permissions Flashcards

1
Q

what information is stored in the /etc/passwd folder? 6 things

A

username, info about a user’s password, UID, GID, home directory, and command shell

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

what commands could you use to show a user’s group membership?

A

id user_name
groups user_name
cat /etc/group | grep user_name

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

what command would you use to delete a user?

A

userdel user_name

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

What happens to a link when a symbolic link’s target is deleted?

A

the link persists to the target’s old location

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

what is the UID and GID of a root user?

A

zero

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

what are 3 characteristics of a standard user account?

A

the UID starts at 1,000
there is a defined home directory and subdirectory
has a defined login shell - usually bash

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

what are three characteristics of a system user account?

A

do not have a dedicated home directory
no valid login shell - /sbin/nologin
UID & GIDs are usually under 100

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

what does the command last do?

A

prints the entries of successful login attempts made by users

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

purpose of the command who

A

lists active login on the system

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

purpose of the command “w”

A

lists active logins on the system, current time and how long system has been up, how many users are connected, load averages, total CPU utilization times, and current process

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

purpose of command su

A

allows you to login as another user & you would need their password

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

purpose of command sudo

A

elevates current user’s privileges for a very short period of time

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

what does this folder contain: /etc/group

A

a list of every user group on the system and their secondary groups

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

what does this folder contain: /etc/shadow

A

this is where user passwords are stored
-minimum password, max password age, password expiration warning, date of last password change

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

purpose of the command id

A

provide info about a user’s identity and names of the groups they belong to

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

purpose of the command passwd and 3 popular options

A

change a user’s password
-l to lock the user’s account
-u unlock the user account
-S (capital s) output status about password for a specific account

17
Q

purpose of the command chmod and the popular options

A

change user permissions for a file
-u (user)
-g (group)
-o (others)

18
Q

purpose of the command chown

A

change file/directory ownership