What is the difference between SUID and SGID?
In computing, umask is a command that determines the settings of a mask that controls which file permissions are set for files and directories when they are created. It also refers to a function that sets the mask, and to the mask itself, which is formally known as the file mode creation mask.
What is the default umask value for useradd command and where is it defined?
Default umask value for useradd: 077
Modifying ACL using setfacl : To add permissions for a user (user is either the user name or ID):
Observe the difference between output of getfacl command before and after setting up ACL permissions using setfacl command. There is one extra line added for user mandeep which is highlighted in above.
From Linux man pages, ACLs are used to define more fine-grained discretionary access rights for files and directories.
Observe the first command output in , there is extra “+” sign after the permissions like -rw-rwxr–+, this indicates there are extra ACL permissions set which you can check by getfacl command.
Using Default ACL : The default ACL is a specific type of permission assigned to a directory, that doesn’t change the permissions of the directory itself, but makes so that specified ACLs are set by default on all the files created inside of it. Let’s demonstrate it : first we are going to create a directory and assign default ACL to it by using the -d option:
Watch this Linux Interview Questions And Answers Video on YouTube:
Linux is an open-source operating system based on UNIX. It was named after the founder “Linus Torvalds”. He introduced Linux with the primary goal to offer an operating system at a free or very reasonable price for users. It is based on the Linux kernel and is compatible with different hardware platforms such as Intel, MIPS, HP, IBM, SPARC, and Motorola hardware platforms. Linux’s mascot, a penguin named Tux, is another popular feature. Linux offers a user-friendly environment where they can easily modify and create variations in the source code.
Why ACL is used in Linux?
How do you check ACL rules in Linux?
How do I use ACL for directory in Linux?
How do I check ACL permissions in UNIX?