Linux Today: Linux News On Internet Time.

More on LinuxToday Smart card: Understanding Permissions

Aug 19, 2000, 23:59 (0 Talkback[s])

WEBINAR: On-demand Event

Replace Oracle with the NoSQL Engagement Database: Why and how leading companies are making the switch REGISTER >

[ Thanks to Steve Emms for this link. ]

"File permissions are an important concept to understand because many users often share the resources of a Linux system. Sometimes a single Linux machine might be 'home' to hundreds of different users. Each user may want to stop others looking at their files/directories, or to share data with some/all of the other users of the systems. File permissions allow this to be possible. These permissions ensure the ability to read or write individual files is given to an authorised individual. Only the system administrator (the 'root' account) has unrestricted access to all the files. Having file permissions set correctly is an important issue for a system administrator; many systems have been compromised because of incorrectly set permissions."

"The command, "chmod" lets you change the permission mode settings of a file/directory. You also need to specify 3 digits with the chmod command. These digits dictate what permissions will be applied. The first digit determines the permissions for the owner, the second digit determines the permissions for the group, and the third for 'others'."

"To change the permissions of the file we would type:

chmod XYZ , where XYZ represents 3 digits e.g. 666

The first digit is the sum of 4 for read permission, 2 for write permission and 1 for execute permissions. So to give a file read and execute permission the digit would be 5, for read only would be 4. The same principle applies to the second and third digits."

Smart Card

Related Stories: