Attributes Flashcards

(19 cards)

1
Q

What does Linux use to track user and group identities?

A

Numeric attributes stored in /etc/passwd for users and /etc/group for groups.

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

Why are these attributes important?

A

They are used for file ownership, permissions, and access control.

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

What are the four core attributes?

A

UID, GID, EUID, EGID.

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

What is UID?

A

Unique integer identifying each user account.

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

Where is UID stored?

A

/etc/passwd.

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

What does UID do?

A

Every file created by the user is stamped with this UID and used during permission checks.

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

Why is UID alignment important?

A

For shared storage across systems (e.g., NFS).

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

What is GID?

A

Identifies the user’s primary group.

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

Where is GID stored?

A

/etc/group.

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

What does GID do?

A

Assigns group permissions for shared access and enables collaborative file access.

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

Example of GID usage?

A

GID 2000 for group ‘developers’ allows shared write access.

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

What is EUID?

A

Effective User ID, a temporary identity used when running set-uid (SUID) programs.

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

How does EUID work?

A

Program runs with the UID of the file owner, not the user.

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

Example of EUID usage?

A

/usr/bin/passwd runs with root’s EUID.

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

Why is EUID important?

A

Allows privilege escalation for specific tasks while maintaining least privilege.

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

What is EGID?

A

Effective Group ID, a temporary group identity used when running set-gid (SGID) programs.

17
Q

How does EGID work?

A

Program or file runs with the group ID of the file; files in SGID directories inherit the directory’s group.

18
Q

Example of EGID usage?

A

chmod g+s <filename> sets SGID on a file.</filename>

19
Q

Why use EGID?

A

Enables temporary group access without permanently adding users to the group.