Least privilege down to the query

Sits between people, agents and your databases, servers and clusters. It decides on each query and command, with no app changes or SDK.

Decision log
  1. maya@acme.com sends SELECT email FROM customers to postgres-prod. Rule mask-pii-columns: run, mask email. MASKED: returned: a***@example.com.
  2. claude-code · leo sends DELETE FROM users WHERE plan='free' to postgres-prod. Rule no-deletes-in-prod: block. BLOCKED.
  3. claude-code · leo sends SELECT * FROM orders to snowflake. Rule cap-agent-reads: add LIMIT, then run. LIMIT ADDED: rewritten with a row LIMIT.
  4. sam · on call sends kubectl exec -it payments-7f -- sh to k8s-prod. Rule prod-exec-needs-approval: approved in Slack, record. APPROVED: session recorded for replay.
People and agents keep their tools. Formal Connector holds the credentials, runs each query as a native user and decides on it before it reaches your data.

Securing 1M+ requests per second in production

The problem

Production access is all or nothing

To fix one bug in production, an engineer gets a role that can do much more. Scripts and agents get the same keys.

Read access becomes full access

Fine-grained roles rarely exist, so troubleshooting a production database means a role that can also write and delete.

maya · psqlDELETE FROM orders WHERE …ALLOWED

Approvals without context

A ticket says who asked. It doesn't say what they'll run, on which resource, or for how long.

leo · psqlpg_dump prod-db > all.sqlALLOWED

Shared passwords travel

One database password ends up in scripts, laptops and agent configs. When something goes wrong, the log shows the account, not the person.

app_admin · psqlDROP TABLE sessionsALLOWED

# Without Formal, all three go through.

How it works

Three steps to least privilege

  1. Deploy the Connector

    Runs in your VPC as several instances behind a load balancer, on Kubernetes or Amazon ECS, and scales with your traffic.

    YOUR VPC · LOAD BALANCERexample
    • connector-1 healthy✓
    • connector-2 healthy✓
    • connector-3 healthy✓
  2. Sign in as yourself

    Engineers use SSO. Agents use short-lived OIDC identities. A Native User on the Connector holds the real password, key or IAM role.

    WHO CONNECTSexample
    • maya@acme.com · SSOPERSON
    • claude-code for leo · OIDCAGENT · FOR LEO
    • native user app_ro · secret from VaultNEVER SHOWN
  3. Decide on each query and command

    Policies check what's about to run and what comes back: block, mask, limit or ask for approval. Every query and command is logged.

    DECIDED ON EACH QUERYexample
    • DELETE FROM users WHERE plan='free'BLOCKED
    • SELECT name, ssn FROM patientsMASKED
    • SELECT * FROM ordersLIMIT ADDED

Why it's different

Production access, before and after

Without FormalWith Formal PAM
CredentialsShared passwords and long-lived keysNative Users hold them; people and agents never see them
PermissionsA different model per system: SQL GRANTs, cloud IAM, Kubernetes RBACOne policy language for every resource
ApprovalsA ticket that grants a role, with no limitOne action, on one resource, ending on its own
AuditLogs scattered across systemsOne log of every query and command, by person or agent

Capabilities

What teams use PAM for

Database access

Control the query, not the connection

Formal reads each query before it runs and each result before it comes back.

  • Block a DELETE in production, with a message the user sees in their client
  • Mask columns by data label, found by automatic data discovery
  • Add context at runtime with hooks, for example only let a support agent read the customer on its current case
Data masking ›
psql · prod-postgresexample
11:02:07maya@acme.comDELETE FROM users WHERE plan='free'BLOCKED
11:02:40maya@acme.comSELECT name, ssn FROM patientsMASKED
11:03:12support-agent · case 4821SELECT * FROM ticketsFILTERED
Just-in-time

Approve one action, not a role

Ask in Slack for one query on one resource. Approve it for a single run or a time window, and it ends on its own.

  • Default-deny rules with one-off or time-bound exceptions
  • Agents request access through the API; the human who owns them approves in Slack
  • No ticket queue, no admin rights on every console
workflow · prod-write-accessexample
09:41mayaform: UPDATE orders … on prod-postgres, onceREQUESTED
09:42sam (Slack)approveAPPROVED
09:47mayaexception used, closedEXPIRED
Sessions

Record sessions and stop risky ones

Every SSH session and kubectl exec session is recorded and can be replayed.

  • AI risk score from 1 to 5 for each session
  • Session monitors written in plain English
  • End a session or quarantine a user automatically
ssh · prod-bastionexample
15:10:02maya@acme.comssh prod-bastionRECORDED
15:12:44maya@acme.combash <(curl -s https://example.com/setup.sh)BLOCKED
15:12:45monitorrisk score 4, user quarantinedBLOCKED
Credentials

No shared credentials

Native Users hold the upstream credential. People and agents never see it.

  • A value stored in Formal, an environment variable on the Connector, or a hook that fetches it from Vault at connection time
  • Connect with AWS or GCP IAM instead of static keys
  • Engineers keep psql, mysql, mongosh, ssh and kubectl
connect · prod-postgresexample
08:30:01leo@acme.compsql via Formal (no password)ALLOWED
08:30:01connectornative user app_ro from VaultTOKEN INJECTED
08:30:02leo@acme.comsession openedRECORDED
Policy testing

Test a policy on last month's traffic

Backtest a new policy on up to 31 days of past traffic, then dry-run it, then enforce it.

  • Every edit is versioned
  • Formal Agent suggests policies from your logs, and applies them only after a human approves
  • Manage it all with Terraform, Pulumi or the Kubernetes operator
policy · read-only-for-agentsexample
backtest31 dayswould have blocked 3 statementsDRY RUN
dry run7 daysno unexpected blocksDRY RUN
enforcev4liveALLOWED

Coverage and trust

Runs in your infrastructure

Databases
  • PostgreSQL
  • MySQL
  • MariaDB
  • MongoDB
  • Redis
  • DynamoDB
Warehouses
  • Snowflake
  • BigQuery
  • Redshift
  • ClickHouse
Infrastructure
  • SSH
  • AWS SSM
  • Kubernetes
  • RDP
APIs and storage
  • HTTP
  • gRPC
  • AWS APIs
  • GCP APIs
  • S3
AI
  • MCP
  • LLM APIs

Your data

Customer data never goes through Formal's cloud.

Control Plane outages

If the Control Plane is unreachable, running Connectors keep their last configuration.

Monitoring

Connector metrics over OpenTelemetry, with a ready-made Datadog dashboard.

Hosting and trust

Control Plane hosted by Formal, or self-hosted on AWS. SOC 2 Type II, ISO 27001, SSO and SCIM.

Customer proof

Technologies secured
10+
Resources secured
1,000+
Logs per week
40M+
Sessions per week
600K+
“With Formal, we can finally manage least privilege access across our entire infrastructure through a single control plane.”
Tom Daniels
Tom Daniels
CISO, Cursor
Read the Cursor story ›

FAQ

Questions buyers ask us

Do engineers have to change their tools?

No. psql, mysql, mongosh, ssh and kubectl keep working. The Formal CLI sets up the local connection.

Do users ever see the database password?

No. The Native User on the Connector holds it, or fetches it from your vault at connection time.

Can AI agents use it?

Yes. Agents connect as machine users with short-lived OIDC identities, mapped to the human they work for, and follow the same policies.

Does our data go through Formal's cloud?

No. The Connector runs in your infrastructure. The Control Plane only holds configuration and logs.

How is it different from CyberArk, StrongDM or Teleport?

It controls each query and its results, not only the session, and the same policies apply to agents. See the compare pages for details.

Does Formal rotate passwords?

Not automatically today. Native Users can fetch credentials from your vault at connection time.

Put a policy on one production database

See how Notion and Cursor run production access through Formal.