[vault] Hands off: take_over a machine-key vault, the no-auto-connect, no-unattended and card-signing items, notes with a detail, the unattended rules; v0.13.0
This commit is contained in:
@@ -10,6 +10,13 @@ on, Custos writes it as v2 only.
|
||||
A **machine store** (the Claude Code store) is the one exception: a separate file whose vault key is
|
||||
wrapped by one device key alone, so a program can open it unattended. It never holds the user's secrets.
|
||||
|
||||
**Taking over a machine-key vault** (core 0.13.0, Custos's hands-off vault): `Vault::take_over(password)` adds the
|
||||
master password as a factor paired with the device key and removes the single slot, in one step. From then on it is
|
||||
an ordinary version-2 vault: two factors open it, the device key alone does not, and factors are added as for any
|
||||
vault (a phone, a TOTP backup). Only a machine-key vault is taken over, and only once; `opens_with_machine_key()`
|
||||
says which it is. The take-over also ticks `no-auto-connect`, `no-unattended` and `card-signing` and writes
|
||||
`taken-over` (FORMAT.md, "The security member").
|
||||
|
||||
## Keys
|
||||
|
||||
```
|
||||
|
||||
+12
-3
@@ -181,7 +181,7 @@ an outcome; a code the server then refuses (its exit 10) is not seen by Custos,
|
||||
- Readers ignore members of an entry they do not know. A file whose `provision` has an `outcome`, `direction` or
|
||||
`store` this core does not know does not open (`Corrupted`), as for `signing`.
|
||||
|
||||
### The security member (core 0.12.0)
|
||||
### The security member (core 0.12.0; hands-off values 0.13.0)
|
||||
|
||||
```json
|
||||
"security": {
|
||||
@@ -202,9 +202,9 @@ an outcome; a code the server then refuses (its exit 10) is not seen by Custos,
|
||||
| :-- | :-- |
|
||||
| `setup` | optional: the last Setup window, Unix milliseconds; `until` is 2 hours after `started` |
|
||||
| `finished` | optional: when that window ended, by *Finish setup*, or `until` once its expiry was noticed |
|
||||
| `ticked` | the checklist items that are ticked: `totp-on-phone`, `hello-approvals`, `narrow-scope`, `rotate-setup`, `no-ssh`, `phone-approves` |
|
||||
| `ticked` | the checklist items that are ticked: `totp-on-phone`, `hello-approvals`, `narrow-scope`, `rotate-setup`, `no-ssh`, `phone-approves`, and (core 0.13.0) `no-auto-connect`, `no-unattended`, `card-signing` |
|
||||
| `keptScope` | optional: the server scope prefixes *Narrow the server scope* replaced (`ask`, `offer`: at most 64 each, 1–200 characters, no control characters), kept for its undo |
|
||||
| `audit` | `{at, action, item?, auth?}`; `action` is `setup-started`, `setup-finished`, `setup-expired`, `ticked`, `unticked`, `ssh-connected` or `totp-moved`; `item` a checklist item (with `ticked`, `unticked`); `auth` is `hello` or `password` (with `unticked`) |
|
||||
| `audit` | `{at, action, item?, auth?, detail?}`; `action` is `setup-started`, `setup-finished`, `setup-expired`, `ticked`, `unticked`, `ssh-connected`, `totp-moved`, or (core 0.13.0) `auto-connected`, `unattended-stored`, `setup-item-removed`, `unattended-signed`, `taken-over`; `item` a checklist item (with `ticked`, `unticked`); `auth` is `hello` or `password` (with `unticked`); `detail` (core 0.13.0, the four notes) names what happened, never a value: 1–500 characters, no control characters |
|
||||
|
||||
The **level** is computed, never stored:
|
||||
|
||||
@@ -218,6 +218,15 @@ the first change after it, not by reading.
|
||||
|
||||
- **Append-only** like `provision`: the API adds entries and lists them; the log keeps the newest 5 000.
|
||||
- Absent while nothing was ever set, so a vault without it is written exactly as before.
|
||||
- The values new in core 0.13.0 make a vault unreadable for a core before 0.13.0 once one is written, as the
|
||||
0.12.0 values did before.
|
||||
- **Hands-off rules** (core 0.13.0, `security`): `is_setup_run` (`setup-` and 1–58 of `[A-Za-z0-9._-]`),
|
||||
`auto_connect_allowed` (not Hardened, neither `no-auto-connect` nor `no-ssh`), `setup_on_connect` (neither
|
||||
`no-unattended` nor `no-ssh`), `unattended_provision` (in Setup, a setup run, `no-unattended` not ticked, never an
|
||||
existing item: an `ask --generate` or an `offer` into `arca/`, `custos/`, `fabrica/`, `aula/`, `gitea/`, an offer
|
||||
into the Claude Code store, a TOTP offer unless `totp-on-phone`; never `display`) and `unattended_sign` (a
|
||||
machine-key vault, a request with a run, not Hardened, `card-signing` not ticked, the kinds `minisign`,
|
||||
`manifest`, `authenticode`, `approval`). The app enforces them; the server never decides.
|
||||
- Readers ignore members they do not know. A file whose `security` has an item, action or auth this core does not
|
||||
know, a window whose `until` is not after `started`, `finished` without `setup`, or a kept scope that breaks the
|
||||
rules above does not open (`Corrupted`).
|
||||
|
||||
Reference in New Issue
Block a user