Operate
OpenBao
Every account secret lives in OpenBao. Each BastionOS component signs in with its own identity and gets only the paths it needs. BastionOS never uses a root token and never creates mounts or policies in your OpenBao.
What BastionOS keeps there#
| Data | Where |
|---|---|
| account passwords, keys and tokens | KV v2 mount, orgs/<organization>/… |
| directory bind passwords, SSO and SIEM secrets | same |
| the keys of recordings, one derived key per organization | Transit, key recordings |
| the audit checkpoint signing key | Transit, key audit-checkpoints (Ed25519) |
| client certificates for databases (optional) | a PKI mount dedicated to BastionOS |
The gateways have no KV access: they receive one wrapped secret per connection and unwrap it once. They can create data keys for recordings but cannot decrypt a recording.
Bundled or yours#
Bundled. The installer can start an OpenBao next to BastionOS, unsealed by a key kept on the same host. Good for a trial or a small site. It is not a separate barrier: whoever holds the host holds the key. Back up deploy/compose/.secrets with bastionos backup.
Yours, recommended in production. Your team runs OpenBao, its unseal or auto-unseal, its backups and its audit. BastionOS is a client of it.
Connecting your OpenBao#
Create the mounts, render the policies for your mount names, and one role per component. With a namespace security/pam and the default mounts:
export BAO_NAMESPACE=security/pam
bao secrets enable -path=bastionos-kv -version=2 kv
bao secrets enable -path=bastionos-transit transit
for c in controlplane ssh-gateway db-gateway; do
bao policy write bastionos-$c /var/dck/bastionos/deploy/openbao/policies/$c.hcl
doneThe installation ships the policies for the default mount names in deploy/openbao/policies/. For other names, render them with the control plane image: openbao policy --component <c> with your BASTION_OPENBAO_KV_MOUNT and BASTION_OPENBAO_TRANSIT_MOUNT.
AppRole, on a Docker host#
One role per component (bastionos-controlplane, bastionos-ssh-gateway, bastionos-db-gateway), each bound to its policy. The installer asks for the address, the namespace, the mounts, the CA that signs OpenBao's certificate (or shows the one the server presents, for you to compare its fingerprint), then each role_id and secret_id. They are stored in deploy/compose/.secrets/ and read again at every login, so an OpenBao Agent can rotate the secret IDs.
Kubernetes auth, with Helm#
The chart creates one ServiceAccount per component and projects a short token with the audience openbao. Bind one Kubernetes role per component to its policy, with token_no_default_policy=true. JWT and TLS certificate auth are supported too.
Startup check#
Each component checks, after logging in, that it holds every capability it needs and no more: a token with root capabilities is refused. A missing capability stops the component with the path it lacks. When OpenBao does not answer at all, components start degraded: open sessions continue, and nothing that needs a secret works until OpenBao is back.
Panic mode and sealing#
A full freeze can also seal OpenBao, only if it is dedicated to BastionOS: render the control plane's policy with --allow-seal, and allow sealing in the installation settings. Never on an OpenBao that other applications use. See Panic mode.
Before replacing an OpenBao#
Moving to another OpenBao means moving its data: secrets, Transit keys, audit anchors. Plan it with a backup, and run service admin reseal-mfa in the control plane first if second factors were sealed by OpenBao (see Second factor).