common_auth.stores.security
Injected secret protection; no key discovery or secret-manager integration.
Classes
AesGcmProtector
AES-GCM with a supplied key, fresh nonce and authenticated row context.
Carries the cipher only. Keys are neither loaded nor serialized. Persisted values include a format byte and nonce, never the key. Key rotation is an explicit migration: an old row must remain decryptable until re-encrypted.
__init__
def __init__(key: bytes | SecretBytes) -> Noneopen
def open(value: bytes, *, context: bytes) -> bytesseal
def seal(value: bytes, *, context: bytes) -> bytesProtector
Bases: Protocol
Authenticated encryption bound to the supplied record context.
open
def open(value: bytes, *, context: bytes) -> bytesseal
def seal(value: bytes, *, context: bytes) -> bytes