Encryption algorithm
Enclave uses AES-256-GCM (Advanced Encryption Standard, 256-bit key, Galois/Counter Mode).- AES-256 — the symmetric cipher. 256-bit keys are currently unbreakable by brute force.
- GCM — the mode of operation. Provides both confidentiality (encryption) and integrity (authentication tag). Any tampering with the ciphertext is detected on decryption.
Encryption happens on your device
The encryption step runs in the client (browser or desktop app) before any data is transmitted. The Enclave server receives only ciphertext.Key hierarchy
| Key | Where it lives | Who can access |
|---|---|---|
| Master Key | Your KMS / HSM | You only |
| KEK | Enclave (encrypted, wrapped by master key) | Derived on demand by authorised clients |
| DEK | Enclave (encrypted, wrapped by KEK) | Derived by authorised room members |
| File ciphertext | Enclave storage | Meaningless without DEK |
Initialisation vector (IV)
Each file encryption operation uses a randomly generated 96-bit IV. The IV is stored alongside the ciphertext and is not secret — its purpose is to ensure that encrypting the same file twice produces different ciphertext.Authentication tag
GCM produces a 128-bit authentication tag over the ciphertext and associated data (AAD). The tag is verified before decryption proceeds. If the ciphertext or AAD has been modified, decryption fails with an authentication error — the file is not presented to the user.Key rotation
DEKs can be rotated without re-uploading files. A rotation event:- Decrypts the existing DEK using the current KEK
- Re-wraps the DEK with a new KEK derived from the rotated master key
- Writes the new wrapped DEK to the database
Enclave does not perform automatic key rotation. Rotation is initiated by your key management administrator and propagated to Enclave via the KMS API.

