From 2b28fea2626c73aa02c4f97b38c9fc1a1de28ca5 Mon Sep 17 00:00:00 2001 From: touhonoob Date: Tue, 13 Dec 2016 22:50:24 +0800 Subject: [PATCH] setfacl: add page --- pages/linux/setfacl.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 pages/linux/setfacl.md diff --git a/pages/linux/setfacl.md b/pages/linux/setfacl.md new file mode 100644 index 000000000..f6cd1db56 --- /dev/null +++ b/pages/linux/setfacl.md @@ -0,0 +1,19 @@ +# setfacl + +> Set file access control lists. + +- Modify ACL of a file for user with read and write access: + +`setfacl -m u:{{username}}:rw {{file}}` + +- Modify default ACL of a file for all users: + +`setfacl -d -m u::rw {{file}}` + +- Remove ACL of a file for an user: + +`setfacl -x u:{{username}} {{file}}` + +- Remove all ACL entries of a file: + +`setfacl -b {{file}}`