You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: ydb/docs/en/core/reference/configuration/index.md
+38-3Lines changed: 38 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -621,19 +621,54 @@ For a configuration located in 3 availability zones, specify 3 rings. For a conf
621
621
622
622
{{ ydb-short-name }} supports various user authentication methods. The configuration for authentication providers is specified in the `auth_config` section.
623
623
624
+
### A Password Complexity Policies {#password-complexity}
625
+
626
+
{{ ydb-short-name }} allows users to be authenticated by login and password. More details can be found in the section [authentication by login and password](../../security/authentication.md#static-credentials). To enhance security in {{ ydb-short-name }} it is possible to configure the complexity of user passwords. You can enable the password complexity policy due include addition section `password_complexity`.
627
+
628
+
Syntax of the `password_complexity` section:
629
+
630
+
```yaml
631
+
auth_config:
632
+
#...
633
+
password_complexity:
634
+
min_length: 8
635
+
min_lower_case_count: 1
636
+
min_upper_case_count: 1
637
+
min_numbers_count: 1
638
+
min_special_chars_count: 1
639
+
special_chars: "!@#$%^&*()_+{}|<>?="
640
+
can_contain_username: false
641
+
#...
642
+
```
643
+
644
+
| Parameter | Description | Default value
645
+
|:---|:---|:---:|
646
+
| `min_length` | Minimal length of the password | 0 |
647
+
| `min_lower_case_count` | Minimal count of letters in lower case | 0 |
648
+
| `min_upper_case_count` | Minimal cont of letters in upper case | 0 |
649
+
| `min_numbers_count` | Minimal count of number in the password | 0 |
650
+
| `min_special_chars_count` | Minimal count of special chars in the password from list `special_chars`| 0 |
651
+
| `special_chars` | Special characters which can be used in the password. Allow use chars from list `!@#$%^&*()_+{}\|<>?=` only. Value (`""`) is equivalent to list `!@#$%^&*()_+{}\|<>?=` | Empty list. Equivalent to all allowed characters: `!@#$%^&*()_+{}\|<>?=` |
652
+
| `can_contain_username` | Allow use username in the password | `false` |
653
+
654
+
{% note info %}
655
+
656
+
Any changes to the password policy do not affect existing user passwords, so it is not necessary to change current passwords; they will be accepted as they are.
657
+
658
+
{% endnote %}
659
+
624
660
### Account lockout after unsuccessful password attempts {#account-lockout}
625
661
626
662
{{ ydb-short-name }} allows for the blocking of user authentication after unsuccessful password entry attempts. Lockout rules are configured in the `account_lockout` section.
Copy file name to clipboardExpand all lines: ydb/docs/en/core/security/authentication.md
+5-1Lines changed: 5 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,7 @@ To enable anonymous authentication, use `false` in the `enforce_user_token_requi
32
32
## Authenticating by username and password {#static-credentials}
33
33
34
34
This access type implies that each database user has a username and password.
35
-
Only digits and lowercase Latin letters can be used in usernames. Passwords are not restricted; even empty passwords are allowed.
35
+
Only digits and lowercase Latin letters can be used in usernames. Allow to set various [criteria](#password-complexity) to password complexity.
36
36
37
37
The username and hashed password are stored in a table inside the authentication component. The password is hashed using the [Argon2](https://en.wikipedia.org/wiki/Argon2) method. Only the system administrator has access to this table.
38
38
@@ -48,6 +48,10 @@ To enable username/password authentication, use `true` in the `enforce_user_toke
48
48
49
49
To learn how to manage roles and users, see [{#T}](../security/authorization.md).
50
50
51
+
### Password complexity {#password-complexity}
52
+
53
+
{{ ydb-short-name }} allows for additional configuration of user password policies. Passwords specified in commands such as CREATE USER and ALTER USER must comply with the current password policy. By default, the following restrictions apply to passwords: passwords of any length are accepted, including empty strings; passwords can contain any number of digits, letters in various cases, and special characters from the list `!@#$%^&*()_+{}|<>?=`. To impose restrictions on password complexity, you need to configure the password_complexity section in the [configuration](../reference/configuration/index.md#password-complexity).
54
+
51
55
### Protection against password brute force
52
56
53
57
{{ ydb-short-name }} provides protection against password brute force. The user will be considered locked out if they exceed the number of allowed incorrect password attempts. After the specified period, they will be able to attempt authentication again.
Copy file name to clipboardExpand all lines: ydb/docs/ru/core/reference/configuration/index.md
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -857,6 +857,12 @@ auth_config:
857
857
| `special_chars` | Специальные символы, которые допустимо использовать в пароле. Допускается указать любое подмножество из следующих символов `!@#$%^&*()_+{}\|<>?=`. Значение (`""`) эквивалентно списку `!@#$%^&*()_+{}\|<>?=` | `""` |
858
858
| `can_contain_username` | Может ли пароль содержать имя пользователя | `false` |
859
859
860
+
{% note info %}
861
+
862
+
Любые изменения политики паролей не затрагивают уже действующие пароли пользователей, поэтому изменять существующие пароли не требуется, они будут приниматься в текущем виде.
863
+
864
+
{% endnote %}
865
+
860
866
### Блокировка пользователя после неуспешных попыток ввода пароля {#account-lockout}
861
867
862
868
{{ ydb-short-name }} позволяет заблокировать возможность аутентификации пользователя после неудачных попыток ввода пароля. Правила блокировки настраиваются в секции `account_lockout`.
@@ -874,7 +880,7 @@ auth_config:
874
880
875
881
| Параметр | Описание | Значение по умолчанию |
876
882
| :--- | :--- | :---: |
877
-
| `attempt_threshold` | Максимальное количество неуспешных попыток ввода правильного пароля. После `attempt_threshold` неуспешных попыток пользователь будет заблокирован на время, заданное в параметре `attempt_reset_duration`. Нулевое значение параметра `attempt_threshold` указывает на отсутствие каких-лио ограничений на число попыток ввода пароля. После успешной аутентификации (ввода правильных имени пользователя и пароля), счетчик неуспешных попыток сбрасывается в значение 0. | 4 |
883
+
| `attempt_threshold` | Максимальное количество неуспешных попыток ввода правильного пароля. После `attempt_threshold` неуспешных попыток пользователь будет заблокирован на время, заданное в параметре `attempt_reset_duration`. Нулевое значение параметра `attempt_threshold` указывает на отсутствие каких-либо ограничений на число попыток ввода пароля. После успешной аутентификации (ввода правильных имени пользователя и пароля), счетчик неуспешных попыток сбрасывается в значение 0. | 4 |
878
884
| `attempt_reset_duration` | Период времени блокировки пользователя. В течение этого периода пользователь не сможет аутентифицироваться в системе даже если введёт правильные имя пользователя и пароль. Период блокировки отсчитывается с момента последней неверной попытки ввода пароля. Если задан нулевой (`"0s"` - запись, эквивалентная 0 секунд) период блокировки, то пользователь будет считаться заблокированным на неограниченное время. В этом случае снять блокировку должен Администратор системы.<br/><br/>Минимальный интервал времени блокировки 1 секунда. <br/>Поддерживаемые единицы измерения:<ul><li>Секунды. `30s`</li><li>Минуты. `20m`</li><li>Часы. `5h`</li><li>Дни. `3d`</li></ul>Не допускается комбинировать единицы измерения в одной строке. Например такая запись некорректна: `1d12h`. Такую запись нужно заменить на эквивалентную, например `36h`. | "1h" |
0 commit comments