docs/src/main/sphinx/security/overview.md
After the initial {doc}installation </installation> of your cluster, security
is the next major concern for successfully operating Trino. This overview
provides an introduction to different aspects of configuring security for your
Trino cluster.
The default installation of Trino has no security features enabled. Security can be enabled for different parts of the Trino architecture:
security-clientsecurity-inside-clustersecurity-data-sourcesTo configure security for a new Trino cluster, follow this best practice order of steps. Do not skip or combine steps.
Enable {doc}TLS/HTTPS </security/tls>
load balancer or proxy <https-load-balancer> to terminate
HTTPS, if possible.{ref}Verify this step is working correctly.<verify-tls>
Configure a {doc}a shared secret </security/internal-communication>
{ref}Verify this step is working correctly.<verify-secrets>
Enable authentication
password file authentication <password-file> to get up
and running.LDAP </security/ldap>.{ref}Verify this step is working correctly.<verify-authentication>
Enable authorization and access control
file-based rules <file-system-access-control>.{ref}Verify this step is working correctly. <verify-rules>
Configure one step at a time. Always restart the Trino server after each change, and verify the results before proceeding.
(security-client)=
Trino {doc}clients </client> include the Trino {doc}CLI </client/cli>,
the {doc}Web UI </admin/web-interface>, the {doc}JDBC driver </client/jdbc>, Python, Go, or other clients, and any applications using these tools.
All access to the Trino cluster is managed by the coordinator. Thus, securing access to the cluster means securing access to the coordinator.
There are three aspects to consider:
cl-access-encrypt: protecting the integrity of client to server
communication in transit.cl-access-auth: identifying users and user name management.cl-access-control: validating each user's access rights.(cl-access-encrypt)=
The Trino server uses the standard {doc}HTTPS protocol and TLS encryption <tls>, formerly known as SSL.
(cl-access-auth)=
Trino supports several authentication providers. When setting up a new cluster, start with simple password file authentication before configuring another provider.
Password file authentication <password-file>LDAP authentication <ldap>Salesforce authentication <salesforce>OAuth 2.0 authentication <oauth2>Certificate authentication <certificate>JSON Web Token (JWT) authentication <jwt>Kerberos authentication <kerberos>(user-name-management)=
Trino provides ways to map the user and group names from authentication providers to Trino usernames.
User mapping <user-mapping> applies to all authentication systems,
and allows for regular expression rules to be specified that map complex
usernames from other systems ([email protected]) to simple usernames
(alice).Group mapping <group-mapping> provides ways to assign a set
of usernames to a group name to ease access control.(cl-access-control)=
Trino's {doc}default method of access control <built-in-system-access-control>
allows all operations for all authenticated users.
To implement access control, use:
File-based system access control <file-system-access-control>, where
you configure JSON files that specify fine-grained user access restrictions at
the catalog, schema, or table level.In addition, Trino {doc}provides an API </develop/system-access-control> that
allows you to create a custom access control method, or to extend an existing
one.
Access control can limit access to columns of a table. The default behavior
of a query to all columns with a SELECT * statement is to show an error
denying access to any inaccessible columns.
You can change this behavior to silently hide inaccessible columns with the
global property hide-inaccessible-columns configured in
{ref}config-properties:
hide-inaccessible-columns = true
(security-inside-cluster)=
You can {doc}secure the internal communication <internal-communication>
between coordinator and workers inside the clusters.
Secrets in properties files, such as passwords in catalog files, can be secured
with {doc}secrets management <secrets>.
(security-data-sources)=
Communication between the Trino cluster and data sources is configured for each catalog. Each catalog uses a connector, which supports a variety of security-related configurations.
More information is available with the documentation for individual
{doc}connectors </connector>.
{doc}Secrets management <secrets> can be used for the catalog properties files
content.