This page covers Minder's security posture — what protections are in place, what is deliberately not yet in place — and how to manage the credentials and secrets a deployment needs. For the login/SSO/JWT model in detail, see Authentication.
!!! warning "A default install is development-grade" Out of the box Minder is functional end-to-end but not hardened for public-internet exposure. The measures below describe what exists today plus the steps to take before a production deployment. Work through the hardening checklist before exposing an instance.
- JWT authentication at the API Gateway. The gateway signs access tokens with EdDSA (an Ed25519 key pair that setup generates). Every other service gets only the public key, so it can verify a token but never mint one. Credentials are stored as bcrypt hashes. See Authentication.
- Redis-backed rate limiting at the gateway, in 60-second windows:
anonymous callers per client IP, signed-in callers per IP and user (a higher
limit), and the login and register routes per IP only. It is fail-open:
if Redis is unreachable, requests are allowed rather than blocked. The limits
are
RATE_LIMIT_PER_MINUTE(60),RATE_LIMIT_AUTHENTICATED_PER_MINUTE(300) andRATE_LIMIT_STATUS_POLL_PER_MINUTE(600, document upload status polls). - Service-to-service identity. A service that calls another service's
internal routes signs a short-lived token with its own Ed25519 key, and
each internal route accepts only the callers on its allowlist. There is no
shared service token. A service whose keys are missing logs an error at
startup and its service calls are refused (
401), so run setup after an upgrade. - Security response headers, on by default. The gateway adds
X-Content-Type-Options: nosniff,Referrer-Policy: no-referrer,X-Frame-Options: DENYwithContent-Security-Policy: frame-ancestors 'none'(the anonymous public-chat paths are the exception: theirframe-ancestorsis the endpoint's own allowed origins), andCache-Control: no-storeon auth and invite-token responses. It addsStrict-Transport-Securityonly when the request arrived over TLS, directly or through a trusted proxy. A header a route already set is never replaced, and error and429responses carry the headers too. The web client's own server adds its headers (including a Content-Security-Policy) in the same way. Settings, all in the root.env:SECURITY_HEADERS_ENABLED(defaulttrue),SECURITY_HEADERS_REFERRER_POLICY,SECURITY_HEADERS_HSTS,CLIENT_SECURITY_HEADERS(onby default; setoffonly when your own reverse proxy sets them) andCLIENT_CSP. - Authelia SSO / OIDC — enabled and enforcing forward-auth on the gated routers, and a real OIDC identity provider that mints the Minder JWT from a verified Authelia identity. See Authentication.
- Traefik v3 reverse proxy — the single ingress; TLS termination and routing
by Docker labels (
exposedByDefault: false, so nothing is exposed unless explicitly labelled). Not Nginx. - Network isolation — storage backends (PostgreSQL, Redis, Qdrant, Neo4j,
MinIO, RabbitMQ, schema-registry) run internal-only on the Docker network and
publish no host port. Host ports that do exist are loopback-bound
(
127.0.0.1) — see Service access. - IP-whitelist middleware on the admin surfaces routed through Traefik (the dashboard, the message-queue management UI, the graph-database browser).
- Least-privilege Docker access — services that need the Docker Engine API
(bundle enable/disable, container logs) go through a proxy with an explicit
allowlist of paths and methods, never a raw
docker.sockmount. - Out-of-process plugins. Plugin code runs in separate
plugin-runnercontainers, not in the plugin registry, with no platform secrets in their environment. Each plugin that needs a database gets its own least-privilege Postgres role. See Plugin trust model.
Plugins run out of process. The plugin registry keeps every policy decision (who may call what, admin-only actions, tier checks, scheduling, config, secrets) and calls a plugin-runner container only after those checks. The registry image contains no plugin code: it parses a read-only copy of the catalog and never imports it.
Runners are grouped by how much they are trusted:
| Group | Hosts | How it reaches the network |
|---|---|---|
declarative |
Declarative (T0) manifest plugins only. No plugin code runs. | Direct, but only to the public hosts each manifest declares. The engine checks every hop, refuses any non-public address and pins the connection to the address it checked. |
trusted |
Catalog code plugins that only need public HTTP(S). | Through an egress proxy only. The runner sits on internal Docker networks with no route out. |
privileged |
Plugins that need LAN access or manage a sidecar (today network and telegraf). |
Direct LAN and internet access under firewall rules in its own network namespace. These block cloud metadata and link-local addresses, the Docker host's networks and gateways, and anything listed in EGRESS_PROXY_DENY_CIDRS. |
Every runner runs with a read-only root filesystem, no Linux capabilities,
no-new-privileges, and no env_file or platform secret in its
environment. Its API listens only on an internal control network, and it
accepts only requests carrying a short-lived, single-use token that
plugin-registry signs for that specific group. A runner that has no
registry public key refuses every request.
A plugin gets only what the platform grants it, through the platform context
(self.ctx): its own secrets, calls to plugins it declares a dependency on,
document indexing on behalf of the invoking user, and the time-series and
sidecar capabilities it declared. The registry checks the grant on every call.
What a plugin receives at load is limited to:
- A scoped database role.
databaseconnects as a role of the formminder_plugins_<plugin>, confined to that plugin's ownplugin_<plugin>schema, with no privilege on the platform's tables or on another plugin's schema. WithoutDB_PLUGIN_PASSWORDa plugin gets no database handle at all. - No Redis, InfluxDB, Neo4j or RabbitMQ handle. Time-series data goes
through the registry's time-series capability and
timeseries-gateway, the only process that holds the InfluxDB admin token. A plugin that used to write to Neo4j or RabbitMQ directly (thenetworkplugin) has those sinks off in a runner.
!!! warning "Isolation is not complete"
Plugin code in the trusted and privileged groups is still arbitrary
Python inside its container. The in-process egress guard in the runner is a
backstop for honest plugins, not a boundary: the boundary is the network
layer around it. Per-plugin egress allowlists for community code are
not shipped. List your host's own public and
LAN addresses in EGRESS_PROXY_DENY_CIDRS, because the runner cannot
discover addresses the Docker host has on its other interfaces.
Catalog plugins arrive as pull requests to the public
plugins repo. They are reviewed, and CI
runs minder-plugin validate and a contract suite on each one. Submitted
marketplace listings go through an admin review workflow before they're
publicly visible (first-party listings are pre-approved). See
Publishing.
Tool effects and approvals. Plugins declare an effect on each AI tool:
read, write, send or destructive. In tool-calling chat, read tools
run straight away. Any other tool, or a tool with no declared or unknown
effect, pauses until the user approves that exact call. See
Tool approvals.
- Complete plugin sandboxing. Plugins run in separate runner containers, but code plugins are not run in a per-plugin sandbox. See Plugin trust model.
- RBAC is partial. A user's
roleis checked on a specific set of admin-only actions (model pull/delete, bundle enable/disable/reconcile, plugin lifecycle and service-registry routes, the marketplace admin endpoints, and admin-only plugin actions). Most other write endpoints still only require a valid JWT, not a particular role — authorization is not yet uniform. Don't build workflows that assume broader per-role enforcement than that. - Full browser SSO needs real DNS + TLS. Over plain
localhostor a bare LAN IP the forward-auth 302 works but end-to-end browser SSO does not.
Configuration and secrets live in a single root .env — the one source of
truth. bash setup.sh self-heals it: any value left as a CHANGEME placeholder
(or missing) is replaced with a strong random value on install/start, and the
file is chmod-ed to 600. A fresh install therefore already has real secrets,
not placeholders.
The placeholders shipped in .env.example are, for example:
POSTGRES_PASSWORD=CHANGEME_POSTGRES_SECRET_32_CHARS
REDIS_PASSWORD=CHANGEME_REDIS_SECRET_32_CHARS
JWT_SECRET=CHANGEME_JWT_SECRET_MINIMUM_64_CHARS_RECOMMENDED
NEO4J_AUTH=neo4j/CHANGEME_NEO4J_PASSWORD_16_CHARSOnly set your own value if you want a specific one. A value you supply must have
the same shape as a generated one (lowercase hex, exact length; see the table
below). Otherwise setup.sh treats it as a placeholder and replaces it. The one
exception is the Authelia admin password, which may be any value you choose. Authelia's admin password follows the
same self-heal: it's generated per deployment, argon2id-hashed, and the plaintext
is printed to the terminal once when first generated — record it then (see
Authentication).
!!! danger "Never commit real secrets"
Keep .env out of version control. It is already covered by .gitignore.
Use distinct credentials per deployment — each machine has its own root
.env.
setup.sh generates and manages every secret below. "Length" is the length of
the generated value: lowercase hex, two characters per random byte.
| Secret | Length | Used for |
|---|---|---|
POSTGRES_PASSWORD |
64 hex | PostgreSQL owner role minder (migrations, schema) |
DB_APP_PASSWORD |
64 hex | Non-superuser runtime role minder_app. Each service's query pool connects as it, which is what makes row-level security apply |
DB_PLUGIN_PASSWORD |
64 hex | Base secret for the per-plugin least-privilege roles (minder_plugins_<plugin>). The registry derives each role's password from it and creates the role when the plugin loads. Each role is confined to its own plugin_<plugin> schema |
OPENWEBUI_DB_PASSWORD |
64 hex | Open WebUI's own database role, which owns the openwebui database only |
REDIS_PASSWORD |
64 hex | Redis |
RABBITMQ_PASSWORD |
64 hex | RabbitMQ |
MINIO_ROOT_PASSWORD |
64 hex | MinIO root user |
JWT_SECRET |
128 hex | Legacy HS256 signing key. Only the API Gateway receives it, and only to accept sessions that predate the EdDSA upgrade during a bounded window. No other service holds it. See JWT signing and keys |
JWT_SIGNING_PRIVATE_KEY, JWT_PUBLIC_KEYS |
Ed25519 key (base64 PEM) | The gateway's EdDSA signing key and the list of public keys every service verifies with. Setup generates both. Only the gateway receives the private key |
SERVICE_SIGNING_KEY_<SERVICE> |
Ed25519 key | One signing key per service that calls another service's internal routes. Each is given to its own service only. SERVICE_PUBLIC_KEYS carries every public half |
PLUGIN_T4_SIGNING_KEY |
base64 Ed25519 seed | The key plugin-registry signs its calls to remote plugins with. The public half is published at /.well-known/minder/plugin-jwks.json |
MODEL_PROVIDER_VAULT_SECRET |
128 hex | Encrypts stored cloud-provider API keys. Never clear it, see below |
PLUGIN_SECRETS_VAULT_SECRET |
128 hex | Encrypts per-plugin connector secrets. Never clear it |
LICENSE_KEY_VAULT_SECRET |
128 hex | Encrypts license keys at rest. Never clear it |
LICENSE_KEY_HASH_SECRET |
128 hex | Keys the license-key lookup hash. Must never change |
NEO4J_AUTH |
neo4j/ + 32 hex |
Neo4j |
INFLUXDB_ADMIN_TOKEN |
apiv3_ + 64 hex |
InfluxDB's admin token. Only timeseries-gateway and InfluxDB receive it. Never regenerated: InfluxDB reads it once |
TIMESERIES_TOKEN_TELEGRAF, TIMESERIES_TOKEN_GRAPH_RAG, TIMESERIES_TOKEN_PLUGIN_REGISTRY |
64 hex | One timeseries-gateway credential per consumer. Each is given to that consumer only |
AUTHELIA_STORAGE_ENCRYPTION_KEY |
64 hex | Encrypts Authelia's own storage. Never clear it |
AUTHELIA_SESSION_SECRET, AUTHELIA_IDENTITY_VALIDATION_RESET_PASSWORD_JWT_SECRET, AUTHELIA_IDENTITY_PROVIDERS_OIDC_HMAC_SECRET |
64 hex | Authelia sessions, password-reset links, OIDC tokens |
MINDER_OIDC_CLIENT_SECRET |
64 hex | API Gateway's OIDC client secret with Authelia |
MINDER_AUTHELIA_ADMIN_PASSWORD |
64 hex (or your own) | Authelia admin login, printed once when generated |
GRAFANA_PASSWORD |
64 hex | Grafana admin |
WEBUI_SECRET_KEY |
64 hex | Open WebUI session signing |
Older installs may still have INFLUXDB_TOKEN, SERVICE_SYNC_TOKEN or
SERVICE_SYNC_TOKEN_ON_MIGRATED_ROUTES in .env. Nothing reads them any more,
and setup removes those lines (after saving the usual backup).
Without DB_PLUGIN_PASSWORD, plugins get no database handle at all (fail
closed). They never fall back to the owner credentials, and the plugin registry
logs an error at startup.
Releases sometimes add a secret to the list above (for example,
DB_PLUGIN_PASSWORD or the TIMESERIES_TOKEN_* credentials). setup.sh fills
missing secrets on install/start. To avoid desyncing live services, it
refuses to generate secrets while the stack is running, with one exception:
a brand-new secret whose service re-applies it from .env on every boot.
DB_PLUGIN_PASSWORD, OPENWEBUI_DB_PASSWORD, the TIMESERIES_TOKEN_*
credentials and INFLUXDB_ADMIN_TOKEN are of this kind, and setup adds them
automatically even on a running stack, as long as the key is absent from
.env. The JWT and service signing keys are also filled on a live stack.
For any other new secret, or if the key is present but empty or a placeholder,
setup stops with Refusing to regenerate .env secrets. Either:
- stop the stack, then start it again (
bash setup.sh stop, thenbash setup.sh start), so setup fills the key while nothing is running; or - run setup with
MINDER_ALLOW_SECRET_REGEN=1set. This is an explicit opt-in that lets setup generate secrets on a live stack. Like a normal run, it only fills keys that are missing, empty, placeholders, or malformed. It never touches a well-formed value you already have.
setup.sh sets 600 on .env automatically. To verify:
ls -la .env # should show -rw------- (owner read/write only)Rotate on a regular cadence (quarterly is a reasonable default), and immediately
on suspected compromise. Before you start, take a backup (bash setup.sh backup).
Before setup regenerates any secret, it saves the current file as
.env.backup-<timestamp> next to .env.
!!! danger "Not every secret can be regenerated"
Clearing a secret makes setup.sh replace it with a new random value.
That is fine for a password that a service re-reads on start. For a secret
that encrypts or hashes stored data, it orphans that data permanently:
| Secret | What breaks if it's regenerated |
|--------|---------------------------------|
| `MODEL_PROVIDER_VAULT_SECRET` | Stored cloud-provider API keys can no longer be decrypted |
| `PLUGIN_SECRETS_VAULT_SECRET` | Stored per-plugin connector secrets can no longer be decrypted |
| `LICENSE_KEY_VAULT_SECRET` | Encrypted license keys can no longer be revealed or rotated |
| `LICENSE_KEY_HASH_SECRET` | Existing license keys stop validating |
| `AUTHELIA_STORAGE_ENCRYPTION_KEY` | Authelia can no longer read its own encrypted storage |
**Never clear these.** If one was regenerated by mistake, restore the old
value from the newest `.env.backup-*` file before any further restart.
These can be rotated by clearing them and letting setup generate new values:
-
Clear the keys to rotate in the root
.env, for exampleREDIS_PASSWORD=. -
Apply with the stack stopped. Setup refuses to regenerate secrets while the stack is running.
bash setup.sh stop bash setup.sh start
-
Sync the ones a data store keeps. Editing
.envalone does not change a password that a data store saved at first initialization:Secret How the new value takes effect JWT_SECRETOnly the legacy HS256 key, which the gateway uses just to honour sessions from before the EdDSA upgrade. Rotating it ends those sessions. To rotate the key that signs current tokens, see Signing key rotation REDIS_PASSWORD,MINIO_ROOT_PASSWORDPicked up when the container is recreated on start DB_APP_PASSWORD,DB_PLUGIN_PASSWORDPicked up on start: the services re-apply the minder_approle password, and each per-plugin role's derived password, from.envon every boot. No manual step neededPOSTGRES_PASSWORDRun bash setup.sh sync-postgres-passwordonce the stack is up. It runsALTER USER minder, so the live database matches.env. It only updates theminderowner role; the roles above sync themselvesRABBITMQ_PASSWORD,NEO4J_AUTH,GRAFANA_PASSWORDSaved in the service's data volume at first initialization. Setup has no sync command for these, so change the password inside the service with its own tooling, then put the same value in .env. Don't regenerate them blindlyTIMESERIES_TOKEN_*Picked up on start. INFLUXDB_ADMIN_TOKENis the exception: InfluxDB reads it once, so setup never regenerates it -
Verify:
bash setup.sh status curl http://localhost:8000/health
The gateway's EdDSA key and the per-service keys are not hex secrets, so clearing them is not how you rotate them:
- JWT signing key. Add the new public key to
JWT_PUBLIC_KEYS(comma-separated, and keep the old one), restart, then replaceJWT_SIGNING_PRIVATE_KEYwith the matching new private key and restart again. Tokens signed with the old key stay valid until they expire. - Service signing keys. Delete the
SERVICE_SIGNING_KEY_<SERVICE>line, run setup again, and restart. Upgrade every service together.
The services accept MODEL_PROVIDER_VAULT_SECRET, PLUGIN_SECRETS_VAULT_SECRET
and LICENSE_KEY_VAULT_SECRET as a comma-separated list:
- the first entry is the primary key, used for all new encryption;
- every entry is tried when decrypting, so data encrypted under an older entry stays readable as long as that entry is still in the list.
Each entry has the same shape as a generated value: 128 lowercase hex
characters (openssl rand -hex 64). Setup accepts a valid list as it is and
never regenerates a vault secret that already has a value, whether the stack is
running or stopped, and even with MINDER_ALLOW_SECRET_REGEN=1. It only fills
one that is missing, empty or still a placeholder.
To rotate one of these secrets:
- Prepend the new key. Generate a new value and put it in front of the
current one, separated by a comma, in the root
.env:Never replace the old value or clear the list.MODEL_PROVIDER_VAULT_SECRET=<NEW>,<OLD>
- Restart so the services load the new list:
New data is now encrypted with the new key, and existing data stays readable through the old one.
bash setup.sh restart
- Re-encrypt, where an endpoint exists. Model providers have one:
POST /v1/model-providers/rotate(admin or org admin). Call it once per organization to move that organization's stored keys onto the new primary.PLUGIN_SECRETS_VAULT_SECRETandLICENSE_KEY_VAULT_SECREThave no re-encryption endpoint, so keep their old entry in the list. - Drop the old key only after re-encryption. Once everything encrypted with
the old entry has been re-encrypted, remove it (
<NEW>alone) and restart again. If you're not sure, leave it in: an extra entry costs nothing, but a missing one makes the data it encrypted unreadable.
!!! warning "Setup stops on a malformed vault value"
If a vault secret has a value that isn't a valid list (for example a
truncated entry, an uppercase or non-hex character, or a wrong length),
setup refuses to start. It logs which key is malformed and what it
expects, and writes nothing to .env. It doesn't replace the value,
because that would orphan the encrypted data. Fix the value by hand, or
restore it from the newest .env.backup-* file, then run setup again.
LICENSE_KEY_HASH_SECRET is a single value with no rotation path. Every
stored license-key lookup hash is keyed with it, so it must stay the same for
the life of the installation. It is kept separate from LICENSE_KEY_VAULT_SECRET
so that the vault key can rotate without touching the hashes.
Stop the stack first (bash setup.sh stop), rotate as above, restart, and
review the gateway access logs (docker logs minder-api-gateway --tail 1000).
Minder's built-in mechanism is the single root .env (one per machine — there is
no .env.development/.staging/.production layering). For a hardened
deployment you may optionally layer an external secrets system on top; these are
forward-looking, not built in:
=== "Docker Swarm secrets"
```yaml
services:
postgres:
secrets:
- postgres_password
environment:
POSTGRES_PASSWORD_FILE: /run/secrets/postgres_password
secrets:
postgres_password:
external: true
```
=== "Kubernetes Secret"
```yaml
apiVersion: v1
kind: Secret
metadata:
name: minder-credentials
type: Opaque
stringData:
POSTGRES_PASSWORD: CHANGEME
REDIS_PASSWORD: CHANGEME
JWT_SECRET: CHANGEME
INFLUXDB_ADMIN_TOKEN: apiv3_CHANGEME
```
- Configure real DNS for the public hostnames.
- Replace the self-signed
.localcertificates with real TLS (ACME / Let's Encrypt via Traefik, or your own certs) so Authelia SSO/2FA works as full browser SSO. - Confirm no
CHANGEME_placeholders remain:grep CHANGEME_ .envshould print nothing. - Verify
.envpermissions are600and it is not committed to git. - Add firewall rules; remember host ports are loopback-bound, so protect access to the box itself.
- Establish a credential-rotation cadence.
- If you enable transactional email, keep
SMTP_PASSWORDin.envonly, usestarttlsortls(notnone), and publish SPF/DKIM/DMARC for the sender domain. - Add alerting on failed authentication attempts and anomalous access (see Monitoring).
- Keep Traefik and the service images updated (see Upgrading).
# No default credentials remain
grep CHANGEME_ .env # should print nothing
# File permissions
ls -la .env # -rw------- (600)
# Services healthy
bash setup.sh status- A service exits immediately or is unhealthy — check its logs
(
docker logs minder-<service>); confirm.envexists and is populated. - "password authentication failed" (PostgreSQL) — the live DB password and
.envhave diverged; runbash setup.sh sync-postgres-password. - "WRONGPASS" (Redis) —
REDIS_PASSWORDin.envdoesn't match what Redis is running with; restart Redis after fixing it. - 401 on API requests — confirm the token hasn't expired, and that every
service has the same
JWT_PUBLIC_KEYS(setup writes it). A service that has none refuses EdDSA tokens. See Authentication.
More diagnostics are in Troubleshooting.