aeat.adapters.persistence.storage.bucket package¶
Per-bucket directory model under <aeat-root>/buckets/<bucket-id>/.
Pydantic v2 strict records, error types, and filesystem primitives that compose
the multi-bucket on-disk layout. The facade exposes
BucketPaths / bucket_paths() /
provision_bucket_directory() for the db/, blobs/, and
audit/ tree; BucketManifest,
ManifestKdfParams, BucketKeySchedule, and
BucketLifecycleStatus for the plaintext manifest; and
read_manifest() / write_manifest() for strict TOML I/O.
The manifest is discovery metadata only: bucket identity, operator label,
UTC timestamps, public Argon2id KDF parameters and salt, recovery-enrollment
state, idle-lock setting, key schedule, schema version, and lifecycle mirror.
It must not contain passphrases, derived keys, wrapped DEKs, recovery secrets,
taxpayer payloads, or secure-object ciphertext. Keystore helpers
(keystore_root(), keystore_path(), and
validate_keystore_separation()) enforce that custody material lives
outside the buckets/ tree and the per-bucket database directory.
The sealed-archive surface re-exports ExportArchiveHeader,
SealedArchiveContents, write_sealed_archive(), and
read_sealed_archive() for application-level bucket export/import. These
helpers own archive shape and metadata normalisation only; profile payload
composition remains in application.user_profile, while
application.bucket_maintenance orchestrates operator-facing export
and import.
See also
BucketManifestStrict per-bucket manifest record stored beside the bucket directory.
ExportArchiveHeaderPlaintext frontmatter for sealed bucket-export archives.
write_sealed_archive()Host-metadata-normalising writer for sealed export archives.
read_sealed_archive()Reader that validates archive member order and header shape before returning encrypted payload bytes.
application.bucket_maintenanceApplication service facade that composes these archive primitives with profile lifecycle and domain event history.
Submodules¶
- aeat.adapters.persistence.storage.bucket._errors module
- aeat.adapters.persistence.storage.bucket._export_header module
- aeat.adapters.persistence.storage.bucket._keystore_paths module
- aeat.adapters.persistence.storage.bucket._layout module
- aeat.adapters.persistence.storage.bucket._lockfile module
- aeat.adapters.persistence.storage.bucket._manifest module
- aeat.adapters.persistence.storage.bucket._manifest_io module
- aeat.adapters.persistence.storage.bucket._output_language_hint module
- aeat.adapters.persistence.storage.bucket._sealed_archive_errors module
- aeat.adapters.persistence.storage.bucket._sealed_archive_reader module
- aeat.adapters.persistence.storage.bucket._sealed_archive_writer module