Most of the resources available on a UNIX system are accessed as though they were files.
In addition to traditional hard disk files containing data, the operating system treats devices (like printers and modems) as special kinds of files.
The commands you use to work on the system are executable programs accessed as files.
Even network connections can be treated as special types of files.
Thus, a clear understanding of the basic attributes of files extends to an understanding of how access to a wide class of system resources is managed.
In this module, we will investigate the access control primitives of the UNIX system. The system is based on a notion of ownership,
together with a set of access permissions.
At the completion of this module, you will be able to:
Describe the central role that files play in the UNIX environment
List the principles of file and directory ownership
Set user and group ownership
Explain how UNIX grants access to files and directories
Set file and directory access permissions
To make a script file executable, add the execute permission to the access permissions for the file. To do so, use the chmod command.
The syntax and function of the chmod command are as follows.