lib.ec.secret_store.Sops: Add store class #148
Loading…
Reference in a new issue
No description provided.
Delete branch "jan/feature/20261017-lib-ec-secret-store-sops-add-store-class"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
lib.ec.secret_store.Sops: Add store class
This commit adds a new class inheriting from
secret_store.Base: Sops. The currently available classes allow to store secrets offline in a GPG-encrypted tarball, but those are not versioned. This commit allows to use aSOPS/ AGE-encrypted Git repository as storage backend instead.The additions in detail:
JW_SECRETS_SOPS_REPO,get()on an entry returns the decrypted serialized content, and a typed put (FT_SECRET) re-encrypts the entry wholesaleJW_SECRETS_SOPS_KEY_PATHonly: the house variable is the sole input to the store, andSOPS_AGE_KEY_FILEis set on the sops subprocess per invocation, never read from the process environment; SopsKeyError is raised when the variable is not setFileContext.create(): the sops:// scheme