Documentation
¶
Overview ¶
Package replica is the fill host's local cache. One sealed box. Names, URIs, logins, and material all live inside the AEAD. The wrapping key is never a file next to the box. Agents who copy replica.box get ciphertext they cannot grind (random 256-bit key, not a password). 1Password/Bitwarden encrypt the whole local vault the same way; they do not leave a device.key beside plaintext sqlite metadata.
Index ¶
Constants ¶
const ( FileName = "replica.box" Version = 1 )
Variables ¶
var ErrNotFound = errors.New("replica: key not found")
Functions ¶
Types ¶
type KeyStore ¶
KeyStore holds the 256-bit replica key off the filesystem. Mac: Keychain, this-device, fill host only. Not device.key.
type Vault ¶
type Vault struct {
// contains filtered or unexported fields
}
func Attach ¶
Attach opens the replica vault for dir under the platform keystore. A volatile keystore (VEIL_REPLICA_KEYSTORE=mem) gets an in-memory vault that never reads or writes replica.box — its key dies with the process, so any box it sealed would be unreadable next boot. On disk, a box that fails to open (stale key, corrupt bytes) is removed and re-created; origin is truth and the next pull repopulates.