Upgrade to remove ads Show
Only ₩37,125/year
Terms in this set (124)id display user identity chmod change a files node umask set the default file permissions su run a shell as another user sudo execute a command as another user chown change a file's owner chgrp change a file group ownership passwd change a user's password a user may own files and directories a user has control of their files and directories access to others group consisting of one or more users who are given access to files and directories of their owners world owner grants some access rights to everybody when user accounts are created users are assigned a number called a user id (uid) after a new user is assigned a uid then mapped to a username primary group id gid and may belong to additional groups where are user accounts defined in? /etc/passwd where are user groups defined in? /etc/group what is another location that holds information about a user password? /etc/shadow what does the /etc/passwd define? user(login)name,the uid, the gid, the accounts real name, the home directory, and the login shell the first 10 characters of a file listing are called? file attributes the first character of a file listing is called? file type remaining 9 characters of a file listing is called file mode file mode is defined as representing the read,write and execute permissions for the file owner, the files group owner, and everybody else file type - a regular file file type d a directory file type l a symbolic link, the remaining file attributes are always rwxrwxrwx and are dummy values, the real file attributes are those of the file the symbolic link point to file type c a character special file, refers to a device that handles data as a stream of bytes, like a terminal or modem file type b a block special file, refers to a device that handles data in blocks, like a hard drive or cd-rom drive example of typing in id command aadrin2002@aadrin2002-MS-7850:~$ id file permission attribute r allows a file to be opened and read directory attribute r allows a directory's contents to be listed if the execute attribute is also set file attribute w allows a file to be written or truncated, does not allow files to be renamed or deleted the ability to delete or rename files is determined by? directory attributes directory attribute w allows files within a directory to be created, deleted and renamed if the execute attribute is set file attribute x allows a file to be treated as a program and executed. program files written in scripting languages must also be set as readable to be executed directory attribute x allows a directory to be entered; e.g., cd directory -rwx------ a regular file that is readable, writable and executable by the file's owner. no one else has any access -rw------- a regular file that is readable and writable by the file's owner. no one else has any access -rw-r--r-- a regular file that is readable and writable by the file's owner. Members of the file's owner may read the file. the file is world readable. -rwxr-xr-x a regular file that is readable, writable, and executable by the file's owner. The file may be read and executed by everybody else -rw-rw---- a regular file that is readable and writable by the file's owner and members of the file's owner group only Lrwxrwxrwx a symbolic link. All symbolic links have "dummy" permissions. The real permissions are kept with the actual file pointed to by the symbolic link. drwxrwx--- A directory. The owner and the members of the owner group may enter the directory and create,rename, and remove files within the directory drwxr-x--- A directory. The owner may enter the directory and create, rename, and delete files within the directory. Members of the owner group may enter the directory but cannot create, delete, or rename files who can change the the mode of a file or directory? only the file's owner or the superuser what are the two distinct ways that chmod supports to specify mode changes? octal number representation and symbolic representation octal numbers are used to set the pattern of desired permissions each digit of octal number represents three binary digits octal 0, binary 000 file mode --- octal 1, binary 001 file mode --x octal 2, binary 010 file mode -w- octal 3, binary 011 file mode -wx octal 4, binary 100 file mode r-- octal 5, binary 100 file mode r-x octal 6, binary 110 rw- octal 7, binary 111 rwx Octal (base 8) counting is done with numerals 0 to 7 hexadecimal (base 16) counting down using numerals 0 through 9 plus letters A through F binary (base2) number system only has two numerals, o and 1 bit patterns small portions of data represented on computers example RBG color displays most displays each pixel is composed of three color components, 8 bits red, 8 bits green, and 8 bits blue a medium blue would be a 24 digit number 010000110110111111001101 each digit in a hexadecimal number represents four digits in binary each digit in Octal represents 3 binary numbers a 24 digit medium blue can be condensed to a 6 digit hexadecimal number 436FCD the digits of in the hexadecimal number line up with the the bits in the binary number, the red component is 43, the green 64 and the blue CD three octal digits set the file mode for owner, group owner, and the world most common octal to binary mappings only five to memorize 7 rxw 6 rw- 5 r-x 4 r-- 0 --- symbolic representation in the form of symbolic notation for specifying file nodes symbolic notation divided in 3 parts whom the change will affect, which operation will be preformed, and which permission will be set to specify who will be affected a combination of characters u, g, o and a is used u short for user but means the file or directory owner g group owner a short for all; the combination of u, g, and 0 if no character specified then all will be assumed + permission added - permission taken away a= only the specified permissions are to be applied and that all others are to be removed advantage of using symbolic notation over octal notation symbolic notation allows one to set a single attribute without disturbing any of the others symbolic notation permissions are specified with r, w, and x characters u+x add execute permission for the owner u-x remove execute permission for the owner +x add execute permission for the owner, group, and world. equivalent to a+x 0-rw remove the read and write permissions from anyone besides the owner and group owner go=rw set the group owner and anyone besides the owner to have read and write permission. If either the group owner or world previously had execute permissions, remove them u+x, go=rx add execute permission for the owner and set permissions for the group and others to read and execute. multiple specifications may be separated by commas chmod recursive option warning --recursive option acts on both files and directories, rarely want files and directories to have the same permissions umask command controls the default permissions given to a file when it is created umask command uses octal notation to express a mask of bits to be removed from a file's mode attributes changing identities taking on the identity of another user, often for testing an account How to change
identities log out and back in as the alternative user from within our own session the su command allows? you to assume the identity of another user the sudo command allows an administrator to setup a configuration file called /etc/sudoers /ect/sudoers configuration file that defines specific commands that particular users are permitted to exectute under an assumed identity run a shell with substitute user and group ids su command is used to start a shell of another user command syntax of a login shell for a specified user su [-[1]] [user] using the -l option with su the resulting shell session is a login shell for the specified user. user environment is loaded and the working directory is changed to the user's home directory if the user is not specified with su the superuser is assumed -l can be abbreviated - how to shell for the superuser? [me@linuxbox ~]$ su - trailing # indicates this shell has superuser privileges and current working directory is now the home directory for the superuser /root pressing exit with superuser returns to the previous shell how to just execute a single command with su? su -c 'command' sudo allows allows an ordinary user to execute commands in a very controlled way user may be restricted to more or more specific commands and no others sudo does not require access to the superuser's password important difference between su and sudo sudo by default does not start a new shell, nor does it load another's user environment sudo default behavior can be modified with specifying various options, see sudo man page for the details to see what privileges are granted by sudo what option is used? sudo -l Ubuntu disables by default? disables logins to root account(by failing to set a password for the account) How does Ubuntu grant superuser privileges by default? by using the sudo command to grant superuser privileges Why does Ubuntu use sudo instead of root privileges by default? to keep people from running their operating system with su (-) root permissions at all times to avoid permission denied messages chown change file owner and group what privileges are needed to use the chown command? Superuser privileges are required changing the file owner and/or the file group owner depending on the first argument of the command chown argument: bob bob:users changes ownership of the file from its current owner to user bob and changes the file group owner to users :admins changes the group owner to admins. the file owner is unchanged bob: change the file owner from the current owner to user bob and changes the group owner to the login group of user bob to set or change a password passwd [user] passwd command enforces strong passwords, will refuse to accept ones that are too short, too similar to previous passwords or dictionary words, or are too easily guessed Sets with similar termsUnix/Linux Users and Permissions Review26 terms sarah8937 LabSim Linux+ 7.7 permissions17 terms bosteterPLUS LabSim Linux+ 7.717 terms momscookies cna 113 chapter 14108 terms jimmy_knight1 Sets found in the same folderLinux+1,545 terms karatyman76 Linux+299 terms amccabe9 Fedora and Red Hat Chapter 239 terms DarbyMason UNIX Chapter 374 terms pueppke Other sets by this creatorChapter 1 Security Fundamentals71 terms Linux47 OSI model explained like pizza delivery7 terms Linux47 Redundancy and single points of failure SY0-401 2.86 terms Linux47 Critical Systems and Components SY0-401 2.88 terms Linux47 Verified questions
COMPUTER SCIENCE How do I write a program to calculate the nth Fibonacci number? Verified answer
COMPUTER SCIENCE A program has the following definition: vector<double> numbers; The same program also has the following function: void display(double n) { cout << n << endl; } Write code that uses the STL for_each algorithm to display the elements of the numbers vector using the display function. Verified answer
COMPUTER SCIENCE Look at the following array definition. char str[10]; Assume that name is also a char array, and it holds a C-string. Write code that copies the contents of name to str if the C-string in name is not too big to fit in str. Verified answer
COMPUTER SCIENCE Say that a CFG is minimal if none of its rules can be removed without changing the language generated. Let $M I N_{\mathrm{CFG}}=\{\langle G\rangle | G$ is a minimal CFG}. a. Show that $M I N_{\mathrm{CFG}}$ is T-recognizable. b. Show that $M I N_{\mathrm{CFG}}$ is undecidable. Verified answer Recommended textbook solutionsFundamentals of Database Systems7th EditionRamez Elmasri, Shamkant B. Navathe 687 solutions
Service Management: Operations, Strategy, and Information Technology7th EditionJames Fitzsimmons, Mona Fitzsimmons 103 solutions
Information Technology Project Management: Providing Measurable Organizational Value5th EditionJack T. Marchewka 346 solutions Information Technology Project Management: Providing Measurable Organizational Value5th EditionJack T. Marchewka 346 solutions Other Quizlet setsEnzymes and Metabolism24 terms MaiMee28 Unit 9 Study Guide Questions14 terms andrewlong6 Peds Exam 4126 terms jnquiroz CH 12 Nervous System Test Practice102 terms wildj015 Related questionsQUESTION A series of related instructions that tells a computer or mobile devices the tasks to perform and how to perform them 15 answers QUESTION In Linux, to copy a file from one location to another, which command do you use? 9 answers QUESTION How is the "Disable-LocalUser" PowerShell cmdlet used? 2 answers QUESTION CPU scheduling determines which programs are in memory. 11 answers What commands would grant additional users access to use the Sudo command quizlet?You need to add an administrator to the /etc/sudoers file to give them the ability to use the sudo command.
Which command allows a standard user to run any command as another user?The su (short for substitute or switch user) utility allows you to run commands with another user's privileges, by default the root user. Using su is the simplest way to switch to the administrative account in the current login session.
What command can an administrator use to change the password of an existing user account quizlet?Chmod (Change Mode) allows the user to change the access (mode) of a file to read, write, execute, or a combination of those permissions. The passwd (password) command is used to change a Linux user's password. The chown (Change Owner) command is used to modify the file owner or group owner assignment.
Which command can you issue to find out which user account you are currently using?12.1.
You may invoke whoami to determine your current username and, hence, which computer you are using. You might also use whoami when sharing a terminal with other users. If the shared terminal has been left unattended, you can issue whoami to list the name of the user who is currently logged in.
|