Assignment 12, due Nov. 30
Part of
the homework for 22C:112, Fall 2012
|
On every assignment, write your name legibly as it appears on your University ID and on the class list! Assignments are due at the start of class on the day indicated (usually Friday). Exceptions will be by advance arrangement unless there is what lawyers call "an act of God" (something outside your control). Homework must be turned in on paper, either in class or in the teaching assistant's mailbox. Never push late work under someone's door!
The Unix file model uses an open-file table indexed by file descriptor (a small integer), where each open-tile table entry contains a pointer to an open-file data structure and the user's access rights to that file.
The link table of a Demos task, indexed by link ID, holds links, where each link enables the task that holds it to send messages to some destination task and has associated rights such as the right to duplicate a link.
These are all examples of capability-based security models. The page table, the open file table, and the link table can all be considered to be capability lists.
a) What are the primitive operations on pages, open files, and links? (Exclude composite operations, where operation c is the same as operation a followed by operation b; these composites typically exist because of the high expense of kernel calls). (0.5 points)
b) What are the access rights typically applicable to pages, to open files, and to links? (0.5 points)
c) With reference to your answers to parts a) and b), is there any sense in which these systems are distinct from each other? That is, does one support operations on capabilities that are essentially different from the others in some way, or does one have a different relation between the sets of operations and the sets of rights than the other has? (0.5 points)
A question: Whis system does the rudimentary access-controlo-list mechanism of Unix use? The easiest way to do this is to use the chmod shell command to set the user, group and other rights on an example file created for the purpose of the experiment, and see what rights you end up with for the file. (0.5 points)
Hint: Feel free to use man 2 command to get the definitions of any Unix kernel commands you might not previously have encountered. (1.0 point)