PROPHET/OS

NAME

rng: shows the sources of chance with their precedence and what each one delivered

SYNOPSIS

rng [--tui]

DESCRIPTION

Shows the sources of chance with their precedence and what each one delivered.

It shows the service and does not become one. No draw happens here: the tool declares no right to randomness, and what hands out values stays POS_SEC_RANDOM and /state/rng. A view that drew in order to show what a draw looks like would change the thing it reports, because the health tests run on the sequence the service really saw.

The title says what the service as a whole did: how many values it drew, how many draws came up empty, how often it climbed back up a step, and whether it is healthy. A draw that came up empty returned a zero to its caller, counted and said once, because a source that lies is more dangerous than one that says no.

One row per source, highest precedence first. Prio is the priority the registry chooses by: the highest whose probe confirms the hardware wins, and priority 0 is the fallback that says yes on every machine.

Role says what a source is to the service right now.

| Word | What it means | |---|---| | takes | the service draws from this one | | stands by | it would carry, and something above it does | | left | the service descended from it and can climb back | | missing | this machine does not have it, and Note says why | | locked | somebody took it out of the choice by hand |

H/1000 is what the source says about itself, the min-entropy per sample in thousandths of a bit. Both bounds of the health tests after NIST SP 800-90B follow from it, and that computation stands in os/include/rng/rng.h.

Drawn and Lost are booked per source, not for the service as a whole. That is the question rule 5 raises: a chain that descended delivers from somewhere else, and one counter for all sources cannot say from where. Lost counts the draws at that source that brought nothing usable, both the ones that ran out their deadline and the ones whose sample a health test rejected. Fell counts how often the service left the source, Back how often it climbed to it again.

Note carries the quality class of what the source hands out, or, where the source is not here at all, the reason it gave: a class nobody can draw from says less than the sentence saying why.

--tui takes the whole screen and keeps the table live; the arrows and the two page keys move in it, q leaves. Both shapes show the same table, and that is why they cannot drift apart: it stands once, in lib/os/board.c.

EXAMPLE

$ rng
the service rng: 387 value(s) drawn, 0 draw(s) that came up empty, 0 climb(s) back up, healthy
Source         Prio Role      H/1000     Drawn   Lost Fell Back Note
rng.infnoise     30 missing    64000         0      0    0    0 not asked, channels 0
rng.rdseed       20 takes      64000       387      0    0    0 64 bit, full entropy
rng.rdrand       10 stands by  64000         0      0    0    0 64 bit, full entropy
rng.virtio        5 missing    64000         0      0    0    0 no virtio transport on thi
rng.jitter        0 stands by  64000         0      0    0    0 64 bit, full entropy

SEE ALSO

irqs, serves, mods, state