Rivergate

Security model

What Rivergate protects, how, and what remains your responsibility when you run it.

Objectives

  1. Prevent unauthorized secret disclosure and cross-tenant access.
  2. Protect the confidentiality and integrity of stored secret versions and wrapped keys.
  3. Make every secret access attributable, and make audit failure impossible to ignore.
  4. Limit the blast radius if the API, database, Redis, dashboard or a Kubernetes cluster is compromised.
  5. Support safe rotation, recovery, upgrades and incident response.

Encryption at rest does not protect against a compromised authorized process that can itself decrypt values. Defence is layered for that reason.

Threats and controls

ThreatControls
Cross-tenant reads or writesPolicy checks, tenant-scoped SQL, composite foreign keys, non-enumerating errors, and ciphertext bound to its tenant and resource.
Unauthorized secret readA distinct read-value permission, exact resource authorization, short-lived credentials, and audit-before-disclosure.
Stolen database snapshotPer-version AES-256-GCM, layered key wrapping (root, organization, project, data key), and a root key held outside the database.
Redis loss or compromiseRedis holds no secrets, keys or audit data; sign-in state is short-lived, single-use and encrypted.
Token theft or replayHigh-entropy, expiring, user-bound tokens stored only as hashes; immediate revocation; HttpOnly, SameSite cookies and CSRF checks.
Telemetry or log leakageBody redaction, allowlisted attributes, bounded labels and no secret capture in traces, metrics or logs.
Key compromiseScoped key hierarchy, versioned keys, rewrap jobs and a documented containment procedure.
Audit history rewriteAppend-only triggers, canonical hash chains, separately held signing keys and signed checkpoints.
Operator abuseAudited bootstrap and handoff, time-limited out-of-band recovery, least privilege.
Kubernetes exposureExact workload identity, namespaced RBAC, scoped policies, and a no-list, no-cross-namespace Operator.

Authentication and authorization

See Authentication and Secrets and access.

Encryption and keys

See Keys and encryption.

Audit

See Audit log.

Secure handling rules

Kubernetes delivery

See Kubernetes Operator.

Incident response

Prepare runbooks for: a leaked machine or personal token, suspected database exfiltration, root, organization or project key compromise, audit checkpoint failure, a malicious insider, a Redis outage, corrupted ciphertext, a failed key rotation and lost key material.

Your responsibilities as the operator

AreaYou provide
KeysProtected, separately backed-up root-key and signing-key material; host access controls and disk encryption.
DatabaseTLS, encrypted backups, restricted runtime role, failover and restore testing.
AuditAn independent place for signed checkpoints and public keys, and monitoring of audit health.
NetworkTLS termination, private metrics, egress control and log redaction.
Kubernetesetcd encryption at rest, namespace RBAC, a cleanup procedure for revoked workloads.
IdentityYour OIDC provider, its MFA and lifecycle policy, and prompt disabling of departed users in Rivergate.