diff --git a/knowledge base/acl.md b/knowledge base/acl.md index cb32301..a6bb238 100644 --- a/knowledge base/acl.md +++ b/knowledge base/acl.md @@ -17,9 +17,10 @@ BSD systems use NFSv4 ACLs by default in ZFS. List of **NFSv4** [permission tags][syntax descriptions for setting acls] and [inheritance options][acl inheritance]. ```sh -# Install the tool. +# Install the tools. apt install 'acl' dnf install 'acl' +zypper install 'acl' # Show ACLs. getfacl 'path/to/file' @@ -127,11 +128,15 @@ setfacl -a '5' 'everyone@:r-x---a-R-c---:-d-----:allow' 'path/to/dir' - [`setfacl` FreeBSD manual page][setfacl freebsd manual page] - [Syntax descriptions for setting ACLs] - [ACL inheritance] +- [`chmod`][chmod] for how to force new files to be owned by specific users or groups + +[chmod]: chmod.md + [access control lists (acl) in linux]: https://www.geeksforgeeks.org/access-control-listsacl-linux/ [acl inheritance]: https://docs.oracle.com/cd/E19253-01/819-5461/gbaax/index.html diff --git a/knowledge base/chmod.md b/knowledge base/chmod.md index 8034553..687851c 100644 --- a/knowledge base/chmod.md +++ b/knowledge base/chmod.md @@ -9,10 +9,12 @@ chmod 'u=rw' "path/to/dir" chmod 'go+x' "path/to/file" # Set 'setuid' bit. +# Set on directories, forces new files to be owned by the same user by default. chmod '04755' "path/to/dir" chmod 'u-s' "path/to/file" # Set 'setgid' bit. +# Set on directories, forces new files to be owned by the same group by default. chmod '02775' "path/to/dir" chmod 'g+s' "path/to/file"