Skip to content

Commit 5064ff6

Browse files
authored
[DOCS] Adds native realm configuration details (#30215)
1 parent 1391716 commit 5064ff6

File tree

3 files changed

+48
-38
lines changed

3 files changed

+48
-38
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
[role="xpack"]
2+
[[configuring-native-realm]]
3+
=== Configuring a Native Realm
4+
5+
The easiest way to manage and authenticate users is with the internal `native`
6+
realm.
7+
8+
The native realm is available by default when no other realms are
9+
configured. If other realm settings have been configured in `elasticsearch.yml`,
10+
you must add the native realm to the realm chain.
11+
12+
You can configure options for the `native` realm in the
13+
`xpack.security.authc.realms` namespace in `elasticsearch.yml`. Explicitly
14+
configuring a native realm enables you to set the order in which it appears in
15+
the realm chain, temporarily disable the realm, and control its cache options.
16+
17+
. Add a realm configuration of type `native` to `elasticsearch.yml` under the
18+
`xpack.security.authc.realms` namespace. At a minimum, you must set the realm
19+
`type` to `native`. If you are configuring multiple realms, you should also
20+
explicitly set the `order` attribute.
21+
+
22+
--
23+
See <<ref-native-settings>> for all of the options you can set for the `native` realm.
24+
For example, the following snippet shows a `native` realm configuration that
25+
sets the `order` to zero so the realm is checked first:
26+
27+
[source, yaml]
28+
------------------------------------------------------------
29+
xpack:
30+
security:
31+
authc:
32+
realms:
33+
native1:
34+
type: native
35+
order: 0
36+
------------------------------------------------------------
37+
--
38+
39+
. Restart {es}.
40+
41+
. Manage your users in {kib} on the *Management / Security / Users* page.
42+
Alternatively, use the <<security-api-users,User Management APIs>>.
43+

x-pack/docs/en/security/authentication/native-realm.asciidoc

+3-38
Original file line numberDiff line numberDiff line change
@@ -9,47 +9,12 @@ manage user passwords.
99
[float]
1010
==== Configuring a native realm
1111

12-
The native realm is added to the realm chain by default. You don't need to
13-
explicitly configure a native realm to manage users through the REST APIs.
14-
15-
16-
IMPORTANT: When you configure realms in `elasticsearch.yml`, only the
17-
realms you specify are used for authentication. To use the
18-
`native` realm as a fallback, you must include it in the realm chain.
19-
20-
You can, however, configure options for the `native` realm in the
21-
`xpack.security.authc.realms` namespace in `elasticsearch.yml`. Explicitly
22-
configuring a native realm enables you to set the order in which it appears in
23-
the realm chain, temporary disable the realm, and control its cache options.
24-
25-
To configure a native realm:
26-
27-
. Add a realm configuration of type `native` to `elasticsearch.yml` under the
28-
`xpack.security.authc.realms` namespace. At a minimum, you must set the realm
29-
`type` to `native`. If you are configuring multiple realms, you should also
30-
explicitly set the `order` attribute. See <<native-settings, Native Realm Settings>>
31-
for all of the options you can set for the `native` realm.
32-
+
33-
For example, the following snippet shows a `native` realm configuration that
34-
sets the `order` to zero so the realm is checked first:
35-
+
36-
[source, yaml]
37-
------------------------------------------------------------
38-
xpack:
39-
security:
40-
authc:
41-
realms:
42-
native1:
43-
type: native
44-
order: 0
45-
------------------------------------------------------------
46-
47-
. Restart Elasticsearch.
12+
See {ref}/[Configuring a native realm].
4813

4914
[[native-settings]]
5015
==== Native realm settings
5116

52-
See {ref}/security-settings.html#ref-native-settings[Native Realm Settings].
17+
See {ref}/security-settings.html#ref-native-settings[Native realm settings].
5318

5419
[[managing-native-users]]
5520
==== Managing native users
@@ -58,7 +23,7 @@ See {ref}/security-settings.html#ref-native-settings[Native Realm Settings].
5823
*Management / Security / Users* page.
5924

6025
Alternatively, you can manage users through the `user` API. For more
61-
information and examples, see {ref}/security-api-users.html[User Management APIs].
26+
information and examples, see {ref}/security-api-users.html[User management APIs].
6227

6328
[[migrating-from-file]]
6429
NOTE: To migrate file-based users to the `native` realm, use the

x-pack/docs/en/security/configuring-es.asciidoc

+2
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ user API.
7373
. Choose which types of realms you want to use to authenticate users.
7474
** <<configuring-ad-realm,Configure an Active Directory realm>>.
7575
** <<configuring-file-realm,Configure a file realm>>.
76+
** <<configuring-native-realm,Configure a native realm>>.
7677
** <<configuring-pki-realm,Configure a PKI realm>>.
7778

7879
. Set up roles and users to control access to {es}.
@@ -135,6 +136,7 @@ include::securing-communications/enabling-cipher-suites.asciidoc[]
135136
include::securing-communications/separating-node-client-traffic.asciidoc[]
136137
include::authentication/configuring-active-directory-realm.asciidoc[]
137138
include::authentication/configuring-file-realm.asciidoc[]
139+
include::authentication/configuring-native-realm.asciidoc[]
138140
include::authentication/configuring-pki-realm.asciidoc[]
139141
include::{xes-repo-dir}/settings/security-settings.asciidoc[]
140142
include::{xes-repo-dir}/settings/audit-settings.asciidoc[]

0 commit comments

Comments
 (0)