File Descriptor - File Descriptors As Capabilities

File Descriptors As Capabilities

Unix file descriptors behave in many ways as capabilities. They can be passed between processes across Unix domain sockets using the sendmsg system call. Note, however, that what is actually passed is a reference to an "open file description" that has mutable state (the file offset, and the file status and access flags). This complicates the secure use of file descriptors as capabilities, since when programs share access to the same open file description, they can interfere with each other's use of it by changing its offset or whether it is blocking or non-blocking, for example. In operating systems that are specifically designed as capability systems, there is very rarely any mutable state associated with a capability itself.

A Unix process' file descriptor table is an example of a C-list.

Read more about this topic:  File Descriptor

Famous quotes containing the words file and/or capabilities:

    A common and natural result of an undue respect for law is, that you may see a file of soldiers, colonel, captain, corporal, privates, powder-monkeys, and all, marching in admirable order over hill and dale to the wars, against their wills, ay, against their common sense and consciences, which makes it very steep marching indeed, and produces a palpitation of the heart.
    Henry David Thoreau (1817–1862)

    I maintain that I have been a Negro three times—a Negro baby, a Negro girl and a Negro woman. Still, if you have received no clear cut impression of what the Negro in America is like, then you are in the same place with me. There is no The Negro here. Our lives are so diversified, internal attitudes so varied, appearances and capabilities so different, that there is no possible classification so catholic that it will cover us all, except My people! My people!
    Zora Neale Hurston (1891–1960)