# Security

How Valakes stores passwords, what an AI agent can and cannot see, how the local agent API stays on your computer, and what the audit log proves.

Source: https://valakes.com/security/

Last updated: 2026-11-25

Valakes keeps your secrets in one place and lets an AI agent work without seeing them. This page says how, and where each protection stops.

## Where secrets live

Saved passwords, tokens and key passphrases are encrypted with AES-256-GCM in the vault, inside Valakes' data folder. The key that opens the vault is wrapped by your operating system's store: your account's protection on Windows, the Keychain on macOS. A value is decrypted only in Valakes' main process, at the moment it is used.

A secret value never goes to the window, and it is never written to a log or the audit log. Your screen and Valakes' history show `{{cred:name}}` instead. The one exception is the inline way, which only you can choose: it writes the value into the command, so it shows in the server's process list, may stay in the server's history and stays in this terminal's scrollback. A dialog warns you each time unless you allowed it for that binding, and an agent can never use it.

If someone copies the data folder to another computer or another account, the vault cannot be opened there, and Valakes deletes nothing until you confirm. The vault also locks after the idle time you choose, and a screen lock or sleep always locks it.

The limit: the operating system store protects against other users and against a copied folder. It does not protect against code running as you inside Valakes, and on Windows a program running as your user can ask for the key.

## What an AI agent can and cannot see

No tool of the agent API returns a credential, a key or a token. To use a saved password, the agent writes `{{cred:name}}` and Valakes answers the program's prompt itself, so the value goes from Valakes to the server and never through the agent. What the agent reads back has your saved values replaced by `***`.

An agent reaches only the sessions it opened and the tabs you share with it. It cannot change a policy, approve a request or read the audit log, because the API has no such call.

The limits: Valakes can hide only the values it knows. A secret that is not in the vault, such as a password in a `.env` file, is visible if the agent can read it, and values shorter than the masking minimum are not masked. An agent you allow to run an approved tool gets whatever that tool's credential grants. Read-only is an allow-list of read commands, not a sandbox: for a production server, give the agent a separate account with no `sudo` and no keys in its home folder.

## The local agent API

The agent API is off until you turn it on. When it runs, it listens on `127.0.0.1` only, on a port the operating system picks at every start, and every call needs the token of one agent. Valakes keeps only a hash of each token; the token itself is a file in the data folder that only you can read.

A web page cannot reach the API. The server refuses any request with an `Origin` header or a `Sec-Fetch-` header, which every browser adds, and it accepts only the exact host value `127.0.0.1` with the port, which stops DNS rebinding. It answers no CORS preflight. The bridge program checks that the server on the port really knows the token before it sends it.

The limit: a program running as your own user can read a token file and act as that agent, under the host's policy and with approvals still waiting for you. Revoke an agent you stop using.

## How a dangerous command is held

Valakes reads each command before it runs. A dangerous one opens a card that says why, with Cancel focused, and on a production host Run anyway stays off until you type the host name. An agent never gets Run anyway: a high-risk command from an agent waits until you approve or deny it.

An approval card shows Valakes' own record of the command, never text the agent wrote about it. An approval is bound to that command, session and directory, it works once, and Valakes runs the stored command, so the agent cannot swap it after you approve. The kill switch turns the API off, cancels every pending approval and closes the sessions agents opened, in one step.

The limit: the command check reads the line that was typed. It does not see inside a script, a remote alias or what a program does after it starts. It guards against a slip of your own hand, not against a compromised window.

## What the assistant sends

The assistant is off until you turn it on, and then each request goes through a Valakes service, which counts tokens for credits and keeps no text, to the model provider, Anthropic. A request carries your messages, its replies, the commands it runs and their output, and your hosts' names, addresses, environments and tags.

Credential values are never part of it. The [privacy page](https://valakes.com/privacy/) says what the Valakes service keeps. Before anything is sent, the values of your saved credentials are masked, and a second pass replaces common key formats with `[redacted:kind]`. For each host you decide whether its output leaves your computer at all. A record that does not match its host counts as withheld, and production output is held back until you answer for that host.

The limit: masking catches only what it knows. Output can still hold a secret that is not in the vault, or personal data, unless you withhold the host.

## The audit log

The audit log records what agents did: every call, every approval, every command and every transfer, with the agent, the host and the time. It holds commands with placeholders, counts and decisions. It never holds the value of a saved credential, a token, command output or the text of an assistant conversation.

Each entry carries a keyed hash of the one before it, the database refuses updates and deletes, and a sealed copy of the latest position catches a missing tail. Verify, in Settings, Audit log, checks the whole chain, and a break stays flagged at every start until you export the log and start a new segment.

The limit: the log is tamper-evident, not tamper-proof. A process that can open the vault as Valakes can rebuild the chain, and the file can be deleted, which Verify then reports.

## Where to read more

The documentation has a longer page on the security model, which describes how Valakes is built to protect your servers and your secrets and where each protection stops. It also has a security FAQ with one short answer for each common question. Read [the security model in the docs](https://docs.valakes.com/security/) or [the security FAQ](https://docs.valakes.com/security-faq/).
