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: versioned_docs/version-3.x/admin-manual/auth/authentication/ldap.md
+17Lines changed: 17 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,6 +57,8 @@ In LDAP, data is organized in a tree structure. Here's an example of a typical L
57
57
ldap_group_basedn = ou=group,o=emr
58
58
# specify ldap_use_ssl to true to use to secured LDAPS protocol, specify false or comment property to use default behavior with plain LDAP
59
59
ldap_use_ssl = true
60
+
# specify ldap_allow_empty_pass to false to prohibit login with non specified LDAP password, specify true or comment property to use default behavior and allow login with empty LDAP password
61
+
ldap_allow_empty_pass = false
60
62
```
61
63
62
64
> To enable LDAPS (encrypted connection to the LDAP server), see the [LDAPS (Encrypted Connection)](#ldaps-encrypted-connection) section below.
@@ -136,6 +138,12 @@ LDAP authentication means password verification through LDAP service to suppleme
136
138
2. If the user doesn't exist in LDAP, it falls back to Doris local password verification.
137
139
3. If the LDAP password is correct but there's no corresponding account in Doris, a temporary user is created for login.
138
140
141
+
> Note on Empty Passwords:
142
+
>
143
+
> By default, Doris allows login with an empty password if the user exists in LDAP (`ldap_allow_empty_pass = true`).
144
+
> This behavior can be disabled by setting `ldap_allow_empty_pass = false` in `ldap.conf`.
145
+
> With such setting Doris will reject all login attempts with empty password and return an error message.
146
+
139
147
### Login Behavior Overview
140
148
141
149
After enabling LDAP, login behaviors under different user states are as follows:
@@ -144,8 +152,10 @@ After enabling LDAP, login behaviors under different user states are as follows:
| Not exists | Exists | Doris password | Success | Doris user |
148
157
| Exists | Not exists | LDAP password | Success | LDAP temporary user |
158
+
| Exists | Not exists | Empty password | Success if `ldap_allow_empty_pass = true`, otherwise Failed | LDAP temporary user (if allowed) |
149
159
150
160
> **About Temporary Users:**
151
161
>
@@ -154,6 +164,12 @@ After enabling LDAP, login behaviors under different user states are as follows:
154
164
> - Temporary user permissions are determined by LDAP group authorization (see "Group Authorization" section below).
155
165
> - If temporary users have no corresponding group permissions, they default to `select_priv` on `information_schema`.
156
166
167
+
> **About Empty Password Security:**
168
+
>
169
+
> The `ldap_allow_empty_pass` configuration provides additional security control:
170
+
> - When `true` (default): Users can accidentally or intentionally log in without a password, which might be convenient for development environments but poses security risks in production.
171
+
> - When `false`: Empty passwords are strictly rejected, ensuring all users must provide valid credentials. This is recommended for production environments to prevent unauthorized access.
172
+
157
173
### Login Examples
158
174
159
175
The following examples assume LDAP authentication is enabled, configured with `ldap_user_filter = (&(uid={login}))`, and the client has set `LIBMYSQL_ENABLE_CLEARTEXT_PLUGIN=1`.
@@ -303,6 +319,7 @@ You can refresh the cache with the `refresh ldap` statement. See [REFRESH-LDAP](
303
319
304
320
- Doris's LDAP functionality only supports cleartext password verification for the client-to-FE segment, meaning that when users log in, passwords are transmitted in plaintext between `client` and `fe`. SSL/TLS encryption between the client and Doris FE must be configured separately (see [Client Connection](#step-2-client-connection)).
305
321
- For the FE-to-LDAP segment, the connection is unencrypted by default (`ldap_use_ssl = false`). To encrypt this segment, set `ldap_use_ssl = true` to use LDAPS (see [LDAPS (Encrypted Connection)](#ldaps-encrypted-connection)).
322
+
- Empty password behavior: By default, Doris allows login with an empty password if the user exists in LDAP (`ldap_allow_empty_pass = true`). This can be disabled by setting `ldap_allow_empty_pass = false` in `ldap.conf`.
Copy file name to clipboardExpand all lines: versioned_docs/version-4.x/admin-manual/auth/authentication/ldap.md
+23Lines changed: 23 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,6 +57,8 @@ In LDAP, data is organized in a tree structure. Here's an example of a typical L
57
57
ldap_group_basedn = ou=group,o=emr
58
58
# specify ldap_use_ssl to true to use to secured LDAPS protocol, specify false or comment property to use default behavior with plain LDAP
59
59
ldap_use_ssl = true
60
+
# specify ldap_allow_empty_pass to false to prohibit login with non specified LDAP password, specify true or comment property to use default behavior and allow login with empty LDAP password
61
+
ldap_allow_empty_pass = false
60
62
```
61
63
62
64
> To enable LDAPS (encrypted connection to the LDAP server), see the [LDAPS (Encrypted Connection)](#ldaps-encrypted-connection) section below.
@@ -135,6 +137,12 @@ LDAP authentication means password verification through LDAP service to suppleme
135
137
2. If the user doesn't exist in LDAP, it falls back to Doris local password verification.
136
138
3. If the LDAP password is correct but there's no corresponding account in Doris, a temporary user is created for login.
137
139
140
+
> Note on Empty Passwords:
141
+
>
142
+
> By default, Doris allows login with an empty password if the user exists in LDAP (`ldap_allow_empty_pass = true`).
143
+
> This behavior can be disabled by setting `ldap_allow_empty_pass = false` in `ldap.conf`.
144
+
> With such setting Doris will reject all login attempts with empty password and return an error message.
145
+
138
146
### Login Behavior Overview
139
147
140
148
After enabling LDAP, login behaviors under different user states are as follows:
@@ -143,8 +151,10 @@ After enabling LDAP, login behaviors under different user states are as follows:
| Not exists | Exists | Doris password | Success | Doris user |
147
156
| Exists | Not exists | LDAP password | Success | LDAP temporary user |
157
+
| Exists | Not exists | Empty password | Success if `ldap_allow_empty_pass = true`, otherwise Failed | LDAP temporary user (if allowed) |
148
158
149
159
> **About Temporary Users:**
150
160
>
@@ -153,6 +163,12 @@ After enabling LDAP, login behaviors under different user states are as follows:
153
163
> - Temporary user permissions are determined by LDAP group authorization (see "Group Authorization" section below).
154
164
> - If temporary users have no corresponding group permissions, they default to `select_priv` on `information_schema`.
155
165
166
+
> **About Empty Password Security:**
167
+
>
168
+
> The `ldap_allow_empty_pass` configuration provides additional security control:
169
+
> - When `true` (default): Users can accidentally or intentionally log in without a password, which might be convenient for development environments but poses security risks in production.
170
+
> - When `false`: Empty passwords are strictly rejected, ensuring all users must provide valid credentials. This is recommended for production environments to prevent unauthorized access.
171
+
156
172
### Login Examples
157
173
158
174
The following examples assume LDAP authentication is enabled, configured with `ldap_user_filter = (&(uid={login}))`, and the client has set `LIBMYSQL_ENABLE_CLEARTEXT_PLUGIN=1`.
@@ -300,8 +316,15 @@ You can refresh the cache with the `refresh ldap` statement. See [REFRESH-LDAP](
300
316
301
317
## Known Limitations
302
318
319
+
<<<<<<< HEAD
303
320
- Doris's LDAP functionality only supports cleartext password verification for the client-to-FE segment, meaning that when users log in, passwords are transmitted in plaintext between `client` and `fe`. SSL/TLS encryption between the client and Doris FE must be configured separately (see [Client Connection](#step-2-client-connection)).
304
321
- For the FE-to-LDAP segment, the connection is unencrypted by default (`ldap_use_ssl = false`). To encrypt this segment, set `ldap_use_ssl = true` to use LDAPS (see [LDAPS (Encrypted Connection)](#ldaps-encrypted-connection)).
322
+
=======
323
+
- Currently, Doris's LDAP functionality only supports cleartext password verification, meaning that when users log in, passwords are transmitted in plaintext between `client` and `fe`, but connection between `fe` and LDAP service can be secured optionally.
324
+
-**For `ldap_use_ssl = false` (default behavior)**: Passwords are transmitted in plain text between the Doris FE and the LDAP server.
325
+
-**To secure the connection**: Set `ldap_use_ssl = true` to encrypt traffic between Doris FE and the LDAP server. Note that SSL/TLS encryption between the **client and Doris FE** must be configured separately.
326
+
-**Empty password behavior:** By default, Doris allows login with an empty password if the user exists in LDAP (`ldap_allow_empty_pass = true`). This can be disabled by setting `ldap_allow_empty_pass = false` in `ldap.conf`.
327
+
>>>>>>> a2a830554a (add docs for allow_empty_pass option for 3.x and 4.x versions)
0 commit comments