cadrumo.adapters.persistence.storage.custody.errors module¶
Typed refusals and integrity failures for profile custody.
- class ProfileCustodyRefusal(*values)[source]¶
Bases:
StrEnumStable refusal reasons exposed by the current custody contract.
- LEGACY_CUSTODY_DETECTED¶
- DEK_ROTATION_UNSUPPORTED¶
- KDF_RESOURCE_LIMIT¶
- KDF_SUPERVISION_UNAVAILABLE¶
- class ProfileCustodyRecoveryGuidance(*values)[source]¶
Bases:
StrEnumClosed operator actions accompanying a custody refusal.
- DESTRUCTIVE_RESET¶
- REENROLL_PROFILE¶
- exception ProfileCustodyError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
SecretStoreErrorBase failure for profile-scoped password custody.
- Parameters:
- Return type:
None
- code¶
- exception ProfileCustodyRecordError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
ProfileCustodyErrorRaised when a current-format custody record is malformed or altered.
- Parameters:
- Return type:
None
- code¶
- exception ProfileCustodyConcurrentCapsuleChangeError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
ProfileCustodyRecordErrorRaised when a capsule changed generation between two anchored reads.
A committed capsule always carries its label beside the commit marker that proved it. So an anchored observation that parses the marker and then finds no label member did not observe a malformed capsule – it observed a capsule being published or deleted underneath it. Separating that from
ProfileCustodyRecordErrorkeeps a caller from reporting a transient race as on-disk corruption, which is the difference between “retry the listing” and “this store is damaged”.- Parameters:
- Return type:
None
- code¶
- exception ProfileCustodyPasswordError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
ProfileCustodyErrorRaised when profile-password representation or proof is refused.
- Parameters:
- Return type:
None
- code¶
- exception ProfileCustodyRecoverySecretError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
ProfileCustodyErrorRaised when recovery-secret representation or proof is refused.
- Parameters:
- Return type:
None
- code¶
- exception ProfileCustodyRefusedError(refusal, *, context=None, recovery_guidance=(), translated_message=None)[source]¶
Bases:
ProfileCustodyErrorRaised for a deliberate, stable current-custody refusal.
- Parameters:
refusal (ProfileCustodyRefusal)
recovery_guidance (tuple[ProfileCustodyRecoveryGuidance, ...])
translated_message (str | None)
- Return type:
None
- code¶
- exception WipeTypeError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
StorageErrorRaised when the wipe primitive receives a value it cannot overwrite.
Zeroisation needs a mutable buffer; handing it an immutable
bytesis a programming error whose damage is silent, because the caller believes key material was wiped when nothing was touched. The typed storage surface propagates it through domain boundaries; callers should catchWipeTypeErrorrather than a builtinTypeError.- Parameters:
- Return type:
None
- code¶