Security
Clane Vault security model
What is encrypted, where and with which keys, what the server can see, what a compromised server could still do, and what hasn't been checked by an outside firm yet.
Summary
Vault items and files are encrypted in the browser before they're sent. The server stores their contents only as ciphertext, so a copy of the database holds your passwords only in encrypted form. These are the eight controls the rest of this page explains.
Two-step sign-in for every account
An authenticator code is required at sign-in, or your Entra ID or Google two-step check if your organisation trusts it. Each code works once, and 10 failed attempts lock the account for 15 minutes.
The master password stays on the device
It is stretched with Argon2id in the browser. The server never receives it, and holds the keys it unlocks only in encrypted form.
A separate key for every item and file
Each is encrypted with AES-256-GCM before it leaves the browser.
Sharing the server can't read
Keys are sealed between browsers with X25519 sealed boxes. You're warned if a colleague's key has changed since you last gave them access.
Organisations kept apart
Each organisation has its own keys. Its admins can't decrypt another organisation's items or anyone's personal vault.
Two ways to recover a lost password
Each person gets a recovery kit. Admin recovery is off by default, needs two admins (plus a 24-hour wait after a 2FA reset) and covers one organisation, never the personal vault.
Links that open once
The key sits in the link's # fragment, which the browser never sends, so the server can't open it. Add a password if you want.
Backups only you can read
Encrypted with your age key before they leave the container, then written to S3 or a folder.
Sign-in and two-step verification
Every account sets up an authenticator app (TOTP) when it is created, and a code is asked for at each sign-in. The server remembers the last 30-second step used on each account, so a code that has been accepted once is refused if it is replayed. The authenticator secrets are encrypted in the database with a key derived from the server's SERVER_SECRET.
Wrong passwords, wrong authenticator codes and wrong recovery codes all count towards the same lockout: after 10 failures the account is locked for 15 minutes. Requests are also rate limited per client address.
Organisations can add single sign-on through OpenID Connect, for example Microsoft Entra ID or Google Workspace. The identity provider confirms who the person is; the master password still unlocks the vault afterwards, so the identity provider never holds vault keys. An owner can choose to trust the provider's own two-step check in place of the authenticator code. It applies only to members who belong to that organisation alone and sign in with its verified domain, and the session stays limited to that organisation until the person enters an authenticator code.
The vault locks itself after 15 idle minutes unless the organisation sets a different time (1 to 1,440 minutes).
Master password and keys
The master password is stretched in the browser with Argon2id (64 MiB of memory, 3 iterations, parallelism 1, and a random salt per account). Two keys are derived from the result with HKDF:
- an authentication key, which is sent to the server to prove the password. The server stores only an Argon2id hash of it.
- a wrapping key, which never leaves the device. It decrypts the account's 32-byte user key.
The user key in turn decrypts the account's X25519 private key and its record keys. Each person also has one X25519 key pair per organisation they belong to (a membership key), so that keys shared inside one organisation can't be used to reach another.
The server stores these keys only in wrapped form. It doesn't receive the master password or the recovery code that would unwrap them.
Vault items and files
Items
Each record gets its own random 256-bit key. The record's fields, including its title, notes, custom fields and its record type, are encrypted with AES-256-GCM under that key, with the record's id bound in as additional data so the server can't move ciphertext from one record to another. Of the record type, the server sees only whether a record is a "login" (which the browser extension may fill) or an "item".
The installable app can keep an encrypted offline copy of the vault. Organisations can turn offline copies and the browser extension off by policy.
File attachments
Files up to 100 MB can be attached to any record. Each file gets its own random 256-bit key and is cut into 1 MiB chunks. Every chunk is encrypted with AES-256-GCM, with the file id, the chunk's position and the number of chunks bound in, so chunks can't be swapped, reordered, dropped or replayed. The file key and the file's name, type, size and SHA-256 are encrypted under the record's key. After a download the app checks every chunk and the hash of the whole file, and discards a file that fails.
Previews never render a file as HTML or SVG, never open it in a frame or new tab, and check an image's or PDF's real format before showing it. PDFs are drawn on a canvas by pdf.js with scripts off. Downloads are always handed to the browser as application/octet-stream, and programs such as .exe or .ps1 files ask before they download and say who added them.
Because the server holds only the files' ciphertext, it can't scan them for malware. Every file shows who added it, and the event log records each upload and download.
| The server knows | The server doesn't know |
|---|---|
| That a record has files, each one's id and ciphertext size, who added it and when | File names, types, content or the hash of the content |
| Who downloaded which file and when | Whether two files are the same (each has its own key) |
| Storage used per organisation, person and server | Anything inside the record |
One-time links
A one-time link sends a copy of a record to someone outside the vault, such as a client. The browser encrypts the copy under a random 32-byte link key and puts that key after the # in the link. Browsers don't send that part of an address to the server, so the server stores the copy but can't open it. The copy never includes a two-step (TOTP) secret.
- The person who makes the link chooses whether it opens once (the default), up to 3 times or until it expires, and whether it expires after 1 hour, 24 hours or 7 days. The last allowed open deletes the stored copy.
- A password can be added. The recipient's browser derives the key from the password with Argon2id together with the link key, and the server checks a hash before it releases the ciphertext.
- A link can carry up to 25 of the record's files (100 MB in total), chosen one by one. The recipient then has 30 minutes to download them.
- Only people who can edit the record can make a link. Links are revoked when their creator loses edit access, when the record is trashed, or when a file the link carries is removed.
Organisations can turn links off, set the longest expiry, require a password, and keep files out of links. Switching links off revokes the organisation's live links.
Recovering a lost master password
Recovery kit
After sign-up each person saves a recovery code made from 32 random bytes, with a checksum so typing errors are caught on the device. The server stores the user key wrapped under a key derived from that code, and a hash of a separate value used to check the code. It can't use the kit itself. Using the kit also needs the person's authenticator code. A used kit is deleted, and the person saves a new one before the vault opens.
Admin recovery
Admin recovery is off by default and is a setting of each organisation. When it is on, admins can help a member set a new master password and restore what the member holds in that organisation: its shared folders and the records shared with them there. They can never restore or open the member's private items or anything in another organisation. That also means admins can read what the member holds in that organisation.
- Turning it on needs the admin's master password and a fresh authenticator code. Members are emailed, are told on sign-up and in Settings, and must confirm a notice before their key is escrowed.
- Approving a reset needs the admin's fresh authenticator code. The member finishes it with a link that works once and for 24 hours, plus their own authenticator code. The admin never sees or sets the new password.
- If the member's two-step sign-in was also reset, the admin who reset it can't approve, the approving admin must have been an admin for at least 7 days before the reset, and the member can't set up a new authenticator until 24 hours after the reset. The member is emailed at each step, and every admin is emailed when a new admin account appears.
- Turning admin recovery off deletes every escrowed key and ends open requests.
Two risks are left. A stolen recovery kit plus a two-step reset obtained by deceiving an admin is an account takeover. So is an honest two-step reset approved by a long-standing admin acting in bad faith, if the member ignores the emails. Admins should confirm who they are talking to, by phone or in person, before resetting anyone's two-step sign-in and before approving a reset. Every recovery step is in the event log.
Backups
Scheduled backups are built in and off until you turn them on. Each run dumps the app's database schema with pg_dump, encrypts the dump inside the container with age to your public key, and only then writes it to S3-compatible storage or a mounted folder. The app refuses to start with backups on and no age recipient set, so it never writes an unencrypted backup.
Keep the age private key offline or in your secrets manager, never on the vault server.
Back up the .env file separately. Its SERVER_SECRET encrypts everyone's authenticator secrets: if it is lost, every account that set up an authenticator needs a two-step reset by an admin. Vault data isn't affected, because it is encrypted with each person's own keys. Since 1.6.1 the server refuses to start if SERVER_SECRET differs from the one the database was set up with.
Agent access: the disclosed exception
Agent access lets AI agents (Claude.ai and ChatGPT connectors, the Claude and OpenAI APIs, Claude Code) use credentials given to them, without the model seeing a value. The agent talks to one remote MCP server, the agent gateway. The gateway makes the outbound HTTPS call itself with the credential added, and returns the response with the credential scrubbed out. Agent access is an evaluation feature and is off unless the server is set up for it.
It is a deliberate exception to end-to-end encryption, limited to what is given to an agent: whoever runs the agent gateway can read the items given to an agent. When you self-host, you run your own gateway, so that is you. On the hosted service it is Clane. Items never given to an agent stay end-to-end encrypted.
There are two kinds of agent. An organisation's agents are created by an owner or admin and get Use only access to folders, groups or single records. A personal agent belongs to one person, who gives it items from their own Personal space one at a time.
| Data | Server and database | Agent gateway | Model and agent client |
|---|---|---|---|
| Items never given to an agent | Ciphertext only | Nothing: no key reaches it | Nothing |
| Items an agent can use | Ciphertext only | Plain text when used, and could decrypt them at any time while the agent is live | Names, hosts and the usage rule; responses with the secret scrubbed |
| Personal items read without asking ("Let the AI see this value", "Without asking") | Ciphertext only | As for items an agent can use | The chosen fields, in full, whenever it asks |
| Personal items with "Ask me each time" | Ciphertext only, and the field names | Only the approved fields, for each approved request; never the item's key | The approved fields, in full |
| Items a personal agent saves or updates | Ciphertext and a gateway signature | Plain text when it writes them | The value, if the model supplied it; with capture, only the new item's handle |
| The agent's private key | Only wrapped under the gateway's key | In memory during a call; wrapped at rest | Never |
How using a credential is limited
- An organisation's agent is a machine member with Use only access. It has no password or sign-in, and it can't edit, export or share. It has no tool that returns a credential.
- Each agent's key is made inside the gateway. The database holds it only wrapped under the gateway's key-encryption key: an AWS KMS or Google Cloud KMS key, whose audit log records every unwrap, or for a simple self-hosted setup a file key on the gateway host, which is weaker.
- A record is used only under its usage rule: allowed hosts, how the secret is sent and, optionally, methods and paths. The rule is inside the encrypted record. The gateway refuses non-public addresses and plain
http, and never sends the credential on a redirect to another origin. - The gateway drops any credential headers the agent sent, adds the real one, and scrubs the secret from the response headers and body, raw and in its common encodings (base64, URL-encoded, hex, JSON-escaped), before the agent gets it.
- Revoking an agent, a token or a connected app stops it at the gateway's next call. Revoke then lists the folders and records the agent could use, so you can rotate those credentials.
The gateway fingerprint
The gateway signs each agent key with its own Ed25519 identity key. When someone verifies a new agent, their browser checks that signature, shows the gateway's fingerprint and pins it. Browsers check the signature against the pinned identity before they seal anything to an agent, so a compromised API server can't slip in a key of its own. A compromised gateway can: the gateway is the trust boundary.
- Gateway fingerprint for vault.clane.ai
- ce99-2be6-9ff9-9b1e-45cc
- Key ID
- zpkr5p_5mx5FzMi8
If the Verify dialog shows anything else for vault.clane.ai, choose Not now and email [email protected] with "Security" in the subject. The same value is in the agent guide on GitHub. When you self-host, print your own with docker compose exec gateway /nodejs/bin/node dist/cli.js identity and give it to your admins through a channel the server doesn't control.
The pin is trust on first use. An admin is asked to compare the fingerprint when verifying an agent. A member pins it the first time they share with an agent, and a person who creates a personal agent pins it themselves. Someone who skips the comparison trusts whatever the server presented that first time.
Letting an agent read a value
For an item in their own Personal space, an owner can turn on "Let the AI see this value" for one personal agent and pick the fields. It is off for every item until the owner turns it on. The password is never picked for them. For a one-time code the agent gets the current 6-digit code, never the 2FA secret.
- "Without asking" is the default once the setting is on: the agent reads the chosen fields whenever it asks. Each read is logged for the owner, and reads are rate limited.
- With "Ask me each time", each read waits for the owner to approve it in the unlocked web app. The request is signed by the gateway, the browser checks the signature against the pinned gateway before it seals anything, and a request expires after 5 minutes.
- An organisation's admins can set its "Reading values" policy to "With approval" or "Off". Whoever runs the server can do the same for everyone with
GATEWAY_REVEAL.
A value an agent has read is out of the vault's control for good. It is in the model's context, the model provider's logs and the conversation, and Clane Vault can't take it back. Without asking, an agent hijacked by prompt injection can read the chosen fields and send them on with nobody asked. Let an agent read only what can't be sent in an HTTP call and is easy to change.
What agents save
A personal agent can save a credential for its owner, and can change an item only where the owner ticked "Agent can update this item". What it saves is signed by the gateway and waits under From agents in the owner's Personal space. It isn't a record, and the browser extension doesn't offer it, until the owner chooses Keep. Unkept items are deleted after 90 days. After an agent's update the server keeps the previous version (the last 5, for 30 days), so the owner can restore it. Agents can't delete items.
Risks that remain. A hijacked agent can't see a value it only uses, but can make legitimate-looking calls to an allowed host with bad intent. A breach of the gateway host, an insider who controls both the gateway's deployment and its KMS key, or legal compulsion of the gateway operator could expose the items given to agents. A host that re-encodes a secret in a form the scrubber doesn't know can get it into a response, and so to the model provider. Use events are reported by the gateway itself. An organisation's admins see only that a member created, verified, connected or revoked a personal agent, not what it holds. Give agents restricted credentials, never a root or owner key, narrow their hosts, methods and paths, and rotate every credential an agent held after a suspected gateway incident. If you have legal exposure, self-host the gateway or don't give such items to agents. The full list is in SECURITY.md.
What is stored in plain text
Some data has to be readable by the server for sign-in, invitations and auditing. It is stored unencrypted in your Postgres:
- member email addresses and display names
- organisation and group names
- record categories ("login" or "item"), and which records and folders each person can open
- for files: how many a record has, their ciphertext size, who added them and when
- the event log: who did what and when, including who was given access to what and who downloaded which file. It never contains a password, a file name or a file's hash.
Treat database dumps as sensitive even though they contain no readable passwords.
If the server is compromised
The server can't decrypt vault items or files. A server that has been taken over could still do harm, though:
- It could serve malicious JavaScript that reads passwords as people type them. Encryption in the browser can't protect against this. The app sends a Content Security Policy that allows scripts only from its own origin, and when you self-host, an attacker has to get into your infrastructure to change the code.
- It could swap public keys, so that a new share is sealed to the attacker. Existing shares aren't affected. Compare key fingerprints with the colleague by another channel before sharing anything sensitive.
- It could plant fake shared folders or records, because sealed boxes aren't signed. The folder sheet shows the owner's name and key fingerprint. Don't type secrets into a folder whose owner you haven't checked.
- It could hide records or serve an older version, because the server decides which rows to return.
Run the image you were given, keep the host patched, and limit network access to Postgres to the container host.
What leaves your network
When you self-host, no data reaches Clane. There is no telemetry and no licence server. Traffic leaves your network only for:
- the breached-password check: the first 5 characters of a SHA-1 hash go to Have I Been Pwned. Members opt in, and admins can switch it off.
- sign-in with Entra ID or Google, if you set up single sign-on
- your mail provider, for invitations and security notices
- your S3 storage, for backups and, if you choose, file attachments
- image downloads from
ghcr.iowhen you install or update - if you turn on agent access, the agent gateway's calls to the hosts your agents may use
Audit status
Pre-audit: use it for evaluation
No independent firm has audited or penetration-tested Clane Vault. Run it to evaluate it, with test data. Don't store production secrets in it or roll it out across an organisation until an audit has been done and its findings fixed. SECURITY.md will say when.
The code has been through internal security reviews, covering multiple organisations, email and single sign-on, per-organisation keys and file attachments. The fixes are listed in the changelog. The full source is on GitHub under AGPL-3.0, so your own team can review it.
To report a security problem, email [email protected] with "Security" in the subject, or use private vulnerability reporting on GitHub.