Chapter 12 Flashcards
Linux is a blank, meaning that it provides features to help multiple individuals use the computer.
multiuser OS
Blanks enable multiple users to share the same computer without causing one another too much trouble
Accounts
Most account features are defined in the blank file, which consists of colon-delimited lines, with each line defining a single account.
/etc/password
The blank field in the /etc/password record is the most relevant feature that usually consists of lowercase letters and numbers. It’s the first field.
username
The blank field in the /etc/password record is the code that is required at login, and is the second field.
password
The blank field in the /etc/password record is a number that tracks accounts and is the third field in a record (usually greater than 1000 for regular users)
user identification number (UID)
The blank field in the /etc/password record tracks account to one or more collection of accounts with predefined permissions. It’s the fourth field in a record.
group identification number (GID)
The blank field in the /etc/password record normally hods the user’s full name, although it can hold other information, and it comes after the GID.
Comment
The blank field in the /etc/password record is a file directory listing for an account’s home base. It comes as the 6th field in the record.
Home directory
The blank field in the /etc/password record is associated with every account and is normally Bash.
Default shell
True or False: The password field in most modern /etc/password files is salted and hashed since the file is available to all users.
False
Where is the salted and hashed password actually stored?
the /etc/shadow file
Name the first field in the record of the /etc/shadow file.
Username
Name the second field in the record of the /etc/shadow file.
password
Name the third field in the record of the /etc/shadow file.
Last password change
In the /etc/shadow file, how is the last password change displayed?
As the number of days since Jan 1, 1970
Name the fourth field in the record of the /etc/shadow file.
Days until a change is allowed
Name the fifth field in the record of the /etc/shadow file.
days before a change is required
Name the sixth field in the record of the /etc/shadow file.
Days of warning before password expiration
Name the seventh field in the record of the /etc/shadow file.
Days between expiration and deacitvation
Name the eighth field in the record of the /etc/shadow file.
Expiration date
in the /etc/shadow file, how is the expiration date for the account displayed.
number of days since Jan 1, 1970
Name the ninth field in the record of the /etc/shadow file that is normally blank
Special flag
The blank file is used to define groups
/etc/group
Name the first field in the record of the /etc/group file.
group name
Name the second field in the record of the /etc/group file.
password
Name the third field in the record of the /etc/group file.
GID
Name the fourth field in the record of the /etc/group file.
User list
If you want to create that are associated with another group to which you belong (other than your primary group) use the blank command
newgrp
What command displays your current user ID?
whoami
If you need more information about your user ID, what command would you use?
id
The id utility shows what three areas of identification?
1) Your userID and userName
2) Your current groups with GID
3) All your group memberships
Name the option(s) for id that displays the effective group id
–group -g
Name the option(s) for id that displays all groups to which you belong
–groups -G
Name the option(s) for id that displays only the user data
–user -u
Name the option(s) for id that when used in conjunction with -g, -G or -u lists only the name and not the ids
–name -n
Name the option(s) for id that when used in conjunction with -g, -G or -u lists only the ids and not the name
–real -r
To learn who is online, use the blank command
who
When using the who command what fields are returned for each record?
Username, Terminal identifier, Login date and time, Remote host
Which command with who provides as a summary the total number of users online
–count or -q
What command is similar to whoami but displays more information
who am i
As an alternative to who, the blank command provides even more verbose results
w
In addition to the fields found in the results of a who command, what additional fields are added in w?
session’s idle time
JCPU (total amount of CPU time for session)
PCPU (total amount of CPU time for current process)
What column (program they are running)
The blank user account has superuser privilege to manage the features of the computer as a whole
root
Activities like browsing the web, writing letters, managing a music collection are known as blank
user tasks
The root user exists to complete blank tasks like installing software, preparing a new disk, and managing ordinary user accounts
administrative tasks
The root account has the ability to blank and blank every file on the computer
read write
Name three ways you can acquire root privileges
login as root
use su
use sudo
The blank command allows you to change your identity within a shell
su
If you type su without a username after the command, you are switched to what account?
root
When your are done with commands after using su, what do you type to relinquish the root user?
exit
If you use a blank with the su command or a blank with a blank, you will switch users and open a login session that runs the target user’s login scripts, which usually sets up their environment variables
-
- username
The blank command is similar to su, but it only allows you to run one command at a time
sudo
Of the ways to get root user privileges, only the blank command tracks and logs a user’s activity to prevent a repudiation environment
sudo
What two changes in the shell prompt let you know that you are using the root account
username is changed to root
the last character of the prompt is # instead of $
What is the purpose of the system account with a UID of 0?
It’s the system administrator’s account
What type of information will you find in the /etc/password for ordinary account users? (select all that apply)
A. A UID number
b. A complete listing of every group the user belongs
C. The path to the user accounts home directory
D. The path to the user account’s default GUI environment
E. The path to the user account’s default text-mode shell
A, C, E
You want to run the cat /etc/shadow command as root, but you aren’t logged in. Which of the following commands will get the job done?
A. sudo cat /etc/shadow
B. root cat /etc/shadow
C. passwd cat /etc/shadow
D. su cat /etc/shadow
E. admin cat /etc/shadow
A
True or False: whoami provides more information than id
False
True or False: Linux stores information on its groups in the /etc/groups file
False
True or False: As a general rule, you should provide extra care when running programs as root
True
The file that associates usernames with UID numbers in Linux is blank
/etc/passwd
To learn who is currently logged into the computer and what programs they are running, you can type blank
w
UID above 0 and below 500 or 1000 are reserved for use by blank accounts
system
A blank environment means that a person cannot deny actions, and the sudo command helps establish this environment
nonrepudiation