Grants of the root service
The root service starts the programs and gives each one only the handles of its role.
What a program receives at its start
| Place | Grant | What the root service gives |
|---|---|---|
| 0 | Root_Ring | Start and stop programs. |
| 1 | Inspect | The machine, with the right Inspect. |
| 2 | Stop | The machine, with the right Stop. |
| 3 | Image | Read the boot image. |
| 4 | Log_Records | Read the records of the log. |
| 5 | Serve | A service: other programs call its exports through connections. |
| 6 | Terminal | The program has no surface: it writes records to a terminal, and reads keys from it. |
| 7 | Store | A private store in the storage service: a connection to it names the program, with a limit of blocks. |
| 8 | Person | The program acts for the person: a service shows it what it holds for all callers. |
| 9 | Data_Disk | A block service of the data disk, and its block ring. |
| 10 | Scratch_Disk | A block service of the disk of the measures, and its block ring. |
| 11 | Replacements | Read the replacement table of the machine. |
| 12 | Replace | Change the replacement table of the machine (Root_Command.Replace). |
| 13 | Network | An endpoint in the network service, with the grant of endpoint_of: datagrams, or segments of TCP. |
| 14 | Network_Device | The frame service of the network device and its frame ring, and a control ring from this service. |
| 15 | Connect | A ring to this service that serves Connect and Disconnect only, to the services of callable_of. |
| 16 | Schedule | The machine, with the right Schedule: change the scheduling strategy of the machine. |
| 17 | Settings | The settings page with Write (contract:settings): the one writer of the settings of the person. |
| 18 | Clock | The date page with Write and the two ports of the real-time clock (contract:date): the one writer of the date. |
| 19 | History_Store | A store of its own in the storage service for the line history of the program, apart from its private store (Root_Command.Connect_History). |
Read from programs/root/main.odin.
What the root service records and can revoke
| Bit | Grant | Name in the console | What it gives |
|---|---|---|---|
| 0 | Log | log | Write on the log. |
| 1 | Machine | machine | The machine, with the rights of the role. |
| 2 | Image | image | Read the boot image. |
| 3 | Log_Records | log_records | Read the records of the log. |
| 4 | Store | store | A private store in the storage service. |
| 5 | Network | network | An endpoint of datagrams in the network service, with one remote. |
| 6 | Person | person | To act for the person in each service that the program is connected to (isolated.CALLER_PERSON). |
| 7 | History | history | The store of the line history of the console in the storage service (Root_Command.Connect_History). |
Read from support/system/grants.odin.
The grants of each program
| Programs | Grants | Why, as the root service says |
|---|---|---|
console | {.Root_Ring, .Inspect, .Stop, .Image, .Terminal, .Store, .Person, .Replacements, .Replace, .History_Store} | |
flood | {.Terminal} | |
inspect | {.Inspect, .Image, .Serve} | A developer tool: it reads the reports of the machine and the names of the modules, and serves the same facts (docs/TOOLS.md). |
monitor | {.Inspect, .Serve} | It serves programs() and counts() to a caller that acts for the person. |
processors, pages, flow, crowd, clock | {.Inspect} | |
rights | {.Inspect, .Image} | It shows what the kernel refuses. |
pointers | {.Image} | It reads the pointer themes in the resource table of the boot image. |
log | {.Log_Records, .Serve} | It serves records() to a caller that acts for the person. |
boot | {.Inspect, .Image} | It shows the modules of the boot image. |
rings | {.Image} | It starts its nodes from the boot image. |
frames | {.Inspect, .Image} | It reads its own page table, and starts its twins from the boot image. |
locks | {.Inspect, .Image} | It reads the counts of the locks, and starts its lockers from the boot image. |
address_space | {.Inspect, .Image} | It reads its own mappings, and starts its child from the boot image. |
scheduler | {.Inspect, .Schedule} | It reads the counts of the scheduler, and changes the strategy. |
paint, life, tally, sample | {.Serve} | sample: the module of the tables, started as a program when a caller connects. |
settings | {.Settings, .Serve, .Store} | It writes the settings of the person, keeps them in its private store, and serves set() and get(). |
date | {.Clock, .Serve} | It reads the real-time clock, writes the date page, and serves now(). |
manual | {.Serve, .Image, .Replacements, .Inspect} | It reads the documentation of each module of the boot image, and the module records of each program. |
disk | {.Scratch_Disk} | |
storage | {.Serve, .Data_Disk} | |
notes | {.Store} | |
errors | {.Store, .Image, .Inspect, .Connect} | It makes errors in its store, loads modules and starts fault from the boot image, counts the locks, and asks for connections that the root service refuses (callable_of gives it none). |
imports | {.Inspect, .Image} | It loads modules of the boot image, and measures with the cycle counter. |
cryptography_vectors | {.Image} | It reads the hash of the module cryptography in the boot image. |
net | {.Inspect, .Network} | It measures with the cycle counter. |
server | {.Network, .Serve, .Store} | A listen grant, its exports for the console, and its pages in its private store. |
fetch | {.Network} | |
quic_echo | {.Network} | A listen grant of UDP: QUIC in the program, the module cryptography through its imports. |
network | {.Network_Device} | |
remote | {.Connect, .Network, .Person} | The calls of the host: an endpoint whose grant names the host, connections to the services of callable_of, and the grant to act for the person (docs/MODULE_CONTRACT.md, "A call from the host"). |
interface_through_module | {.Image} | It reads the size of the code of interface_module. |
tables | {.Image, .Connect} | It loads sample, starts a call host of it from the boot image, and connects to the service sample (docs/MODULE_CONTRACT.md, "Tables and bytes as parameters"). |
| Each other program | {} |
Read from programs/root/main.odin.
