Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Use touch to create a file named dog in the working directory. Use is to con- firm the file was created. 2. Use ls

image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
1. Use touch to create a file named dog in the working directory. Use is to con- firm the file was created. 2. Use ls -1 (Sobell, page 199) to display the permissions of the file you just cre- ated. Who owns the file? Which group is it associated with? Which permissions does the owner of the file have? The group? Others? 3. Display the permissions of /bin/bash. Who owns the file? Which group is it associated with? Which permissions does the owner of the file have? The group? Others? Which permissions apply to you? I 4. Only the owner of a file for a user working with root privileges) can change the permissions of a lile. Using numeric arguments to chmod (Sohell. page 201). change the permissions of the file you created in step 1 so the owner has read and write permissions and the group and others have no permissions. Next change the permissions so the owner, the group, and oth- crs have only read permissions. Display the permissions of the file hefore you start and after each change. 48 SOBELL LAB MANUAL 5. Determine the permissions of various files and directories on the system. Fill in the following chart: Filename Readable by Writable by Executable/ Symbolic type Octal searchable by and permissions permissions none |-rw-r--- 644 /etc/passwd owner (root), owner (root) group (root), and others /etc/shadow /etc/cups/cupsd.conf Nar/log/audit Nar/log/cups /etc/cups/ssl Nar/spool/mail /var/spool/cron /dev/tty1 /bin/chmod /usr/bin/procmail usr/bin/locate just bin/crontab 6. Change permissions of files. a. Make the Unit2/reports/report.feb file readable by the owner and group, writable by the owner only, and not accessible by others. b. Create a subdirectory in /tmp named shared. The file should be owned by ben and associated with the group named linux. The user named ben and the owner of the directory and members of the linux group should have read, write, and execute (scarch) permission to the directory. Other users should have no access. (Tip: Run these commands as the user ben.) Working as student once again, list the permissions and ownership infor- mation of the new directory. c. Working as the user named max. create a file named max I in the /tmp/shared directory. Then, once again working as the user named stu- dent, display your effective UID and then attempt to create a file named student in /tmp/shared. The touch utility will display a Permission denied error. d. Make sure you are working as student. If you are not, give an exit com- mand and check again. 7. The permissions of a new file are determined by the file permissions mask that is set by the umask utility (Sohell, page 459). a. Working as the user named student, display the value of the file permis- sions mask h. Create a new file named mask.one and display the permissions. I c. Change the file permissions mask to 077 and then create a file named mask.wo. Display the permissions of the new lile d. Create a new directory named masks and display the permissions of the new directory & Optional: Repeat the procedure in step 7 for other le permissions masks such as 027.022 and 777 9. Reset the permissions mask to 002

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Repairing And Querying Databases Under Aggregate Constraints

Authors: Sergio Flesca ,Filippo Furfaro ,Francesco Parisi

2011th Edition

146141640X, 978-1461416401

More Books

Students also viewed these Databases questions

Question

3 How the market system answers four fundamental questions.

Answered: 1 week ago

Question

5 The mechanics of the circular flow model.

Answered: 1 week ago

Question

1 The difference between a command system and a market system.

Answered: 1 week ago