|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
Unix Permissions on CSUN Accounts |
||||||||||||||||||||||||||||||||||||||||||||||||||||||
There are user-changeable permissions assigned to every directory and file in a campus Unix account that specify who has read, write, or execute privileges. Separate permissions are assigned to the user (i.e., you, the account owner), the group to which the user belongs (normally a department, such as Geography), and "other" (i.e., anyone in the world). This document provides a brief overview to help you understand the permissions associated with your account. Viewing and Understanding PermissionsYou can view the permissions that are set for the directories and files in your account by typing the following command at the prompt: ls -al where ls means "list" and -al modifies the list request to include "all" files (including those preceded with a dot) in the "long" format (which includes permissions). The resulting list of files and directories will appear in the following format: -rwxr--r-- # userID group size date time filename The ten characters in the first column shows the permissions for the designated file or directory name. The remaining columns give information such as userID (i.e., your login account), the group abbreviation (e.g., geog for Geography), the size of the file or directory, the date and time it was last modified, and the name of the file or directory. In the permissions column, the first character indicates the entry type. File listings begin with a hyphen; directory listings, with the letter d. The remaining nine characters indicate the permissions themselves (in three groups of three). Character positions 2 thru 4 show user permissions — read (r), write (w), and/or execute (x); 5 thru 7, group permissions; and 8 thru 10, other permissions. A hyphen in a character position indicates a lack of permission for that item. Table 1 and Table 2, below, describe what the various permissions mean for the user, the group, and others. TABLE 1. Unix Directory Permissions
In the example at the beginning of this section, the permissions for the directory listing are shown as: drwxr-xr-x which indicates that the user has read, write, and execute priviliges and that the everyone else (group and other) has read and execute privileges. However, they cannot create or delete files in the directory. TABLE 2. Unix File Permissions
In the example at the beginning of this section, the permissions for the file listing are shown as: -rwxr--r-- which indicates that the user has read, write, and execute priviliges and that everyone else (group and other) can only read the file. They cannot modify or delete the file or run it as a program. Standard Permissions SettingsThe standard settings for files and directories in a typical CSUN account are as follows.
These settings give the account owner (user) read, write, and execute access to directories and read and write access to files. Group members and others have no access at all. Changing PermissionsThe most common reason for changing account permissions on a CSUN Unix account is to allow access to Web pages that are published there. Refer to Commands for Publishing Web Pages to a Campus Account ("Setting Up Your Account") for instructions. Otherwise, there is typically no need for the average account owner to change the default permissions on an account, and, in fact, it may be detrimental to do so. You might inadvertently "lock yourself out" of your own account or unintentially allow access to "the world". |
||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
August 14, 2003 |
Prepared by Gail Said Johnson, User Support Services |
|||||||||||||||||||||||||||||||||||||||||||||||||||||
ITR's technology training guides are the property of California State University, Northridge. They are intended for non-profit educational use only. Please do not use this material without citing the source. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||