PlantedPassRig

interface PlantedPassRig

The forging half of a ReturnHarness (#3710): devices whose Proof carries passes a row chose, and the passes to put there.

A row asks for a fresh device, which has never held a pass, and has its one Proof carry a pass that is good in every respect but the one the row changes. Every row asserts its rig fired: newDevice's planter was asked once, for a Proof the room itself put no pass in, and returned exactly one pass. A control row plants a pass with nothing wrong with it and expects the device in without its policy being asked, so a rig that drops what the planter returns reds there, not as a host refusing it.

Functions

Link copied to clipboard
abstract suspend fun hostPass(subject: DidKey, scope: GrantScope): Grant

A pass the host's own key signs, letting subject back into scope: issued at the host's now and good on the host's clock for at least an hour, so the only thing wrong with it is what a row put there.

Link copied to clipboard
abstract suspend fun newDevice(planter: PassPlanter): ReturnDevice

A new device, as ReturnHarness.newDevice makes, except that every Proof its rooms send also carries what planter returns for it, after the passes its room chose to present.

Link copied to clipboard
abstract suspend fun strangerPass(subject: DidKey, scope: GrantScope): Grant

As hostPass, but signed by a key that is not the host's and that the host does not trust.