What is a Capability
Computer science has no theoretical foundation within which there is a concise definition of a capability.
Here are some short attempts and dissections thereof.
- In a computer system, an unforgeable ticket, which when presented can be taken as incontestable proof that the presenter is authorized to have access to the object named in the ticket.
My description of capability and object:
An Object:
- Has state which includes:
- A c-list which is a mutable array of capabilities
- data
- Has a behavior which may include references to capabilities by index into the c-list.
- An object’s behavior may change its data and c-list.
- The objects data and behavior are not otherwise changed.
A capability
- designates an object,
- allows the holder, as part of its behavior, to send a message to the object that is designated,
- may be included in a message, whereupon the designated object holds the capability too,
- When an object is born a capability thereto is made available to the object who acted to create it.
There are primitive objects messages to which cause new primitive objects to be created and the capability to the new object returned.
This is not very satisfactory.
One can speak of call or sending a message.
The message primitive demands describing how the reply is made.
This differs in good capability systems.
A call primitive looses the similarity between the messages involved with the call and with the return.
Further not all messages are part of either.