Which pair of commands is used to manage access control lists on a file?

Prepare for the Red Hat Certified Systems Admin Exam EX200. Enhance your skills with interactive quizzes, flashcards, and detailed explanations. Ace your certification exam today!

Multiple Choice

Which pair of commands is used to manage access control lists on a file?

Explanation:
Fine-grained access control in Linux uses ACLs to assign permissions to specific users and groups beyond the standard owner/owning group/other model. To manage these ACLs, use setfacl to set or modify ACL entries and getfacl to display them. For example, setfacl -m u:charlie:r-- file.txt grants user charlie read access without changing other permissions, and getfacl file.txt will show the current ACL entries (such as user:charlie:r--, user::rwx, group::r-x, other::r--, and any default ACLs on directories). In contrast, chmod adjusts only the basic rwx permissions, ls -l and stat show standard permissions and metadata but do not reveal or modify ACLs by default, and mount/umount relate to mounting filesystems rather than managing file permissions. So, for controlling ACL-based access, setfacl and getfacl are the correct tools.

Fine-grained access control in Linux uses ACLs to assign permissions to specific users and groups beyond the standard owner/owning group/other model. To manage these ACLs, use setfacl to set or modify ACL entries and getfacl to display them. For example, setfacl -m u:charlie:r-- file.txt grants user charlie read access without changing other permissions, and getfacl file.txt will show the current ACL entries (such as user:charlie:r--, user::rwx, group::r-x, other::r--, and any default ACLs on directories). In contrast, chmod adjusts only the basic rwx permissions, ls -l and stat show standard permissions and metadata but do not reveal or modify ACLs by default, and mount/umount relate to mounting filesystems rather than managing file permissions. So, for controlling ACL-based access, setfacl and getfacl are the correct tools.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy