Keys
You hold every private key a vault depends on. Octet receives public keys only. This page describes each key, who holds it, and what happens when it changes or is lost.
| Key | Algorithm | Held by | What it does |
|---|---|---|---|
| Recipient key | X-Wing | You | Every object is sealed to it. It is the only key that opens your objects. |
| Owner key | Ed25519 | You, in a file or on a YubiKey | Signs each recipient key and the delegation root, so a key you did not sign stands out |
| Custodian keys | X-Wing | Your custodians | Each holds one share of a recipient key's backup |
| Delegation root key | Ed25519 | You | Signs the delegations you give auditors |
| Auditor key | X-Wing and Ed25519 | The auditor | Opens what you grant the auditor, and signs the auditor's requests |
Key files
keygen, owner keygen, auditor keygen and delegation root keygen each write a key file. The private key in it is encrypted under a key derived from your passphrase with Argon2id. The passphrase needs at least 12 characters. The file is written readable by its owner only. The CLI asks for the passphrase, or reads it from a file or an environment variable named for the kind of key, such as --key-passphrase-file or OCTET_VAULT_KEY_PASSPHRASE for a recipient key (see Passphrases).
Security keys
A key file can also require a FIDO2 security key. It then opens only with the security key and the passphrase together, so a copied file or a leaked backup is useless without the security key, however good a guess at the passphrase.
keygen --fido2enrolls a security key when it creates a recipient key.key wrap <file> --out <new file> --fido2writes a copy of an existing key file, of any kind, that needs a security key, and leaves the original as it is. Repeat--fido2to enroll several security keys, one after the other. Any one of them opens the file.- By default the file has no entry that opens with the passphrase alone.
--keep-passphrasekeeps one, and the CLI then opens the file with the passphrase alone. - For a file without that entry, every command that opens the file asks for the passphrase, then for the security key's PIN and a touch. Commands that use no key file, such as
list,fetch,verify-logandmonitor, run unattended as before. - The CLI talks to the security key through
ykman, from yourPATH, the--ykmanoption or theOCTET_VAULT_YKMANenvironment variable. It works with any FIDO2 security key over USB, and uses only the key's FIDO2 application. - The portal's Open and verify page opens the same file with the same security key (see Export and Verify Offline).
key unwrap-info <file>lists how a key file opens, without asking for any secret.key info <file>shows the same, with the key's fingerprint and, with a token, its key ID in the vault.
The security key does not open objects itself. The CLI still decrypts the private key on your computer, and uses it there.
Once every enrolled security key is lost, a file without a passphrase-only entry can't be opened. For a recipient key, split a recovery backup when you create the key (see Recovery shares), or keep a passphrase-only entry.
Recipient keys
The vault seals each new object to its one active recipient key. A key's ID has the form ovk-<year>-<month>-<8 hex digits>, and its fingerprint is the SHA-256 of its public key.
key list prints every recipient key of the vault: its ID, fingerprint, state, registration time, and whether your owner key signed it.
Registering a key proves that you hold it. The vault encrypts a random challenge to the new key, and register opens it and returns it. Only then does the key become active.
A key moves through these states:
| State | Meaning |
|---|---|
pending |
Registered, waiting for the proof of possession |
active |
New objects are sealed to it |
retired |
Receives no new objects, and still opens the objects sealed to it |
revoked |
Reported compromised. The vault never seals to it again, and keeps it listed so you can find the objects sealed to it. |
Registering a new key retires the previous active one. Keep every key file you have ever registered: a retired key is the only key that opens the objects sealed while it was active.
Destroying a key destroys its objects. If you destroy every copy of a retired private key, every object sealed to it becomes permanently unreadable, in every copy Octet holds. It is the only way to make a write-once object unreadable before it expires (see Retention and Deletion). To destroy the active key, register a new one first, so the old one is retired.
The owner key
The owner key gives each recipient key your signature. Without it, you would rely on Octet alone to seal to the key you registered. With it:
- every recipient key in the vault's key list carries your signature, and
monitorflags an active key without one; - the vault refuses a recipient key with an invalid owner signature;
- every owner-key change is a log event that
monitorreports unless you expected it.
You can keep the owner key in a YubiKey's PIV applet, where it never leaves the YubiKey. That needs a YubiKey 5 with firmware 5.7 or later, which supports Ed25519.
To replace the owner key, sign the new one with the current one (owner replace). Recipient keys signed by the old owner key stay valid. If you lose the owner key, Octet can reset it on your request. The reset is a log event with a reason code, and every recipient key then needs your signature with the new owner key (owner sign-key).
Recovery shares
keygen --recovery 2-of-3 splits a new recipient key among custodians while it is created. Each custodian receives one share, encrypted to their own key. Any two of the three can restore the key, and one alone learns nothing about it. Each share is checked before it is used, so a wrong or damaged share is named, not silently combined. See Recover a Recipient Key.
Delegation and auditor keys
To let an auditor read and open chosen objects, your owner key certifies a delegation root key, and the root key signs each delegation. The owner key stays offline while you create, narrow and revoke delegations.
The auditor creates one auditor key file. It holds two keys from one seed: an X-Wing key that what you grant is encrypted to, and an Ed25519 key that signs every request the auditor makes. The auditor sends you only the public half, auditor.pub.json. See Delegate to an Auditor.
Losing a delegation root key or an auditor key loses no data: nothing is sealed to either. Create a new one and certify or delegate again.