How to Configure Trino Create User
You cannot run a native trino create user command inside the query engine. Instead, you add people in an external identity tool and map them to roles. Data teams often start by linking a directory or a password file to the coordinator. This basic setup gets people in fast, but broad roles soon expose too much data. When one role grants wide read rights, every person in that group sees sensitive tables. How the trino create user setup works in practice Trino separates identity checks from quer
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.
You cannot run a native trino create user command inside the query engine. Instead, you add people in an external identity tool and map them to roles. Data teams often start by linking a directory or a password file to the coordinator. This basic setup gets people in fast, but broad roles soon expose too much data. When one role grants wide read rights, every person in that group sees sensitive tables.
How the trino create user setup works in practice
Trino separates identity checks from query execution. The engine does not store a local table of accounts or passwords. To add a new person, you first register them in your identity system. Teams often use password files, LDAP directories, or token providers for this step. The coordinator checks those external records when a client tries to log in.
Once a person logs in, the coordinator must know what they can do. You handle this through access control plugins or catalog role rules. In a file-based setup, you write rules that match user names to specific catalogs. You can also use SQL role commands if the underlying catalog supports them. These roles group permissions together so you do not manage each person one by one.
A typical workflow has three clear steps. First, an admin adds the account in the external identity provider. Second, the admin assigns that account to a group or a role. Third, the engine reads those group claims and applies catalog rules during login. This split design lets one identity system serve many clusters at once.
Why teams share service accounts across apps
Setting up individual accounts for every person and app takes steady work. Many teams skip this step for dashboards, notebooks, and automated jobs. They create one shared account and put those credentials into several analytics tools. Now every query from those tools arrives at the coordinator under the same name.
This shortcut breaks your audit trail right away. When a bad query slows down the cluster, the logs only show the shared account. You cannot tell which person or script ran the heavy join. Even worse, you must give that shared account permissions for every team that uses it. Anyone using that tool can now query tables meant for other departments.
User Provisioning (SCIM) + End-to-End Encryption: architecture patterns and best practices
Continue reading? Get the full guide.
Free. No spam. Unsubscribe anytime.
What native user setup solves and what it misses
A good identity setup solves the problem of who can log into the cluster. It verifies the person and maps them to a starting set of catalog rules. This stops unknown clients from reaching the coordinator in the first place. It also keeps password management inside your central security tools.
Still, login checks and static roles do not inspect queries in flight. Once a person has read rights on a table, they can select every column. If that table holds emails, phone numbers, or card numbers, the query returns them all. Native login rules also cannot pause a risky query to ask for a peer review. You need controls that act on each statement and mask matched fields in results.
Add runtime guardrails and masking beside your databases and APIs
Login rules, role grants, and CI checks govern who connects to your stack. Yet any allowed script, engineer, or AI agent still runs commands with the full scope of its role. For workloads on Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes, SSH, or internal HTTP services, hoop.dev sits inline in the protocol beside the service as an open-source proxy, a sidecar for your database or API. On every production query an agent or human runs, hoop.dev decides whether to pass, mask, block, or escalate it for review.
Before a query runs, hoop.dev guardrails check the statement against your rules, an AI Analyzer you configure can score intent or hold risky calls for human approval, and hoop.dev data masking rewrites sensitive fields in responses in memory. Explore the MIT-licensed project on GitHub.
Frequently asked questions
Does Trino have a built-in command to create a user?
No, the engine does not store user accounts inside its own system tables. You must add new accounts in an external password file, directory, or identity provider.
How do I give a new Trino user permissions on a catalog?
You map the user name or group to a role in your access control rules. You can also grant role rights through SQL if your catalog connector supports it.
How can I protect sensitive columns when users query shared tables?
Static catalog roles grant table access, so you need field-level masking on query results. Masking rewrites matched fields like emails or national IDs before results reach the client.
Related guides
In this post