Encryption Keys & Reversible Anonymization

Understand the complete key lifecycle — from generation to rotation — and how reversible anonymization enables secure collaboration.

By anonym.plus · Published 2026-06-27 · Updated 2026-06-27

What Are Encryption Keys For?

When you use the Encrypt operator in anonym.plus, each detected PII entity is individually encrypted using AES-CBC with a 256-bit key by default (128/192-bit selectable), Presidio-compatible, with a random IV per value, producing a Base64 string of IV and ciphertext that replaces the original value in the document. The encryption key is what makes this process reversible.

Keys enable the encrypt-share-edit-decrypt workflow: you anonymize a document with encryption, share it with collaborators who can edit the surrounding text freely, receive the modified document back, and then decrypt all intact encrypted tokens to restore the original PII. Without the correct key, encrypted tokens are unreadable to anyone.

Encryption keys are stored in a local vault on your machine. They never leave the Rust backend — the frontend references keys by ID only, and key values are never exposed to the JavaScript layer or transmitted to any server.

Key Generation and Storage

Encryption keys are generated and managed in Settings > Encryption Keys. anonym.plus supports three key lengths:

Key storage follows a zero-knowledge architecture. Key values never leave the local vault. The frontend references keys by ID only — it never sees or handles raw key material. The vault itself is encrypted with AES-256-GCM, with the vault encryption key derived from your password via Argon2id (64 MB memory, 3 iterations, 32-byte output). This means even if someone gains access to the vault file on disk, they cannot extract key values without your password.

The Encrypt-Share-Edit-Decrypt Workflow

This is the core collaboration workflow that encryption keys enable:

  1. Anonymize with encrypt. Process your document using the Encrypt operator with your chosen key. All detected PII entities are replaced with AES-256 encrypted values (Base64 strings).
  2. Share the anonymized document. Send the document via email, cloud storage, or any other channel. Recipients see only encrypted tokens in place of PII — the document is safe to transmit.
  3. Collaborators edit freely. Recipients can add text, rewrite paragraphs, insert comments, and modify the document around the encrypted chunks. The encrypted tokens look like opaque strings and should be left intact.
  4. Receive the modified document. When collaborators return the edited document, the encrypted tokens remain embedded in the text alongside the new content.
  5. Deanonymize. Drop the returned document into Deanonymize > File Drop. The app automatically detects all encrypted chunks in the document.
  6. Decrypt. Click Deanonymize. All intact encrypted chunks are decrypted using the original key, restoring the original PII values in their correct positions.

Important notes: Encrypted chunks must remain intact for decryption to work. Surrounding text can be freely edited. Encrypt does not detect changes: leave encrypted values unchanged — if a collaborator edits an encrypted value (even one character), it can no longer be decrypted reliably. Missing chunks and chunks that fail to decrypt are skipped — the app performs partial recovery, decrypting all intact tokens and leaving damaged ones as-is.

Encryption Specification

The following table details the complete cryptographic specification used by anonym.plus:

Parameter Value
Algorithm Encrypt operator: AES-CBC with a 256-bit key by default (128/192-bit selectable), Presidio-compatible, PKCS7 padding. Key vault: AES-256-GCM
IV Random 16 bytes per encrypted value
Output format Base64 of IV and ciphertext, for example q8vJ3kL0…==
Key lengths 128, 192, 256 bit
Authentication Encrypt operator: none (CBC has no authentication tag). Key vault: yes (GCM)
Key storage Zero-knowledge local vault
Key derivation (vault) Argon2id, 64 MB memory, 3 iterations
Recovery 24-word BIP39 mnemonic (256 bits entropy)

Each PII entity is encrypted individually with a random IV. This means identical PII values produce different ciphertexts, preventing frequency analysis attacks. Encrypt does not detect changes: leave encrypted values unchanged — an edited value can no longer be decrypted reliably.

Key Rotation

Key rotation generates new key material for an existing key entry. When you rotate a key:

Best practices for key rotation:

Vault Protection

The encryption key vault uses multiple layers of protection to secure your key material:

Ready to try it yourself? See encryption in action →

Important Considerations

Reversible encryption has key management requirements you must understand: