What Coloa protects, against whom, what has been checked, and what an external penetration test should focus on. Keep this current when a finding is fixed or a design changes.
schema.coloa rules compile to Postgres row-level security, so a bug in app code can’t widen access.| Attacker | Example | In scope |
|---|---|---|
| A prompt-injected or careless agent | Sends a key to a pastebin, drops a column, loosens a rule | Yes, the main case |
| Malicious app code (written by an agent) | Exfiltrates data through allowed hosts, forges audit labels | Yes |
| An app’s end users | Reads other users’ rows or files, CSRF, session theft | Yes |
Another app on the same coloa server |
Reaches another app’s database, files, console or previews | Yes |
| A person with a valid human token who isn’t an owner | Promotes an app they don’t own | Yes (org policy) |
| Software on the host running as the same OS user | Reads ~/.coloa/master.key |
No. Use a separate OS account or machine. |
| Root on the host, or access to the Docker socket | Anything | No |
db, fetch, log, connector)..coloa/ hidden, egress only through the gateway relay.coloa server: host-based routing, per-person tokens, SSO sessions, org policy.An independent reviewer read the code adversarially, without being told our conclusions. Status:
| # | Finding | Severity | Status |
|---|---|---|---|
| 1 | A preview named after the app captured the production hostname | Critical | Fixed: previews only at exactly <env>.<app>.<domain> |
| 2 | Database names were ambiguous (shop+x-prod = shop-x+prod), so a preview could take over another app’s production database |
Critical | Fixed: coloa_<app>__<env>, no -- in names, owner tag on each database, adoption of foreign databases refused |
| 3 | An agent’s push changed the code that production services run, without approval | High | Fixed: services run a snapshot made by a human push or a promotion |
| 4 | Previews reached production service containers with preview identities | High | Fixed: previews don’t reach services |
| 5 | Sibling apps and previews are the same site, so cross-site requests carried cookies and sessions could be planted | High | Fixed: __Host- cookie over HTTPS; cookie-authenticated state changes need Sec-Fetch-Site: same-origin or a matching Origin |
| 6 | Each session lookup opened a superuser connection, and Argon2 floods weren’t limited | Medium-high | Fixed: pooled auth connections (4), at most 4 password hashes at once |
| 7 | ./.coloa in a pushed tarball got past the filter |
Medium | Fixed |
| 8 | like and sorting on @sensitive columns leaked values bit by bit |
Medium | Fixed: only exact matches and null checks. Masking still only catches exact values (see below) |
| 9 | A secret could be stored on an allowed host and read back in pieces | Medium | Mitigated: secrets in headers and URLs only unless in_body: true; Range is dropped when a secret is injected |
| 10 | IPv6 forms with an embedded IPv4 address skipped the private-address filter | Low-medium | Fixed |
| 11 | A function fetch buffered the whole response before checking its size | Medium (DoS) | Fixed |
| 12 | Console log viewer path traversal | Low | Fixed. Who may read other apps’ audit, logs and cost was decided with roles (#21) |
| 13 | Function code could relabel itself through proxy headers | Low | Fixed for functions. Services can still set their own label (attribution only, no extra rights) |
| 14 | Services shared the agent sandbox’s Docker network, so a sandboxed agent could call a production service directly with a forged x-coloa-user header and act as any end user (found after the review, reproduced in e2e) |
High | Fixed: services run on their own internal network and relay; e2e probes from the sandbox network and must find them unreachable |
| 15 | No time limit for request headers or TLS handshakes, and a failed accept (e.g. out of file descriptors) stopped the listener: a few hundred slow connections could take down the app server, gateway or console |
Medium-high (DoS) | Fixed: 10 s header and handshake timeouts, at most 4096 connections per listener, accept errors retried; a unit test sends half a request and must be cut off |
| 16 | Per-address request limits used a fixed window, so twice the limit fit across a minute boundary | Low | Fixed: sliding window |
| 17 | Services ran as root inside their containers, with no memory or CPU limit unless configured | Medium | Fixed: the code’s owner or nobody, 512 MB without extra swap, 1 CPU by default |
| 18 | App queries had no time limit: a slow query kept running (holding a connection and CPU) after its function had timed out | Medium (DoS) | Fixed: statement_timeout 5 s and lock_timeout 2 s per query; the Postgres suite stops a 300k-row scan under a 1 ms limit |
| 19 | Function logs had no size limit: a function logging in a loop could fill the disk (shared by every app on a server) | Medium (DoS) | Fixed: 200 lines per request, rotation at 50 MB |
| 20 | Design check for the start-up snapshot (no flaw shipped): a snapshot shared by all requests must not carry a random seed, time or request data | — | Guarded: imports trap during snapshotting (this caught Boa’s clock and std’s hash seed before release); a test checks globals don’t leak and Math.random/Date.now differ per request |
| 21 | On a shared server every person with a token could read every app’s audit, logs and cost, and could manage any app without declared owners | Medium (confidentiality on shared servers) | Fixed: roles (admin, auditor, owner, developer, viewer). Once an admin exists, people see only apps they have a role on; refusals are audited; the last admin can’t be removed |
| 23 | App users could only sign in with passwords: open to credential stuffing (now automated by agents at scale) and phishing, and in a cluster the login limits counted per replica | High | Fixed: passkeys (WebAuthn, user verification required, bound to the app’s host so a phishing site gets nothing usable, one-time challenges), auth: { passwords: false } for passkey-only apps, and login limits shared by every replica |
| 24 | A stolen account or token could read everything it was allowed to see, as fast as it liked, and nothing signalled an intruder exploring | High | Mitigated: hourly read caps per identity (rows and bytes; alert, optionally block), decoy tables, accounts and server tokens that raise an alert on first touch (a decoy table also signs the user out everywhere), alerts to the audit log and a webhook |
| 25 | The management API and console answered on the same public address as the apps, so anyone could find them and try stolen or guessed tokens | Medium-high | Fixed (opt-in): --admin-listen keeps them on a private listener and hides them from the public one; COLOA_ADMIN_ALLOW limits them to listed addresses |
| 22 | No backup of a server: losing the machine lost every app’s data, audit trail, roles and the key to their secrets | High (availability) | Fixed: encrypted, authenticated backups (ChaCha20-Poly1305, truncation-proof chunks) of files, databases and the machine key; restore verifies every audit chain and never silently overwrites a database. The backup key must be kept off the machine: whoever has a backup and its key has all the data |
The fixes are covered by tests/e2e.sh (163 checks), tests/e2e-server.sh (209), tests/e2e-cluster.sh (25) and the unit tests.
coloa_control database holds the whole server state: token hashes, roles, code, sealed secrets (still encrypted with the master key, which is never stored there), audit chains. Whoever administers that Postgres can change it: treat its credentials like the master key. Connections to Postgres are plain unless the URL says sslmode=require (then verified TLS, see the implementation notes): use it whenever Postgres isn’t on the same machine.coloa check reads TypeScript for unlisted hosts and @sensitive reads; Go and Python code is only held to the rules at runtime (egress allowlist, row-level security, masking, caps), which is what actually enforces them.python.wasm comes from the CPython WASI builds a CPython core developer publishes on GitHub, pinned by sha256 (zip and module), and runs inside the same sandbox as user code, so a bad build could misbehave only within a function’s limits and rules. Building it ourselves would remove the dependency (see open questions). Each request’s CPython seeds its own hash randomisation (no shared snapshot).coloa check flags functions that read @sensitive fields; review those.CONNECT) isn’t inspected. Secrets can’t be injected there either, so this only matters for data the code already holds.sdk/). Coloa signs the identity it sends to each service with that service’s own key (x-coloa-signature, see 09-implementation.md). A service that reads x-coloa-user without checking it can still be handed a made-up user by another service of the same app. A captured signed request could be replayed for 5 minutes, but only from inside the services network.require_mfa needs a provider that reports amr (Microsoft Entra, Okta and Keycloak do; Google doesn’t, so enforce 2-Step Verification in Google Workspace instead). Console sessions live in memory: restarting the server signs everyone out.protection.trust_forwarded, or every client shares the proxy’s address.Goal: break promises 1–5 above, as the attackers listed in scope.
Environment to provide: a coloa server with HTTPS and SSO against a test identity provider, two apps (shop and taskboard examples), one with a Python service. Accounts:
Plus a sandboxed agent session (coloa run --sandbox docker).
Priorities:
verify noticing.Out of scope: the host OS and Docker daemon, the identity provider itself, and volumetric DDoS.
Code and tests to hand over: this repository; tests/attacks.sh (side-by-side demo, results in attack-demo-results.md); tests/e2e*.sh.