How to Configure JIT Policy

Published
Length
3 min read

Luis Felipe Dias

All posts

A jit policy controls when users get temporary permissions to reach databases and servers. You set it up by linking identity groups to short time limits and approvals. Standing permissions leave databases and servers open to mistakes or stolen keys every day. A temporary rule set removes standing rights so engineers request roles only when needed. When the timer runs out, the system drops the user role on its own. How a jit policy works and safe defaults This rule set maps an identity group

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

A jit policy controls when users get temporary permissions to reach databases and servers. You set it up by linking identity groups to short time limits and approvals.

Standing permissions leave databases and servers open to mistakes or stolen keys every day. A temporary rule set removes standing rights so engineers request roles only when needed. When the timer runs out, the system drops the user role on its own.

How a jit policy works and safe defaults

This rule set maps an identity group to a target role and time limit. When an engineer needs to fix a bug, they send a quick request. The request states the target system, the role level, and a short reason. A team lead or on-call manager reviews the note in chat or email. Once approved, the system grants the role for that specific window.

The setup affects human users, support staff, and third-party contractors who run fixes. Automated apps and background jobs still use their own service roles to run tasks. You should keep human accounts at zero standing rights by default. Start with a short timer like thirty or sixty minutes for write roles. Require at least one peer approval before any production write role turns on. Block self-approval so no single person can grant their own high-level rights.

How to check rules and what static setups miss

To check your setup, test the flow with a regular user account first. Try to log in to a database before you ask for a role. The target system should block the login right away. Next, ask for a read role and have a peer approve the request. Log in again to confirm the session works during the active window. Wait for the timer to end and test that the role drops off.

For audits, log every request, the approver name, the ticket number, and timestamps. Reviewers need these logs to prove that nobody holds permanent production write rights. Still, role grants at the cloud or identity level leave a big gap. Once a session starts, a temporary role still allows any command inside that role. An engineer with a temporary admin role can still drop tables by mistake. They can also run broad queries that pull raw emails, phone numbers, or card numbers. Static role timers also fail to cut off open database sessions when time expires. You need controls that inspect single commands and mask sensitive fields in results.

End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Managing approvals and session limits

Fast approvals keep engineers moving during an urgent outage or late-night fix. Link your request flow to the chat tools your team already uses daily. Route read requests to a broad peer group so someone can approve fast. Route write or admin requests to senior leads who know the target system well. For emergencies, set up a break-glass rule that logs alerts to security teams.

Pair your time limits with data rules that work inside the active session. When a query runs, data masking rewrites matched fields like national IDs in results. Command checks can pause a risky delete statement and ask for a second look. This keeps your data safe even after a user passes the first login check.

Check database and API queries on the wire

Identity tools, roles, and network rules decide who opens a session. Setup alone cannot check what each query does or mask sensitive values in a response once a session starts. When workflows touch Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, or internal HTTP APIs, hoop.dev runs beside those services as an open-source proxy, a sidecar for your Postgres or API. It inspects requests coming in and results going back on the wire.

Your login details and client tools stay as they are while hoop.dev guardrails refuse bad deletes or drops before they run. On responses, hoop.dev data masking rewrites matched sensitive values in memory. Furthermore, hoop.dev holds SOC 2 Type II, is MIT licensed, and writes every query and decision to an audit trail that generates evidence for HIPAA, GDPR, and PCI DSS. See the source on GitHub.

Frequently asked questions

What is the best time limit for a temporary role?

One hour works well for most routine checks and small production fixes. Set shorter timers of fifteen to thirty minutes for high-risk admin roles.

How do teams handle urgent fixes when approvers are asleep?

Teams set up an on-call group so the active responder can approve requests. You can also allow break-glass access that sends high-priority alerts to security.

Does a role timer stop an active database session right away?

Cloud role timers often stop new logins but leave open sessions running. You need session-level controls to end active database connections when the timer ends.

The query runs. The emails stay hidden.