Skip to content

Commit f3e510e

Browse files
committed
Credentials: update per review
1 parent 4530623 commit f3e510e

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

doc/book/admin/access_control.rst

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,7 @@ There are two built-in users in Tarantool:
4343
4444
$ tt connect app:instance001
4545
46-
.. NOTE::
47-
48-
To allow remote :ref:`binary port <admin-security>` connections using the 'admin' user, you need to :ref:`set a password <access_control_user_changing_passwords>`.
46+
To allow remote :ref:`binary port <admin-security>` connections using the 'admin' user, you need to :ref:`set a password <access_control_user_changing_passwords>`.
4947

5048
* 'guest' is a user with minimum permissions used by default for remote :ref:`binary port <admin-security>` connections.
5149
For example, 'guest' is used when connecting to the instance using :ref:`tt connect <tt-connect>` using the IP address and port without specifying the name of a user:
@@ -54,6 +52,10 @@ There are two built-in users in Tarantool:
5452
5553
$ tt connect 192.168.10.10:3301
5654
55+
.. WARNING::
56+
57+
Given that the 'guest' user allows unauthenticated access to Tarantool instances, it is not recommended to grant additional privileges to this user.
58+
For example, granting the 'execute' access to :ref:`'universe' <access_control_concepts_objects>` allows *remote code execution* on instances.
5759

5860
.. NOTE::
5961

@@ -68,9 +70,13 @@ Passwords
6870
~~~~~~~~~
6971

7072
Any user (except 'guest') may have a password.
71-
The password is any alphanumeric string.
73+
If a password is not set, a user cannot connect to Tarantool instances.
74+
7275
Tarantool :ref:`password hashes <enterprise-authentication-protocol>` are stored in the :ref:`_user <box_space-user>` system space.
76+
By default, Tarantool uses the ``CHAP`` protocol to authenticate users and applies ``SHA-1`` hashing to
77+
:ref:`passwords <authentication-passwords>`.
7378
So, if the password is '123456', the stored hash is a string like 'a7SDfrdDKRBe5FaN2n3GftLKKtk='.
79+
In the Enterprise Edition, you can enable ``PAP`` :ref:`authentication <enterprise-authentication-protocol>` with the ``SHA256`` hashing algorithm. In this case, a password is salted with a user-unique salt before saving it in the database.
7480

7581
Tarantool Enterprise Edition allows you to improve database security by enforcing the use of strong passwords, setting up a maximum password age, and so on.
7682
Learn more from the :ref:`configuration_authentication` topic.
@@ -107,6 +113,7 @@ The privileges granted to a user determine which operations the user can perform
107113
* The 'read' and 'write' privileges granted to the 'space' :ref:`object <access_control_concepts_objects>` allow a user to select or update data in the specified space.
108114
* The 'create' privilege granted to the 'space' object allows a user to create new spaces.
109115
* The 'execute' privilege granted to the 'function' object allows a user to execute the specified function.
116+
* The 'session' privilege granted to a user allows connecting to the instance over IPROTO.
110117

111118
Note that some privileges might require read and write access to certain system spaces.
112119
For example, the 'create' privilege granted to the 'space' object requires 'read' and 'write' privileges to the :ref:`_space <box_space-space>` system space.
@@ -132,6 +139,10 @@ There are the following built-in roles in Tarantool:
132139
* 'replication' can be granted to a user used to maintain replication in a cluster.
133140
* 'sharding' can be granted to a user used to maintain sharding in a cluster.
134141

142+
.. NOTE::
143+
144+
The 'sharding' role is created only if an instance is managed using :ref:`YAML configuration <configuration_overview>`.
145+
135146
Below are a few diagrams that demonstrate how privileges can be granted to a user without and with using roles.
136147

137148
* In this example, a user gets privileges directly without using roles.
@@ -178,7 +189,7 @@ Object owners
178189
An owner of a database :ref:`object <access_control_concepts_objects>` is the user who created it.
179190
The owner of the database and the owner of objects that are created initially (the system spaces and the default users) is the 'admin' :ref:`user <access_control_concepts_users>`.
180191

181-
Owners automatically have :ref:`privileges <authentication-owners_privileges>` for what they create.
192+
Owners automatically have :ref:`privileges <authentication-owners_privileges>` for objects they create.
182193
They can :ref:`share these privileges <access_control_granting_privileges>` with other users or roles using ``box.schema.user.grant()`` and ``box.schema.role.grant()``.
183194

184195
.. NOTE::
@@ -325,7 +336,7 @@ To get information about privileges granted to a user, call :ref:`box.schema.use
325336
326337
In the example above, 'testuser' has the following privileges:
327338

328-
* The 'execute' privilege to the 'public' role means that this role is :ref:`assigned to a user <access_control_roles_granting_user>`.
339+
* The 'execute' privilege to the 'public' role means that this role is :ref:`assigned to the user <access_control_roles_granting_user>`.
329340

330341
* The 'read' privilege to the ``writers`` space means that a user can read data from this space.
331342

@@ -934,7 +945,7 @@ Privileges
934945

935946
* - Privilege
936947
- Object type
937-
- Applied to roles
948+
- Granted to roles
938949
- Description
939950
* - 'read'
940951
- All

0 commit comments

Comments
 (0)