security-settings.asciidoc 108 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723
  1. [role="xpack"]
  2. [[security-settings]]
  3. === Security settings in {es}
  4. ++++
  5. <titleabbrev>Security settings</titleabbrev>
  6. ++++
  7. You configure `xpack.security` settings to
  8. <<anonymous-access-settings,enable anonymous access>> and perform message
  9. authentication,
  10. <<field-document-security-settings,set up document and field level security>>,
  11. <<realm-settings,configure realms>>,
  12. <<ssl-tls-settings,encrypt communications with SSL>>,and
  13. <<auditing-settings,audit security events>>.
  14. All of these settings can be added to the `elasticsearch.yml` configuration file,
  15. with the exception of the secure settings, which you add to the {es} keystore.
  16. For more information about creating and updating the {es} keystore, see
  17. <<secure-settings>>.
  18. [discrete]
  19. [[general-security-settings]]
  20. ==== General security settings
  21. `xpack.security.enabled`::
  22. (<<static-cluster-setting,Static>>)
  23. Defaults to `true`, which enables {es} {security-features} on the node.
  24. This setting must be enabled to use Elasticsearch's authentication,
  25. authorization and audit features. +
  26. +
  27. --
  28. If set to `false`, {security-features} are disabled, which is not recommended.
  29. It also affects all {kib} instances that connect to this {es} instance; you do
  30. not need to disable {security-features} in those `kibana.yml` files. For more
  31. information about disabling {security-features} in specific {kib} instances, see
  32. {kibana-ref}/security-settings-kb.html[{kib} security settings].
  33. --
  34. `xpack.security.autoconfiguration.enabled`::
  35. (<<static-cluster-setting,Static>>)
  36. Defaults to `true`, which enables
  37. <<configuring-stack-security,security auto configuration>>.
  38. +
  39. --
  40. If set to `false`, security auto configuration is disabled, which is not
  41. recommended. When disabled, security is not configured automatically when
  42. starting {es} for the first time, which means that you must
  43. <<manually-configure-security,manually configure security>>.
  44. --
  45. `xpack.security.enrollment.enabled`::
  46. (<<static-cluster-setting,Static>>)
  47. Defaults to `false`. Controls enrollment (of nodes and {kib}) to a local node
  48. that's been <<configuring-stack-security, autoconfigured for security>>.
  49. When set to `true`, the local node can generate new enrollment tokens. Existing
  50. tokens can be used for enrollment if they are still valid.
  51. +
  52. --
  53. The security autoconfiguration process will set this to `true` unless
  54. an administrator sets it to `false` before starting {es}.
  55. --
  56. `xpack.security.hide_settings`::
  57. (<<static-cluster-setting,Static>>)
  58. A comma-separated list of settings that are omitted from the results of the
  59. <<cluster-nodes-info,cluster nodes info API>>. You can use wildcards to include
  60. multiple settings in the list. For example, the following value hides all the
  61. settings for the ad1 active_directory realm:
  62. `xpack.security.authc.realms.active_directory.ad1.*`.
  63. The API already omits all `ssl` settings, `bind_dn`, and `bind_password` due to
  64. the sensitive nature of the information.
  65. `xpack.security.fips_mode.enabled`::
  66. (<<static-cluster-setting,Static>>)
  67. Enables fips mode of operation. Set this to `true` if you run this {es} instance in a FIPS 140-2 enabled JVM. For more information, see <<fips-140-compliance>>. Defaults to `false`.
  68. `xpack.security.fips_mode.required_providers`::
  69. (<<static-cluster-setting,Static>>)
  70. Optionally enforce specific Java JCE/JSSE security providers. For example, set this to `["BCFIPS", "BCJSSE"]` (case-insensitive) to require
  71. the Bouncy Castle FIPS JCE and JSSE security providers. Only applicable when `xpack.security.fips_mode.enabled` is set to `true`.
  72. [discrete]
  73. [[password-hashing-settings]]
  74. ==== Password hashing settings
  75. `xpack.security.authc.password_hashing.algorithm`::
  76. (<<static-cluster-setting,Static>>)
  77. Specifies the hashing algorithm that is used for secure user credential storage.
  78. See <<password-hashing-algorithms>>.
  79. If `xpack.security.fips_mode.enabled` is true (see <<fips-140-compliance>>), defaults to `pbkdf2_stretch`.
  80. In all other cases, defaults to `bcrypt`.
  81. [discrete]
  82. [[anonymous-access-settings]]
  83. ==== Anonymous access settings
  84. You can configure the following anonymous access settings in
  85. `elasticsearch.yml`. For more information, see <<anonymous-access>>.
  86. `xpack.security.authc.anonymous.username`::
  87. (<<static-cluster-setting,Static>>)
  88. The username (principal) of the anonymous user. Defaults to `_es_anonymous_user`.
  89. `xpack.security.authc.anonymous.roles`::
  90. (<<static-cluster-setting,Static>>)
  91. The roles to associate with the anonymous user. Required.
  92. `xpack.security.authc.anonymous.authz_exception`::
  93. (<<static-cluster-setting,Static>>)
  94. When `true`, an HTTP 403 response is returned if the anonymous user
  95. does not have the appropriate permissions for the requested action. The
  96. user is not prompted to provide credentials to access the requested
  97. resource. When set to `false`, an HTTP 401 response is returned and the user
  98. can provide credentials with the appropriate permissions to gain
  99. access. Defaults to `true`.
  100. [discrete]
  101. [[security-automata-settings]]
  102. ==== Automata Settings
  103. In places where the {security-features} accept wildcard patterns (e.g. index
  104. patterns in roles, group matches in the role mapping API), each pattern is
  105. compiled into an Automaton. The follow settings are available to control this
  106. behaviour.
  107. `xpack.security.automata.max_determinized_states`::
  108. (<<static-cluster-setting,Static>>)
  109. The upper limit on how many automaton states may be created by a single pattern.
  110. This protects against too-difficult (e.g. exponentially hard) patterns.
  111. Defaults to `100,000`.
  112. `xpack.security.automata.cache.enabled`::
  113. (<<static-cluster-setting,Static>>)
  114. Whether to cache the compiled automata. Compiling automata can be CPU intensive
  115. and may slowdown some operations. The cache reduces the frequency with which
  116. automata need to be compiled.
  117. Defaults to `true`.
  118. `xpack.security.automata.cache.size`::
  119. (<<static-cluster-setting,Static>>)
  120. The maximum number of items to retain in the automata cache.
  121. Defaults to `10,000`.
  122. `xpack.security.automata.cache.ttl`::
  123. (<<static-cluster-setting,Static>>)
  124. The length of time to retain in an item in the automata cache (based on most
  125. recent usage).
  126. Defaults to `48h` (48 hours).
  127. [discrete]
  128. [[field-document-security-settings]]
  129. ==== Document and field level security settings
  130. You can set the following document and field level security
  131. settings in `elasticsearch.yml`. For more information, see
  132. <<field-and-document-access-control>>.
  133. `xpack.security.dls_fls.enabled`::
  134. (<<static-cluster-setting,Static>>)
  135. Set to `false` to prevent document and field level security
  136. from being configured. Defaults to `true`.
  137. `xpack.security.dls.bitset.cache.ttl`::
  138. (<<static-cluster-setting,Static>>)
  139. The time-to-live for cached `BitSet` entries for document level security.
  140. Document level security queries may depend on Lucene BitSet objects, and these are
  141. automatically cached to improve performance. Defaults to expire entries that are
  142. unused for `2h` (2 hours).
  143. `xpack.security.dls.bitset.cache.size`::
  144. (<<static-cluster-setting,Static>>)
  145. The maximum memory usage of cached `BitSet` entries for document level security.
  146. Document level security queries may depend on Lucene BitSet objects, and these are
  147. automatically cached to improve performance. Can be configured as a raw number
  148. of bytes (such as `200mb` or `1g`) or a percentage of the node's JVM heap
  149. memory (such as `5%`). When the default value is exceeded, the least recently
  150. used entries are evicted. Defaults to `10%` of the heap assigned to the node.
  151. [discrete]
  152. [[token-service-settings]]
  153. ==== Token service settings
  154. You can set the following token service settings in
  155. `elasticsearch.yml`.
  156. `xpack.security.authc.token.enabled`::
  157. (<<static-cluster-setting,Static>>)
  158. Set to `false` to disable the built-in token service. Defaults to `true` unless
  159. `xpack.security.http.ssl.enabled` is `false`. This prevents sniffing the token
  160. from a connection over plain http.
  161. `xpack.security.authc.token.timeout`::
  162. (<<static-cluster-setting,Static>>)
  163. The length of time that a token is valid for. By default this value is `20m` or
  164. 20 minutes. The maximum value is 1 hour.
  165. [discrete]
  166. [[api-key-service-settings]]
  167. ==== API key service settings
  168. You can set the following API key service settings in
  169. `elasticsearch.yml`.
  170. `xpack.security.authc.api_key.enabled`::
  171. (<<static-cluster-setting,Static>>)
  172. Set to `false` to disable the built-in API key service. Defaults to `true`.
  173. `xpack.security.authc.api_key.cache.ttl`::
  174. (<<static-cluster-setting,Static>>)
  175. The time-to-live for cached API key entries. A API key id and a hash of its
  176. API key are cached for this period of time. Specify the time period using
  177. the standard {es} <<time-units,time units>>. Defaults to `1d`.
  178. `xpack.security.authc.api_key.cache.max_keys`::
  179. (<<static-cluster-setting,Static>>)
  180. The maximum number of API key entries that can live in the
  181. cache at any given time. Defaults to 10,000.
  182. `xpack.security.authc.api_key.cache.hash_algo`::
  183. (<<static-cluster-setting,Static>>, Expert)
  184. The hashing algorithm that is used for the
  185. in-memory cached API key credentials. For possible values, see <<cache-hash-algo>>.
  186. Defaults to `ssha256`.
  187. [[api-key-service-settings-delete-retention-period]]
  188. `xpack.security.authc.api_key.delete.retention_period`::
  189. (<<dynamic-cluster-setting,Dynamic>>)
  190. Invalidated or expired API keys older than the retention period are eligible for deletion.
  191. Defaults to `7d`.
  192. --
  193. NOTE: Large real-time clock inconsistency across cluster nodes can cause problems
  194. with evaluating the API key retention period. That is, if the clock on the node
  195. invalidating the API key is significantly different than the one performing the deletion,
  196. the key may be retained for longer or shorter than the configured retention period.
  197. --
  198. `xpack.security.authc.api_key.delete.interval`::
  199. (<<dynamic-cluster-setting,Dynamic>>, Expert)
  200. Cluster nodes schedule the automatic deletion of invalidated or expired API keys
  201. that are older than the retention period.
  202. This setting controls the minimum time interval between two such deletion jobs.
  203. Defaults to `24h`.
  204. +
  205. NOTE: This is a low-level setting that currently controls the interval between
  206. deletion jobs triggered per-node, not across the cluster.
  207. `xpack.security.authc.api_key.delete.timeout`::
  208. (<<static-cluster-setting,Static>>, Expert)
  209. Sets the timeout of the internal search and delete call.
  210. `xpack.security.authc.api_key.hashing.algorithm`::
  211. (<<static-cluster-setting,Static>>)
  212. Specifies the hashing algorithm that is used for securing API key credentials.
  213. See <<password-hashing-algorithms>>. Defaults to `pbkdf2`.
  214. [discrete]
  215. [[security-domain-settings]]
  216. ==== Security domain settings
  217. // tag::security-domain-settings-description-tag[]
  218. You configure security domain settings in the `xpack.security.authc.domains`
  219. namespace in `elasticsearch.yml`.
  220. For example:
  221. [source, yaml]
  222. ------------------------------------------------------------
  223. xpack:
  224. security:
  225. authc:
  226. domains:
  227. my_domain: <1>
  228. realms: [ 'default_native', 'saml1' ] <2>
  229. ------------------------------------------------------------
  230. <1> Specifies the name of the security domain
  231. <2> Specifies the realms that belong to the domain
  232. // end::security-domain-settings-description-tag[]
  233. [discrete]
  234. [[realm-settings]]
  235. ==== Realm settings
  236. // tag::realm-settings-description-tag[]
  237. You configure realm settings in the `xpack.security.authc.realms`
  238. namespace in `elasticsearch.yml`.
  239. For example:
  240. [source,yaml]
  241. ----------------------------------------
  242. xpack.security.authc.realms:
  243. native.realm1: <1>
  244. order: 0 <2>
  245. ...
  246. ldap.realm2:
  247. order: 1
  248. ...
  249. active_directory.realm3:
  250. order: 2
  251. ...
  252. ...
  253. ----------------------------------------
  254. <1> Specifies the type of realm (for example, `native`, `ldap`,
  255. `active_directory`, `pki`, `file`, `kerberos`, `saml`) and the realm name. This
  256. information is required.
  257. <2> Specifies priority of a realm in the realm chain. This information
  258. is required.
  259. The valid settings vary depending on the realm type. For more
  260. information, see <<setting-up-authentication>>.
  261. // end::realm-settings-description-tag[]
  262. [discrete]
  263. [[ref-realm-settings]]
  264. ===== Settings valid for all realms
  265. // tag::realm-order-tag[]
  266. `order`::
  267. (<<static-cluster-setting,Static>>)
  268. The priority of the realm within the realm chain. Realms with a lower order are
  269. consulted first. The value must be unique for each realm. This setting is required.
  270. // end::realm-order-tag[]
  271. `enabled`::
  272. (<<static-cluster-setting,Static>>)
  273. Indicates whether a realm is enabled. You can use this setting to disable a
  274. realm without removing its configuration information. Defaults to `true`.
  275. [[ref-native-settings]]
  276. [discrete]
  277. ===== Native realm settings
  278. In addition to the <<ref-realm-settings,settings that are valid for all realms>>,
  279. you can specify the following optional settings:
  280. `cache.ttl`::
  281. (<<static-cluster-setting,Static>>)
  282. The time-to-live for cached user entries. A user and a hash of its
  283. credentials are cached for this period of time. Specify the time period using
  284. the standard {es} <<time-units,time units>>. Defaults to `20m`.
  285. `cache.max_users`::
  286. (<<static-cluster-setting,Static>>)
  287. The maximum number of user entries that can live in the
  288. cache at any given time. Defaults to 100,000.
  289. `cache.hash_algo`::
  290. (<<static-cluster-setting,Static>>, Expert)
  291. The hashing algorithm that is used for the
  292. in-memory cached user credentials. For possible values, see <<cache-hash-algo>>.
  293. Defaults to `ssha256`.
  294. `authentication.enabled`::
  295. (<<static-cluster-setting,Static>>)
  296. If set to `false`, disables authentication support in
  297. this realm, so that it only supports user lookups.
  298. (See the <<run-as-privilege,run as>> and
  299. <<authorization_realms,authorization realms>> features).
  300. Defaults to `true`.
  301. [[ref-users-settings]]
  302. [discrete]
  303. ===== File realm settings
  304. In addition to the <<ref-realm-settings,settings that are valid for all realms>>, you can specify
  305. the following settings:
  306. `cache.ttl`::
  307. (<<static-cluster-setting,Static>>)
  308. The time-to-live for cached user entries. A user and a hash of its credentials
  309. are cached for this configured period of time. Defaults to `20m`. Specify values
  310. using the standard {es} <<time-units,time units>>.
  311. Defaults to `20m`.
  312. `cache.max_users`::
  313. (<<static-cluster-setting,Static>>)
  314. The maximum number of user entries that can live in the cache at a given time.
  315. Defaults to 100,000.
  316. `cache.hash_algo`::
  317. (<<static-cluster-setting,Static>>, Expert)
  318. The hashing algorithm that is used for the in-memory cached
  319. user credentials. See <<cache-hash-algo>>. Defaults to `ssha256`.
  320. `authentication.enabled`::
  321. (<<static-cluster-setting,Static>>)
  322. If set to `false`, disables authentication support in
  323. this realm, so that it only supports user lookups.
  324. (See the <<run-as-privilege,run as>> and
  325. <<authorization_realms,authorization realms>> features).
  326. Defaults to `true`.
  327. [[ref-ldap-settings]]
  328. [discrete]
  329. ===== LDAP realm settings
  330. In addition to the <<ref-realm-settings>>, you can specify the following settings:
  331. `url`::
  332. (<<static-cluster-setting,Static>>)
  333. One or more LDAP URLs in the `ldap[s]://<server>:<port>` format. Required.
  334. +
  335. To provide multiple URLs, use a YAML array (`["ldap://server1:636", "ldap://server2:636"]`)
  336. or comma-separated string (`"ldap://server1:636, ldap://server2:636"`).
  337. +
  338. While both are supported, you can't mix the `ldap` and `ldaps` protocols.
  339. `load_balance.type`::
  340. (<<static-cluster-setting,Static>>)
  341. The behavior to use when there are multiple LDAP URLs defined. For supported
  342. values see <<load-balancing,load balancing and failover types>>.
  343. Defaults to `failover`.
  344. `load_balance.cache_ttl`::
  345. (<<static-cluster-setting,Static>>)
  346. When using `dns_failover` or `dns_round_robin` as the load balancing type,
  347. this setting controls the amount of time to cache DNS lookups. Defaults
  348. to `1h`.
  349. `bind_dn`::
  350. (<<static-cluster-setting,Static>>)
  351. The DN of the user that is used to bind to the LDAP and perform searches.
  352. Only applicable in user search mode.
  353. If not specified, an anonymous bind is attempted.
  354. Defaults to Empty. Due to its potential security impact, `bind_dn` is not
  355. exposed via the <<cluster-nodes-info,nodes info API>>.
  356. `bind_password`::
  357. (<<static-cluster-setting,Static>>)
  358. deprecated[6.3] Use `secure_bind_password` instead. The password for the user
  359. that is used to bind to the LDAP directory.
  360. Defaults to Empty. Due to its potential security impact, `bind_password` is not
  361. exposed via the <<cluster-nodes-info,nodes info API>>.
  362. `secure_bind_password`::
  363. (<<secure-settings,Secure>>, <<reloadable-secure-settings,Reloadable>>)
  364. The password for the user that is used to bind to the LDAP directory.
  365. Defaults to Empty.
  366. `user_dn_templates`::
  367. (<<static-cluster-setting,Static>>)
  368. The DN template that replaces the user name with the string `{0}`.
  369. This setting is multivalued; you can specify multiple user contexts.
  370. Required to operate in user template mode. If `user_search.base_dn` is specified,
  371. this setting is not valid. For more information on
  372. the different modes, see <<ldap-realm>>.
  373. `authorization_realms`::
  374. (<<static-cluster-setting,Static>>)
  375. The names of the realms that should be consulted for delegated authorization.
  376. If this setting is used, then the LDAP realm does not perform role mapping and
  377. instead loads the user from the listed realms. The referenced realms are
  378. consulted in the order that they are defined in this list.
  379. See <<authorization_realms>>.
  380. +
  381. --
  382. NOTE: If any settings starting with `user_search` are specified, the
  383. `user_dn_templates` settings are ignored.
  384. --
  385. `user_group_attribute`::
  386. (<<static-cluster-setting,Static>>)
  387. Specifies the attribute to examine on the user for group membership.
  388. If any `group_search` settings are specified, this setting is ignored. Defaults
  389. to `memberOf`.
  390. `user_full_name_attribute`::
  391. (<<static-cluster-setting,Static>>)
  392. Specifies the attribute to examine on the user for the full name of the user.
  393. Defaults to `cn`.
  394. `user_email_attribute`::
  395. (<<static-cluster-setting,Static>>)
  396. Specifies the attribute to examine on the user for the email address of the user.
  397. Defaults to `mail`.
  398. `user_search.base_dn`::
  399. (<<static-cluster-setting,Static>>)
  400. Specifies a container DN to search for users. Required
  401. to operated in user search mode. If `user_dn_templates` is specified, this
  402. setting is not valid. For more information on
  403. the different modes, see <<ldap-realm>>.
  404. `user_search.scope`::
  405. (<<static-cluster-setting,Static>>)
  406. The scope of the user search. Valid values are `sub_tree`, `one_level` or
  407. `base`. `one_level` only searches objects directly contained within the
  408. `base_dn`. `sub_tree` searches all objects contained under `base_dn`.
  409. `base` specifies that the `base_dn` is the user object, and that it is
  410. the only user considered. Defaults to `sub_tree`.
  411. `user_search.filter`::
  412. (<<static-cluster-setting,Static>>)
  413. Specifies the filter used to search the directory in attempts to match
  414. an entry with the username provided by the user. Defaults to `(uid={0})`.
  415. `{0}` is substituted with the username provided when searching.
  416. `user_search.attribute`::
  417. (<<static-cluster-setting,Static>>)
  418. deprecated[5.6] Use `user_search.filter` instead.
  419. The attribute to match with the username sent with the request. Defaults to `uid`.
  420. `user_search.pool.enabled`::
  421. (<<static-cluster-setting,Static>>)
  422. Enables or disables connection pooling for user search. If set to `false`, a new
  423. connection is created for every search. The
  424. default is `true` when `bind_dn` is set.
  425. `user_search.pool.size`::
  426. (<<static-cluster-setting,Static>>)
  427. The maximum number of connections to the LDAP server to allow in the
  428. connection pool. Defaults to `20`.
  429. `user_search.pool.initial_size`::
  430. (<<static-cluster-setting,Static>>)
  431. The initial number of connections to create to the LDAP server on startup.
  432. Defaults to `0`. If the LDAP server is down, values greater than `0` could cause
  433. startup failures.
  434. `user_search.pool.health_check.enabled`::
  435. (<<static-cluster-setting,Static>>)
  436. Enables or disables a health check on LDAP connections in the connection
  437. pool. Connections are checked in the background at the specified interval.
  438. Defaults to `true`.
  439. `user_search.pool.health_check.dn`::
  440. (<<static-cluster-setting,Static>>)
  441. The distinguished name that is retrieved as part of the health check.
  442. Defaults to the value of `bind_dn` if present; if
  443. not, falls back to `user_search.base_dn`.
  444. `user_search.pool.health_check.interval`::
  445. (<<static-cluster-setting,Static>>)
  446. The interval to perform background checks of connections in the pool.
  447. Defaults to `60s`.
  448. `group_search.base_dn`::
  449. (<<static-cluster-setting,Static>>)
  450. The container DN to search for groups in which the user has membership. When
  451. this element is absent, {es} searches for the attribute specified by
  452. `user_group_attribute` set on the user in order to determine group membership.
  453. `group_search.scope`::
  454. (<<static-cluster-setting,Static>>)
  455. Specifies whether the group search should be `sub_tree`, `one_level` or
  456. `base`. `one_level` only searches objects directly contained within the
  457. `base_dn`. `sub_tree` searches all objects contained under `base_dn`.
  458. `base` specifies that the `base_dn` is a group object, and that it is the
  459. only group considered. Defaults to `sub_tree`.
  460. `group_search.filter`::
  461. (<<static-cluster-setting,Static>>)
  462. Specifies a filter to use to look up a group.
  463. When not set, the realm searches for `group`, `groupOfNames`, `groupOfUniqueNames`,
  464. or `posixGroup` with the attributes `member`, `memberOf`, or `memberUid`. Any
  465. instance of `{0}` in the filter is replaced by the user attribute defined in
  466. `group_search.user_attribute`.
  467. `group_search.user_attribute`::
  468. (<<static-cluster-setting,Static>>)
  469. Specifies the user attribute that is fetched and provided as a parameter to
  470. the filter. If not set, the user DN is passed into the filter. Defaults to Empty.
  471. `unmapped_groups_as_roles`::
  472. (<<static-cluster-setting,Static>>)
  473. If set to `true`, the names of any unmapped LDAP groups are used as role names
  474. and assigned to the user. A group is considered to be _unmapped_ if it is not
  475. referenced in a <<mapping-roles-file,role-mapping file>>. API-based
  476. role mappings are not considered. Defaults to `false`.
  477. `files.role_mapping`::
  478. (<<static-cluster-setting,Static>>)
  479. The <<security-files,location>> for the
  480. <<mapping-roles,YAML role mapping configuration file>>. Defaults to
  481. `ES_PATH_CONF/role_mapping.yml`.
  482. `follow_referrals`::
  483. (<<static-cluster-setting,Static>>)
  484. Specifies whether {es} should follow referrals returned
  485. by the LDAP server. Referrals are URLs returned by the server that are to be
  486. used to continue the LDAP operation (for example, search). Defaults to `true`.
  487. `metadata`::
  488. (<<static-cluster-setting,Static>>)
  489. A list of additional LDAP attributes that should be loaded from the
  490. LDAP server and stored in the authenticated user's metadata field.
  491. `timeout.tcp_connect`::
  492. (<<static-cluster-setting,Static>>)
  493. The TCP connect timeout period for establishing an LDAP connection.
  494. An `s` at the end indicates seconds, or `ms` indicates milliseconds.
  495. Defaults to `5s` (5 seconds ).
  496. `timeout.tcp_read`::
  497. (<<static-cluster-setting,Static>>)
  498. deprecated[7.7] The TCP read timeout period after establishing an LDAP
  499. connection. This is equivalent to and is deprecated in favor of
  500. `timeout.response` and they cannot be used simultaneously. An `s` at the end
  501. indicates seconds, or `ms` indicates milliseconds.
  502. `timeout.response`::
  503. (<<static-cluster-setting,Static>>)
  504. The time interval to wait for the response from the LDAP server. An `s` at the
  505. end indicates seconds, or `ms` indicates milliseconds. Defaults to the value of
  506. `timeout.ldap_search`.
  507. `timeout.ldap_search`::
  508. (<<static-cluster-setting,Static>>)
  509. The timeout period for an LDAP search. The value is specified in the request
  510. and is enforced by the receiving LDAP Server.
  511. An `s` at the end indicates seconds, or `ms` indicates milliseconds.
  512. Defaults to `5s` (5 seconds ).
  513. `ssl.key`::
  514. (<<static-cluster-setting,Static>>)
  515. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-pem]
  516. +
  517. If the LDAP server requires client authentication, it uses this file. You cannot
  518. use this setting and `ssl.keystore.path` at the same time.
  519. `ssl.key_passphrase`::
  520. (<<static-cluster-setting,Static>>)
  521. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-passphrase]
  522. `ssl.secure_key_passphrase`::
  523. (<<secure-settings,Secure>>)
  524. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-secure-key-passphrase]
  525. `ssl.certificate`::
  526. (<<static-cluster-setting,Static>>)
  527. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate]
  528. +
  529. This certificate is presented to clients when they connect.
  530. `ssl.certificate_authorities`::
  531. (<<static-cluster-setting,Static>>)
  532. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate-authorities]
  533. +
  534. You cannot use this setting and `ssl.truststore.path` at the same time.
  535. `ssl.keystore.path`::
  536. (<<static-cluster-setting,Static>>)
  537. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-path]
  538. +
  539. You cannot use this setting and `ssl.key` at the same time.
  540. `ssl.keystore.type`::
  541. (<<static-cluster-setting,Static>>)
  542. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-type-pkcs12]
  543. `ssl.keystore.password`::
  544. (<<static-cluster-setting,Static>>)
  545. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-password]
  546. `ssl.keystore.secure_password`::
  547. (<<secure-settings,Secure>>)
  548. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-password]
  549. `ssl.keystore.key_password`::
  550. (<<static-cluster-setting,Static>>)
  551. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-key-password]
  552. `ssl.keystore.secure_key_password`::
  553. (<<static-cluster-setting,Static>>)
  554. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-key-password]
  555. `ssl.truststore.path`::
  556. (<<static-cluster-setting,Static>>)
  557. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-path]
  558. +
  559. You cannot use this setting and `ssl.certificate_authorities` at the same time.
  560. `ssl.truststore.password`::
  561. (<<static-cluster-setting,Static>>)
  562. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-password]
  563. `ssl.truststore.secure_password`::
  564. (<<secure-settings,Secure>>)
  565. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-secure-password]
  566. `ssl.truststore.type`::
  567. (<<static-cluster-setting,Static>>)
  568. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-type]
  569. `ssl.verification_mode`::
  570. (<<static-cluster-setting,Static>>)
  571. Indicates the type of verification when using `ldaps` to protect against man
  572. in the middle attacks and certificate forgery.
  573. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-verification-mode-values]
  574. `ssl.supported_protocols`::
  575. (<<static-cluster-setting,Static>>)
  576. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-supported-protocols]
  577. `ssl.cipher_suites`::
  578. (<<static-cluster-setting,Static>>)
  579. Specifies the cipher suites that should be supported when
  580. communicating with the LDAP server.
  581. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-cipher-suites-values]
  582. //TBD: Can this be updated to using the Java 11 URL instead or does it have to stay java8?
  583. `cache.ttl`::
  584. (<<static-cluster-setting,Static>>)
  585. Specifies the time-to-live for cached user entries. A user and a hash of its
  586. credentials are cached for this period of time. Use the standard {es}
  587. <<time-units,time units>>. Defaults to `20m`.
  588. `cache.max_users`::
  589. (<<static-cluster-setting,Static>>)
  590. Specifies the maximum number of user entries that the cache can contain.
  591. Defaults to `100000`.
  592. `cache.hash_algo`::
  593. (<<static-cluster-setting,Static>>, Expert)
  594. Specifies the hashing algorithm that is used for the
  595. in-memory cached user credentials. See <<cache-hash-algo>>. Defaults to `ssha256`.
  596. `authentication.enabled`::
  597. (<<static-cluster-setting,Static>>)
  598. If set to `false`, disables authentication support in
  599. this realm, so that it only supports user lookups.
  600. (See the <<run-as-privilege,run as>> and
  601. <<authorization_realms,authorization realms>> features).
  602. Defaults to `true`.
  603. [[ref-ad-settings]]
  604. [discrete]
  605. ===== Active Directory realm settings
  606. In addition to the <<ref-realm-settings,settings that are valid for all realms>>,
  607. you can specify the following settings:
  608. `url`::
  609. (<<static-cluster-setting,Static>>)
  610. One or more LDAP URLs in the `ldap[s]://<server>:<port>` format. Defaults to
  611. `ldap://<domain_name>:389`. This setting is required when connecting using
  612. SSL/TLS or when using a custom port.
  613. +
  614. To provide multiple URLs, use a YAML array (`["ldap://server1:636", "ldap://server2:636"]`)
  615. or comma-separated string (`"ldap://server1:636, ldap://server2:636"`).
  616. +
  617. While both are supported, you can't mix the `ldap` and `ldaps` protocols.
  618. +
  619. If no URL is provided, {es} uses a default of `ldap://<domain_name>:389`. This
  620. default uses the `domain_name` setting value and assumes an unencrypted
  621. connection to port 389.
  622. `load_balance.type`::
  623. (<<static-cluster-setting,Static>>)
  624. The behavior to use when there are multiple LDAP URLs defined. For supported
  625. values see <<load-balancing,load balancing and failover types>>.
  626. Defaults to `failover`.
  627. `load_balance.cache_ttl`::
  628. (<<static-cluster-setting,Static>>)
  629. When using `dns_failover` or `dns_round_robin` as the load balancing type,
  630. this setting controls the amount of time to cache DNS lookups. Defaults
  631. to `1h`.
  632. `domain_name`::
  633. (<<static-cluster-setting,Static>>)
  634. The domain name of Active Directory. If the `url` and the `user_search.base_dn`
  635. settings are not specified, the cluster can derive those values from this
  636. setting. Required.
  637. `bind_dn`::
  638. (<<static-cluster-setting,Static>>)
  639. The DN of the user that is used to bind to Active Directory and perform searches.
  640. Defaults to Empty. Due to its potential security impact, `bind_dn` is not
  641. exposed via the <<cluster-nodes-info,nodes info API>>.
  642. `bind_password`::
  643. (<<static-cluster-setting,Static>>)
  644. deprecated[6.3] Use `secure_bind_password` instead. The password for the user
  645. that is used to bind to Active Directory. Defaults to Empty. Due to its
  646. potential security impact, `bind_password` is not exposed via the
  647. <<cluster-nodes-info,nodes info API>>.
  648. `secure_bind_password`::
  649. (<<secure-settings,Secure>>, <<reloadable-secure-settings,Reloadable>>)
  650. The password for the user that is used to bind to Active Directory.
  651. Defaults to Empty.
  652. `unmapped_groups_as_roles`::
  653. (<<static-cluster-setting,Static>>)
  654. If set to `true`, the names of any unmapped Active Directory groups are used as
  655. role names and assigned to the user. A group is considered _unmapped_ when it
  656. is not referenced in any role-mapping files. API-based role mappings are not
  657. considered. Defaults to `false`.
  658. `files.role_mapping`::
  659. (<<static-cluster-setting,Static>>)
  660. The <<security-files,location>> for the YAML
  661. role mapping configuration file. Defaults to `ES_PATH_CONF/role_mapping.yml`.
  662. `user_search.base_dn`::
  663. (<<static-cluster-setting,Static>>)
  664. The context to search for a user. Defaults to the root
  665. of the Active Directory domain.
  666. `user_search.scope`::
  667. (<<static-cluster-setting,Static>>)
  668. Specifies whether the user search should be `sub_tree`, `one_level` or `base`.
  669. `one_level` only searches users directly contained within the `base_dn`.
  670. `sub_tree` searches all objects contained under `base_dn`. `base`
  671. specifies that the `base_dn` is a user object, and that it is the
  672. only user considered. Defaults to `sub_tree`.
  673. `user_search.filter`::
  674. (<<static-cluster-setting,Static>>)
  675. Specifies a filter to use to lookup a user given a username. The default
  676. filter looks up `user` objects with either `sAMAccountName` or
  677. `userPrincipalName`. If specified, this must be a valid LDAP user search filter.
  678. For example `(&(objectClass=user)(sAMAccountName={0}))`. For more information,
  679. see
  680. https://msdn.microsoft.com/en-us/library/aa746475(v=vs.85).aspx[Search Filter Syntax].
  681. `user_search.upn_filter`::
  682. (<<static-cluster-setting,Static>>)
  683. Specifies a filter to use to lookup a user given a user principal name.
  684. The default filter looks up `user` objects with
  685. a matching `userPrincipalName`. If specified, this
  686. must be a valid LDAP user search filter. For example,
  687. `(&(objectClass=user)(userPrincipalName={1}))`. `{1}` is the full user principal name
  688. provided by the user. For more information, see
  689. https://msdn.microsoft.com/en-us/library/aa746475(v=vs.85).aspx[Search Filter Syntax].
  690. `user_search.down_level_filter`::
  691. (<<static-cluster-setting,Static>>)
  692. Specifies a filter to use to lookup a user given a down level logon name
  693. (DOMAIN\user). The default filter looks up `user` objects with a matching
  694. `sAMAccountName` in the domain provided. If specified, this
  695. must be a valid LDAP user search filter. For example,
  696. `(&(objectClass=user)(sAMAccountName={0}))`. For more information, see
  697. https://msdn.microsoft.com/en-us/library/aa746475(v=vs.85).aspx[Search Filter Syntax].
  698. `user_search.pool.enabled`::
  699. (<<static-cluster-setting,Static>>)
  700. Enables or disables connection pooling for user search. When
  701. disabled a new connection is created for every search. The
  702. default is `true` when `bind_dn` is provided.
  703. `user_search.pool.size`::
  704. (<<static-cluster-setting,Static>>)
  705. The maximum number of connections to the Active Directory server to allow in the
  706. connection pool. Defaults to `20`.
  707. `user_search.pool.initial_size`::
  708. (<<static-cluster-setting,Static>>)
  709. The initial number of connections to create to the Active Directory server on startup.
  710. Defaults to `0`. If the LDAP server is down, values greater than 0
  711. could cause startup failures.
  712. `user_search.pool.health_check.enabled`::
  713. (<<static-cluster-setting,Static>>)
  714. Enables or disables a health check on Active Directory connections in the connection
  715. pool. Connections are checked in the background at the specified interval.
  716. Defaults to `true`.
  717. `user_search.pool.health_check.dn`::
  718. (<<static-cluster-setting,Static>>)
  719. The distinguished name to be retrieved as part of the health check.
  720. Defaults to the value of `bind_dn` if that setting is present. Otherwise, it
  721. defaults to the value of the `user_search.base_dn` setting.
  722. `user_search.pool.health_check.interval`::
  723. (<<static-cluster-setting,Static>>)
  724. The interval to perform background checks of connections in the pool.
  725. Defaults to `60s`.
  726. `group_search.base_dn`::
  727. (<<static-cluster-setting,Static>>)
  728. The context to search for groups in which the user has membership. Defaults
  729. to the root of the Active Directory domain.
  730. `group_search.scope`::
  731. (<<static-cluster-setting,Static>>)
  732. Specifies whether the group search should be `sub_tree`, `one_level` or
  733. `base`. `one_level` searches for groups directly contained within the
  734. `base_dn`. `sub_tree` searches all objects contained under `base_dn`.
  735. `base` specifies that the `base_dn` is a group object, and that it is
  736. the only group considered. Defaults to `sub_tree`.
  737. `metadata`::
  738. (<<static-cluster-setting,Static>>)
  739. A list of additional LDAP attributes that should be loaded from the
  740. LDAP server and stored in the authenticated user's metadata field.
  741. `timeout.tcp_connect`::
  742. (<<static-cluster-setting,Static>>)
  743. The TCP connect timeout period for establishing an LDAP connection.
  744. An `s` at the end indicates seconds, or `ms` indicates milliseconds.
  745. Defaults to `5s` (5 seconds ).
  746. `timeout.tcp_read`::
  747. (<<static-cluster-setting,Static>>)
  748. deprecated[7.7] The TCP read timeout period after establishing an LDAP
  749. connection. This is equivalent to and is deprecated in favor of
  750. `timeout.response` and they cannot be used simultaneously. An `s` at the end
  751. indicates seconds, or `ms` indicates milliseconds. Defaults to the value of
  752. `timeout.ldap_search`.
  753. `timeout.response`::
  754. (<<static-cluster-setting,Static>>)
  755. The time interval to wait for the response from the AD server. An `s` at the
  756. end indicates seconds, or `ms` indicates milliseconds. Defaults to the value of
  757. `timeout.ldap_search`.
  758. `timeout.ldap_search`::
  759. (<<static-cluster-setting,Static>>)
  760. The timeout period for an LDAP search. The value is specified in the request
  761. and is enforced by the receiving LDAP Server.
  762. An `s` at the end indicates seconds, or `ms` indicates milliseconds.
  763. Defaults to `5s` (5 seconds ).
  764. `ssl.certificate`::
  765. (<<static-cluster-setting,Static>>)
  766. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate]
  767. +
  768. This certificate is presented to clients when they connect.
  769. `ssl.certificate_authorities`::
  770. (<<static-cluster-setting,Static>>)
  771. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate-authorities]
  772. +
  773. You cannot use this setting and `ssl.truststore.path` at the same time.
  774. `ssl.key`::
  775. (<<static-cluster-setting,Static>>)
  776. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-pem]
  777. +
  778. If the Active Directory server requires client authentication, it uses this file.
  779. You cannot use this setting and `ssl.keystore.path` at the same time.
  780. `ssl.key_passphrase`::
  781. (<<static-cluster-setting,Static>>)
  782. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-passphrase]
  783. `ssl.secure_key_passphrase`::
  784. (<<secure-settings,Secure>>)
  785. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-secure-key-passphrase]
  786. `ssl.keystore.key_password`::
  787. (<<static-cluster-setting,Static>>)
  788. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-key-password]
  789. `ssl.keystore.secure_key_password`::
  790. (<<secure-settings,Secure>>)
  791. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-key-password]
  792. `ssl.keystore.password`::
  793. (<<static-cluster-setting,Static>>)
  794. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-password]
  795. `ssl.secure_keystore.password`::
  796. (<<secure-settings,Secure>>)
  797. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-password]
  798. //TBD: Why/how is this different than `ssl.keystore.secure_password`?
  799. `ssl.keystore.path`::
  800. (<<static-cluster-setting,Static>>)
  801. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-path]
  802. +
  803. You cannot use this setting and `ssl.key` at the same time.
  804. `ssl.keystore.type`::
  805. (<<static-cluster-setting,Static>>)
  806. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-type-pkcs12]
  807. `ssl.truststore.password`::
  808. (<<static-cluster-setting,Static>>)
  809. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-password]
  810. `ssl.truststore.secure_password`::
  811. (<<secure-settings,Secure>>)
  812. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-secure-password]
  813. `ssl.truststore.path`::
  814. (<<static-cluster-setting,Static>>)
  815. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-path]
  816. +
  817. You cannot use this setting and `ssl.certificate_authorities` at the same time.
  818. `ssl.truststore.type`::
  819. (<<static-cluster-setting,Static>>)
  820. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-type]
  821. `ssl.verification_mode`::
  822. (<<static-cluster-setting,Static>>)
  823. Indicates the type of verification when using `ldaps` to protect against man
  824. in the middle attacks and certificate forgery.
  825. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-verification-mode-values]
  826. `ssl.supported_protocols`::
  827. (<<static-cluster-setting,Static>>)
  828. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-supported-protocols]
  829. `ssl.cipher_suites`::
  830. (<<static-cluster-setting,Static>>)
  831. Specifies the cipher suites that should be supported when
  832. communicating with the Active Directory server.
  833. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-cipher-suites-values]
  834. //TBD: Can this be updated to using the Java 11 URL instead or does it have to stay java8?
  835. `cache.ttl`::
  836. (<<static-cluster-setting,Static>>)
  837. Specifies the time-to-live for cached user entries. A user and a hash of its
  838. credentials are cached for this configured period of time. Use the
  839. standard Elasticsearch <<time-units,time units>>).
  840. Defaults to `20m`.
  841. `cache.max_users`::
  842. (<<static-cluster-setting,Static>>)
  843. Specifies the maximum number of user entries that the cache can contain.
  844. Defaults to `100000`.
  845. `cache.hash_algo`::
  846. (<<static-cluster-setting,Static>>, Expert)
  847. Specifies the hashing algorithm that is used for
  848. the in-memory cached user credentials. See <<cache-hash-algo>>. Defaults to `ssha256`.
  849. `authentication.enabled`::
  850. (<<static-cluster-setting,Static>>)
  851. If set to `false`, disables authentication support in
  852. this realm, so that it only supports user lookups.
  853. (See the <<run-as-privilege,run as>> and
  854. <<authorization_realms,authorization realms>> features).
  855. Defaults to `true`.
  856. `follow_referrals`::
  857. (<<static-cluster-setting,Static>>)
  858. If set to `true`, {es} follows referrals returned by the LDAP server.
  859. Referrals are URLs returned by the server that are to be used to continue the
  860. LDAP operation (such as `search`). Defaults to `true`.
  861. [[ref-pki-settings]]
  862. [discrete]
  863. ===== PKI realm settings
  864. In addition to the <<ref-realm-settings,settings that are valid for all realms>>, you can specify
  865. the following settings:
  866. `username_pattern`::
  867. (<<static-cluster-setting,Static>>)
  868. The regular expression pattern used to extract the username from the
  869. certificate DN. The username is used for auditing and logging. The username can also be used
  870. with the <<role-mapping-resources, role mapping API>> and <<configuring-authorization-delegation, authorization delegation>>.
  871. The first match group is the used as the username.
  872. Defaults to `CN=(.*?)(?:,|$)`.
  873. `certificate_authorities`::
  874. (<<static-cluster-setting,Static>>)
  875. List of paths to the PEM certificate files that should be used to authenticate a
  876. user's certificate as trusted. Defaults to the trusted certificates configured
  877. for SSL. This setting cannot be used with `truststore.path`.
  878. `truststore.algorithm`::
  879. (<<static-cluster-setting,Static>>)
  880. Algorithm for the truststore. Defaults to `SunX509`.
  881. `truststore.password`::
  882. (<<static-cluster-setting,Static>>)
  883. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-password]
  884. If `truststore.path` is set, this setting is required.
  885. `truststore.secure_password`::
  886. (<<secure-settings,Secure>>)
  887. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-secure-password]
  888. `truststore.path`::
  889. (<<static-cluster-setting,Static>>)
  890. The path of a truststore to use. Defaults to the trusted certificates configured
  891. for SSL. This setting cannot be used with `certificate_authorities`.
  892. `files.role_mapping`::
  893. (<<static-cluster-setting,Static>>)
  894. Specifies the <<security-files,location>> of the
  895. <<mapping-roles,YAML role mapping configuration file>>.
  896. Defaults to `ES_PATH_CONF/role_mapping.yml`.
  897. `authorization_realms`::
  898. (<<static-cluster-setting,Static>>)
  899. The names of the realms that should be consulted for delegated authorization.
  900. If this setting is used, then the PKI realm does not perform role mapping and
  901. instead loads the user from the listed realms.
  902. See <<authorization_realms>>.
  903. `cache.ttl`::
  904. (<<static-cluster-setting,Static>>)
  905. Specifies the time-to-live for cached user entries. A user and a hash of its
  906. credentials are cached for this period of time. Use the
  907. standard {es} <<time-units,time units>>).
  908. Defaults to `20m`.
  909. `cache.max_users`::
  910. (<<static-cluster-setting,Static>>)
  911. Specifies the maximum number of user entries that the cache can contain.
  912. Defaults to `100000`.
  913. `delegation.enabled`::
  914. (<<static-cluster-setting,Static>>)
  915. Generally, in order for the clients to be authenticated by the PKI realm they
  916. must connect directly to {es}. That is, they must not pass through proxies
  917. which terminate the TLS connection. In order to allow for a *trusted* and
  918. *smart* proxy, such as Kibana, to sit before {es} and terminate TLS
  919. connections, but still allow clients to be authenticated on {es} by this realm,
  920. you need to toggle this to `true`. Defaults to `false`. If delegation is
  921. enabled, then either `truststore.path` or `certificate_authorities` setting
  922. must be defined. For more details, see <<pki-realm-for-proxied-clients,
  923. Configuring authentication delegation for PKI realms>>.
  924. [[ref-saml-settings]]
  925. [discrete]
  926. ===== SAML realm settings
  927. // tag::saml-description-tag[]
  928. In addition to the <<ref-realm-settings,settings that are valid for all realms>>, you can specify
  929. the following settings.
  930. // end::saml-description-tag[]
  931. // tag::saml-idp-entity-id-tag[]
  932. `idp.entity_id` {ess-icon}::
  933. (<<static-cluster-setting,Static>>)
  934. The Entity ID of the SAML Identity Provider. An Entity ID is a URI with a
  935. maximum length of 1024 characters. It can be a URL (https://idp.example.com/) or
  936. a URN (`urn:example.com:idp`) and can be found in the configuration or the SAML
  937. metadata of the Identity Provider.
  938. // end::saml-idp-entity-id-tag[]
  939. // tag::saml-idp-metadata-path-tag[]
  940. `idp.metadata.path` {ess-icon}::
  941. (<<static-cluster-setting,Static>>)
  942. The path _(recommended)_ or URL to a SAML 2.0 metadata file describing the
  943. capabilities and configuration of the Identity Provider.
  944. If a path is provided, then it is resolved relative to the {es} config
  945. directory.
  946. If a URL is provided, then it must be either a `file` URL or a `https` URL.
  947. +
  948. {es} automatically polls this metadata resource and reloads
  949. the IdP configuration when changes are detected.
  950. File based resources are polled at a frequency determined by the global {es}
  951. `resource.reload.interval.high` setting, which defaults to 5 seconds.
  952. HTTPS resources are polled at a frequency determined by the realm's
  953. `idp.metadata.http.refresh` and `idp.metadata.http.minimum_refresh` settings.
  954. +
  955. If the metadata resource is loaded from a file then the file must exist at node
  956. startup, if it does not exist then the node will fail to start.
  957. If the resource is loaded over HTTPS then (by default) the node will be tolerant
  958. of a failure to load the resource - the node will start and will continue to
  959. poll the URL for updates. The affected SAML realm will fail to authenticate
  960. users until the problem is resolved. To force the node to fail if the metadata is
  961. unavailable set `idp.metadata.http.fail_on_error` to `true`.
  962. // end::saml-idp-metadata-path-tag[]
  963. // tag::saml-idp-metadata-http-refresh-tag[]
  964. `idp.metadata.http.fail_on_error`::
  965. (<<static-cluster-setting,Static>>)
  966. If set to `true`, the realm will fail on startup (and prevent the node from starting)
  967. if it attempts to load metadata over HTTPS and that metadata is not available.
  968. If set to `false` (the default), the node will start but the affected SAML realm will
  969. not support user authentication until the metadata can be successfully loaded.
  970. This setting is ignored if metadata is loaded from a file.
  971. // end::saml-idp-metadata-http-refresh-tag[]
  972. // tag::saml-idp-metadata-http-refresh-tag[]
  973. `idp.metadata.http.refresh` {ess-icon}::
  974. (<<static-cluster-setting,Static>>)
  975. Controls the frequency with which `https` metadata is checked for changes.
  976. Defaults to `1h` (1 hour).
  977. +
  978. Under some circumstances {es} may determine that the metadata needs to be checked
  979. more frequently. This may occur if previous attempts to load the metadata
  980. encountered an error, or if the metadata indicates that it is due to expire in
  981. less than the configured refresh interval. In these cases {es} will poll more
  982. often, but never more frequently than `idp.metadata.http.minimum_refresh`.
  983. If there is an attempt to authenticate against a realm that has not yet loaded
  984. metadata successfully, that realm may attempt to load metadata outside of the
  985. configured polling frequency.
  986. // end::saml-idp-metadata-http-refresh-tag[]
  987. // tag::saml-idp-metadata-http-minimum-refresh-tag[]
  988. `idp.metadata.http.minimum_refresh`::
  989. (<<static-cluster-setting,Static>>)
  990. Controls the minimum frequency with which `https` metadata is checked for
  991. changes. In regular operation {es} will use the value of
  992. `idp.metadata.http.refresh` as the polling interval. However, under some
  993. circumstances {es} may determine that it needs to poll more frequently.
  994. In these cases, the `minimum_refresh` will set the minimum frequency at which
  995. the metdata will be checked.
  996. Defaults to `5m` (5 minutes) and must not be set to a value greater than
  997. `idp.metadata.http.refresh`
  998. // end::saml-idp-metadata-http-minimum-refresh-tag[]
  999. // tag::saml-idp-use-single-logout-tag[]
  1000. `idp.use_single_logout` {ess-icon}::
  1001. (<<static-cluster-setting,Static>>)
  1002. Indicates whether to utilise the Identity Provider's Single Logout service
  1003. (if one exists in the IdP metadata file).
  1004. Defaults to `true`.
  1005. // end::saml-idp-use-single-logout-tag[]
  1006. // tag::saml-sp-entity-id-tag[]
  1007. `sp.entity_id` {ess-icon}::
  1008. (<<static-cluster-setting,Static>>)
  1009. The Entity ID to use for this SAML Service Provider. This should be entered as a
  1010. URI. We recommend that you use the base URL of your Kibana instance. For example,
  1011. `https://kibana.example.com/`.
  1012. // end::saml-sp-entity-id-tag[]
  1013. // tag::saml-sp-acs-tag[]
  1014. `sp.acs` {ess-icon}::
  1015. (<<static-cluster-setting,Static>>)
  1016. The URL of the Assertion Consumer Service within {kib}. Typically this is the
  1017. "api/security/saml/callback" endpoint of your Kibana server. For example,
  1018. `https://kibana.example.com/api/security/saml/callback`.
  1019. // end::saml-sp-acs-tag[]
  1020. // tag::saml-sp-logout-tag[]
  1021. `sp.logout` {ess-icon}::
  1022. (<<static-cluster-setting,Static>>)
  1023. The URL of the Single Logout service within {kib}. Typically this is the
  1024. "logout" endpoint of your Kibana server. For example,
  1025. `https://kibana.example.com/logout`.
  1026. // end::saml-sp-logout-tag[]
  1027. // tag::saml-attributes-principal-tag[]
  1028. `attributes.principal` {ess-icon}::
  1029. (<<static-cluster-setting,Static>>)
  1030. The Name of the SAML attribute that contains the user's principal (username).
  1031. // end::saml-attributes-principal-tag[]
  1032. // tag::saml-attributes-groups-tag[]
  1033. `attributes.groups` {ess-icon}::
  1034. (<<static-cluster-setting,Static>>)
  1035. The Name of the SAML attribute that contains the user's groups.
  1036. // end::saml-attributes-groups-tag[]
  1037. // tag::saml-attributes-name-tag[]
  1038. `attributes.name` {ess-icon}::
  1039. (<<static-cluster-setting,Static>>)
  1040. The Name of the SAML attribute that contains the user's full name.
  1041. // end::saml-attributes-name-tag[]
  1042. // tag::saml-attributes-mail-tag[]
  1043. `attributes.mail` {ess-icon}::
  1044. (<<static-cluster-setting,Static>>)
  1045. The Name of the SAML attribute that contains the user's email address.
  1046. // end::saml-attributes-mail-tag[]
  1047. // tag::saml-attributes-dn-tag[]
  1048. `attributes.dn` {ess-icon}::
  1049. (<<static-cluster-setting,Static>>)
  1050. The Name of the SAML attribute that contains the user's X.50
  1051. _Distinguished Name_.
  1052. // end::saml-attributes-dn-tag[]
  1053. // tag::saml-attributes-patterns-principal-tag[]
  1054. `attribute_patterns.principal` {ess-icon}::
  1055. (<<static-cluster-setting,Static>>)
  1056. A Java regular expression that is matched against the SAML attribute specified
  1057. by `attributes.principal` before it is applied to the user's _principal_ property.
  1058. The attribute value must match the pattern and the value of the first
  1059. _capturing group_ is used as the principal. For example, `^([^@]+)@example\\.com$`
  1060. matches email addresses from the "example.com" domain and uses the local-part as
  1061. the principal.
  1062. // end::saml-attributes-patterns-principal-tag[]
  1063. // tag::saml-attributes-patterns-groups-tag[]
  1064. `attribute_patterns.groups` {ess-icon}::
  1065. (<<static-cluster-setting,Static>>)
  1066. As per `attribute_patterns.principal`, but for the _group_ property.
  1067. // end::saml-attributes-patterns-groups-tag[]
  1068. // tag::saml-attributes-patterns-name-tag[]
  1069. `attribute_patterns.name` {ess-icon}::
  1070. (<<static-cluster-setting,Static>>)
  1071. As per `attribute_patterns.principal`, but for the _name_ property.
  1072. // end::saml-attributes-patterns-name-tag[]
  1073. // tag::saml-attributes-patterns-mail-tag[]
  1074. `attribute_patterns.mail` {ess-icon}::
  1075. (<<static-cluster-setting,Static>>)
  1076. As per `attribute_patterns.principal`, but for the _mail_ property.
  1077. // end::saml-attributes-patterns-mail-tag[]
  1078. // tag::saml-attributes-patterns-dn-tag[]
  1079. `attribute_patterns.dn` {ess-icon}::
  1080. (<<static-cluster-setting,Static>>)
  1081. As per `attribute_patterns.principal`, but for the _dn_ property.
  1082. // end::saml-attributes-patterns-dn-tag[]
  1083. // tag::saml-attributes-delimiters-groups-tag[]
  1084. `attribute_delimiters.groups` {ess-icon}::
  1085. (<<static-cluster-setting,Static>>)
  1086. A plain string that is used as a delimiter to split a single-valued SAML
  1087. attribute specified by `attributes.groups` before it is applied to the user's
  1088. _groups_ property. For example, splitting the SAML attribute value
  1089. `engineering,elasticsearch-admins,employees` on a delimiter value of `,` will
  1090. result in `engineering`, `elasticsearch-admins`, and `employees` as the list of
  1091. groups for the user. The delimiter will always be split on, regardless of
  1092. escaping in the input string. This setting does not support multi-valued SAML
  1093. attributes. It cannot be used together with the `attribute_patterns` setting.
  1094. You can only configure this setting for the groups attribute.
  1095. // end::saml-attributes-delimiters-groups-tag[]
  1096. // tag::saml-nameid-format-tag[]
  1097. `nameid_format` {ess-icon}::
  1098. (<<static-cluster-setting,Static>>)
  1099. The NameID format that should be requested when asking the IdP to authenticate
  1100. the current user. The default is to not include the `nameid_format` attribute.
  1101. // end::saml-nameid-format-tag[]
  1102. // tag::saml-nameid-allow-create-tag[]
  1103. `nameid.allow_create` {ess-icon}::
  1104. (<<static-cluster-setting,Static>>)
  1105. The value of the `AllowCreate` attribute of the
  1106. `NameIdPolicy` element in an authentication request. The default value is false.
  1107. // end::saml-nameid-allow-create-tag[]
  1108. // tag::saml-nameid-sp-qualifier-tag[]
  1109. `nameid.sp_qualifier` {ess-icon}::
  1110. (<<static-cluster-setting,Static>>)
  1111. The value of the `SPNameQualifier` attribute of the
  1112. `NameIdPolicy` element in an authentication request. The default is to not
  1113. include the `SPNameQualifier` attribute.
  1114. // end::saml-nameid-sp-qualifier-tag[]
  1115. // tag::saml-force-authn-tag[]
  1116. `force_authn` {ess-icon}::
  1117. (<<static-cluster-setting,Static>>)
  1118. Specifies whether to set the `ForceAuthn` attribute when requesting that the IdP
  1119. authenticate the current user. If set to `true`, the IdP is required to verify
  1120. the user’s identity, irrespective of any existing sessions they might have.
  1121. Defaults to `false`.
  1122. // end::saml-force-authn-tag[]
  1123. // tag::saml-populate-user-metadata-tag[]
  1124. `populate_user_metadata` {ess-icon}::
  1125. (<<static-cluster-setting,Static>>)
  1126. Specifies whether to populate the {es} user's metadata with the values that are
  1127. provided by the SAML attributes. Defaults to `true`.
  1128. // end::saml-populate-user-metadata-tag[]
  1129. `authorization_realms`::
  1130. (<<static-cluster-setting,Static>>)
  1131. The names of the realms that should be consulted for delegated authorization.
  1132. If this setting is used, then the SAML realm does not perform role mapping and
  1133. instead loads the user from the listed realms.
  1134. See <<authorization_realms>>.
  1135. // tag::saml-allowed-clock-skew-tag[]
  1136. `allowed_clock_skew` {ess-icon}::
  1137. (<<static-cluster-setting,Static>>)
  1138. The maximum amount of skew that can be tolerated between the IdP's clock and the
  1139. {es} node's clock.
  1140. Defaults to `3m` (3 minutes).
  1141. // end::saml-allowed-clock-skew-tag[]
  1142. // tag::saml-req-authn-context-tag[]
  1143. `req_authn_context_class_ref` {ess-icon}::
  1144. (<<static-cluster-setting,Static>>)
  1145. A comma separated list of Authentication Context Class Reference values to be
  1146. included in the Requested Authentication Context when requesting the IdP to
  1147. authenticate the current user. The Authentication Context of the corresponding
  1148. authentication response should contain at least one of the requested values.
  1149. +
  1150. For more information, see
  1151. <<req-authn-context>>.
  1152. // end::saml-req-authn-context-tag[]
  1153. [discrete]
  1154. [[ref-saml-signing-settings]]
  1155. ===== SAML realm signing settings
  1156. // tag::saml-signing-description-tag[]
  1157. If a signing key is configured (that is, either `signing.key` or
  1158. `signing.keystore.path` is set), then {es} signs outgoing SAML messages.
  1159. Signing can be configured using the following settings:
  1160. // end::saml-signing-description-tag[]
  1161. // tag::saml-signing-messages-tag[]
  1162. `signing.saml_messages` {ess-icon}::
  1163. (<<static-cluster-setting,Static>>)
  1164. A list of SAML message types that should be signed or `*` to sign all messages.
  1165. Each element in the list should be the local name of a SAML XML Element.
  1166. Supported element types are `AuthnRequest`, `LogoutRequest` and `LogoutResponse`.
  1167. Only valid if `signing.key` or `signing.keystore.path` is also specified.
  1168. Defaults to `*`.
  1169. // end::saml-signing-messages-tag[]
  1170. // tag::saml-signing-key-tag[]
  1171. `signing.key` {ess-icon}::
  1172. (<<static-cluster-setting,Static>>)
  1173. Specifies the path to the PEM encoded private key to use for SAML message signing.
  1174. `signing.key` and `signing.keystore.path` cannot be used at the same time.
  1175. // end::saml-signing-key-tag[]
  1176. `signing.secure_key_passphrase` {ess-icon}::
  1177. (<<secure-settings,Secure>>)
  1178. Specifies the passphrase to decrypt the PEM encoded private key (`signing.key`)
  1179. if it is encrypted.
  1180. // tag::saml-signing-certificate-tag[]
  1181. `signing.certificate` {ess-icon}::
  1182. (<<static-cluster-setting,Static>>)
  1183. Specifies the path to the PEM encoded certificate (or certificate chain) that
  1184. corresponds to the `signing.key`. This certificate must also be included in the
  1185. Service Provider metadata or manually configured within the IdP to allow for
  1186. signature validation. This setting can only be used if `signing.key` is set.
  1187. // end::saml-signing-certificate-tag[]
  1188. // tag::saml-signing-keystore-path-tag[]
  1189. `signing.keystore.path` {ess-icon}::
  1190. (<<static-cluster-setting,Static>>)
  1191. The path to the keystore that contains a private key and certificate. It must be
  1192. either a Java keystore (jks) or a PKCS#12 file. You cannot use this setting and
  1193. `signing.key` at the same time.
  1194. // end::saml-signing-keystore-path-tag[]
  1195. // tag::saml-signing-keystore-type-tag[]
  1196. `signing.keystore.type` {ess-icon}::
  1197. (<<static-cluster-setting,Static>>)
  1198. The type of the keystore in `signing.keystore.path`.
  1199. Must be either `jks` or `PKCS12`. If the keystore path ends in ".p12", ".pfx",
  1200. or "pkcs12", this setting defaults to `PKCS12`. Otherwise, it defaults to `jks`.
  1201. // end::saml-signing-keystore-type-tag[]
  1202. // tag::saml-signing-keystore-alias-tag[]
  1203. `signing.keystore.alias` {ess-icon}::
  1204. (<<static-cluster-setting,Static>>)
  1205. Specifies the alias of the key within the keystore that should be
  1206. used for SAML message signing. If the keystore contains more than one private
  1207. key, this setting must be specified.
  1208. // end::saml-signing-keystore-alias-tag[]
  1209. `signing.keystore.secure_password` {ess-icon}::
  1210. (<<secure-settings,Secure>>)
  1211. The password to the keystore in `signing.keystore.path`.
  1212. `signing.keystore.secure_key_password` {ess-icon}::
  1213. (<<secure-settings,Secure>>)
  1214. The password for the key in the keystore (`signing.keystore.path`).
  1215. Defaults to the keystore password.
  1216. [discrete]
  1217. [[ref-saml-encryption-settings]]
  1218. ===== SAML realm encryption settings
  1219. // tag::saml-encryption-description-tag[]
  1220. If an encryption key is configured (that is, either `encryption.key` or
  1221. `encryption.keystore.path` is set), then {es} publishes an encryption
  1222. certificate when generating metadata and attempts to decrypt incoming SAML
  1223. content. Encryption can be configured using the following settings:
  1224. // end::saml-encryption-description-tag[]
  1225. // tag::saml-encryption-key-tag[]
  1226. `encryption.key` {ess-icon}::
  1227. (<<static-cluster-setting,Static>>)
  1228. Specifies the path to the PEM encoded private key to use for SAML message
  1229. decryption.
  1230. `encryption.key` and `encryption.keystore.path` cannot be used at the same time.
  1231. // end::saml-encryption-key-tag[]
  1232. `encryption.secure_key_passphrase`::
  1233. (<<secure-settings,Secure>>)
  1234. Specifies the passphrase to decrypt the PEM encoded private key
  1235. (`encryption.key`) if it is encrypted.
  1236. // tag::saml-encryption-certificate-tag[]
  1237. `encryption.certificate` {ess-icon}::
  1238. (<<static-cluster-setting,Static>>)
  1239. Specifies the path to the PEM encoded certificate (or certificate chain) that is
  1240. associated with the `encryption.key`. This certificate must also be included in
  1241. the Service Provider metadata or manually configured within the IdP to enable
  1242. message encryption. This setting can be used only if `encryption.key` is set.
  1243. // end::saml-encryption-certificate-tag[]
  1244. // tag::saml-encryption-keystore-path-tag[]
  1245. `encryption.keystore.path` {ess-icon}::
  1246. (<<static-cluster-setting,Static>>)
  1247. The path to the keystore that contains a private key and certificate. It must be
  1248. either a Java keystore (jks) or a PKCS#12 file. You cannot use this setting and
  1249. `encryption.key` at the same time.
  1250. // end::saml-encryption-keystore-path-tag[]
  1251. // tag::saml-encryption-keystore-type-tag[]
  1252. `encryption.keystore.type` {ess-icon}::
  1253. (<<static-cluster-setting,Static>>)
  1254. The type of the keystore (`encryption.keystore.path`).
  1255. Must be either `jks` or `PKCS12`. If the keystore path ends in ".p12", ".pfx",
  1256. or "pkcs12", this setting defaults to `PKCS12`. Otherwise, it defaults to `jks`.
  1257. // end::saml-encryption-keystore-type-tag[]
  1258. // tag::saml-encryption-keystore-alias-tag[]
  1259. `encryption.keystore.alias` {ess-icon}::
  1260. (<<static-cluster-setting,Static>>)
  1261. Specifies the alias of the key within the keystore (`encryption.keystore.path`)
  1262. that should be used for SAML message decryption. If not specified, all compatible
  1263. key pairs from the keystore are considered as candidate keys for decryption.
  1264. // end::saml-encryption-keystore-alias-tag[]
  1265. `encryption.keystore.secure_password`::
  1266. (<<secure-settings,Secure>>)
  1267. The password to the keystore (`encryption.keystore.path`).
  1268. `encryption.keystore.secure_key_password`::
  1269. (<<secure-settings,Secure>>)
  1270. The password for the key in the keystore (`encryption.keystore.path`). Only a
  1271. single password is supported. If you are using multiple decryption keys,
  1272. they cannot have individual passwords.
  1273. [discrete]
  1274. [[ref-saml-ssl-settings]]
  1275. ===== SAML realm SSL settings
  1276. // tag::saml-ssl-description-tag[]
  1277. If you are loading the IdP metadata over SSL/TLS (that is, `idp.metadata.path`
  1278. is a URL using the `https` protocol), the following settings can be used to
  1279. configure SSL.
  1280. NOTE: These settings are not used for any purpose other than loading metadata
  1281. over https.
  1282. // end::saml-ssl-description-tag[]
  1283. // tag::saml-ssl-key-tag[]
  1284. `ssl.key` {ess-icon}::
  1285. (<<static-cluster-setting,Static>>)
  1286. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-pem]
  1287. // end::saml-ssl-key-tag[]
  1288. // tag::saml-ssl-key-passphrase-tag[]
  1289. `ssl.key_passphrase` {ess-icon}::
  1290. (<<static-cluster-setting,Static>>)
  1291. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-passphrase]
  1292. // end::saml-ssl-key-passphrase-tag[]
  1293. `ssl.secure_key_passphrase`::
  1294. (<<secure-settings,Secure>>)
  1295. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-secure-key-passphrase]
  1296. +
  1297. You cannot use this setting and `ssl.key_passphrase` at the same time.
  1298. // tag::saml-ssl-certificate-tag[]
  1299. `ssl.certificate` {ess-icon}::
  1300. (<<static-cluster-setting,Static>>)
  1301. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate]
  1302. // end::saml-ssl-certificate-tag[]
  1303. // tag::saml-ssl-certificate-authorities-tag[]
  1304. `ssl.certificate_authorities` {ess-icon}::
  1305. (<<static-cluster-setting,Static>>)
  1306. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate-authorities]
  1307. // end::saml-ssl-certificate-authorities-tag[]
  1308. // tag::saml-ssl-keystore-path-tag[]
  1309. `ssl.keystore.path` {ess-icon}::
  1310. (<<static-cluster-setting,Static>>)
  1311. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-path]
  1312. // end::saml-ssl-keystore-path-tag[]
  1313. // tag::saml-ssl-keystore-type[]
  1314. `ssl.keystore.type` {ess-icon}::
  1315. (<<static-cluster-setting,Static>>)
  1316. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-type-pkcs12]
  1317. // end::saml-ssl-keystore-type[]
  1318. // tag::saml-ssl-keystore-password-tag[]
  1319. `ssl.keystore.password` {ess-icon}::
  1320. (<<static-cluster-setting,Static>>)
  1321. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-password]
  1322. // end::saml-ssl-keystore-password-tag[]
  1323. `ssl.keystore.secure_password`::
  1324. (<<secure-settings,Secure>>)
  1325. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-password]
  1326. +
  1327. You cannot use this setting and `ssl.keystore.password` at the same time.
  1328. //TBD: Why is this different name than `ssl.secure_keystore.password` elsewhere in this file?
  1329. `ssl.keystore.key_password`::
  1330. (<<static-cluster-setting,Static>>)
  1331. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-key-password]
  1332. +
  1333. You cannot use this setting and `ssl.keystore.secure_key_password` at the same
  1334. time.
  1335. `ssl.keystore.secure_key_password`::
  1336. (<<secure-settings,Secure>>)
  1337. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-key-password]
  1338. You cannot use this setting and `ssl.keystore.key_password` at the same time.
  1339. // tag::saml-ssl-truststore-path-tag[]
  1340. `ssl.truststore.path` {ess-icon}::
  1341. (<<static-cluster-setting,Static>>)
  1342. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-path]
  1343. // end::saml-ssl-truststore-path-tag[]
  1344. // tag::saml-ssl-truststore-type-tag[]
  1345. `ssl.truststore.type` {ess-icon}::
  1346. (<<static-cluster-setting,Static>>)
  1347. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-type]
  1348. // end::saml-ssl-truststore-type-tag[]
  1349. // tag::saml-ssl-truststore-password-tag[]
  1350. `ssl.truststore.password` {ess-icon}::
  1351. (<<static-cluster-setting,Static>>)
  1352. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-password]
  1353. // end::saml-ssl-truststore-password-tag[]
  1354. `ssl.truststore.secure_password`::
  1355. (<<secure-settings,Secure>>)
  1356. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-secure-password]
  1357. +
  1358. This setting cannot be used with `ssl.truststore.password`.
  1359. // tag::saml-ssl-verification-mode-tag[]
  1360. `ssl.verification_mode` {ess-icon}::
  1361. (<<static-cluster-setting,Static>>)
  1362. Controls the verification of certificates.
  1363. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-verification-mode-values]
  1364. // end::saml-ssl-verification-mode-tag[]
  1365. // tag::saml-ssl-supported-prototols-tag[]
  1366. `ssl.supported_protocols` {ess-icon}::
  1367. (<<static-cluster-setting,Static>>)
  1368. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-supported-protocols]
  1369. // end::saml-ssl-supported-prototols-tag[]
  1370. // tag::saml-ssl-cipher-suites-tag[]
  1371. `ssl.cipher_suites` {ess-icon}::
  1372. (<<static-cluster-setting,Static>>)
  1373. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-cipher-suites-values]
  1374. // end::saml-ssl-cipher-suites-tag[]
  1375. [discrete]
  1376. [[ref-kerberos-settings]]
  1377. ===== Kerberos realm settings
  1378. // tag::kerberos-description-tag[]
  1379. In addition to the
  1380. <<ref-realm-settings,settings that are valid for all realms>>, you can specify
  1381. the following settings:
  1382. // end::kerberos-description-tag[]
  1383. // tag::kerberos-keytab-path-tag[]
  1384. `keytab.path` {ess-icon}::
  1385. (<<static-cluster-setting,Static>>)
  1386. Specifies the path to the Kerberos keytab file that contains the
  1387. service principal used by this {es} node. This must be a location within the
  1388. {es} configuration directory and the file must have read permissions. Required.
  1389. // end::kerberos-keytab-path-tag[]
  1390. // tag::kerberos-remove-realm-name-tag[]
  1391. `remove_realm_name` {ess-icon}::
  1392. (<<static-cluster-setting,Static>>)
  1393. Set to `true` to remove the realm part of principal names.
  1394. Principal names in Kerberos have the form `user/instance@REALM`. If this option
  1395. is `true`, the realm part (`@REALM`) will not be included in the username.
  1396. Defaults to `false`.
  1397. // end::kerberos-remove-realm-name-tag[]
  1398. `krb.debug`::
  1399. (<<static-cluster-setting,Static>>)
  1400. Set to `true` to enable debug logs for the Java login module that
  1401. provides support for Kerberos authentication. Defaults to `false`.
  1402. // tag::kerberos-cache-ttl-tag[]
  1403. `cache.ttl` {ess-icon}::
  1404. (<<static-cluster-setting,Static>>)
  1405. The time-to-live for cached user entries. A user is cached for
  1406. this period of time. Specify the time period using the standard {es}
  1407. <<time-units,time units>>. Defaults to `20m`.
  1408. // end::kerberos-cache-ttl-tag[]
  1409. // tag::kerberos-cache-max-users-tag[]
  1410. `cache.max_users` {ess-icon}::
  1411. (<<static-cluster-setting,Static>>)
  1412. The maximum number of user entries that can live in the
  1413. cache at any given time. Defaults to 100,000.
  1414. // end::kerberos-cache-max-users-tag[]
  1415. // tag::kerberos-authorization-realms-tag[]
  1416. `authorization_realms` {ess-icon}::
  1417. (<<static-cluster-setting,Static>>)
  1418. The names of the realms that should be consulted for delegated authorization.
  1419. If this setting is used, then the Kerberos realm does not perform role mapping and
  1420. instead loads the user from the listed realms.
  1421. See <<authorization_realms>>.
  1422. // end::kerberos-authorization-realms-tag[]
  1423. [[ref-oidc-settings]]
  1424. [discrete]
  1425. ===== OpenID Connect realm settings
  1426. // tag::oidc-description-tag[]
  1427. In addition to the <<ref-realm-settings,settings that are valid for all realms>>, you
  1428. can specify the following settings.
  1429. // end::oidc-description-tag[]
  1430. // tag::oidc-op-issuer-tag[]
  1431. `op.issuer` {ess-icon}::
  1432. (<<static-cluster-setting,Static>>)
  1433. A verifiable Identifier for your OpenID Connect Provider. An Issuer
  1434. Identifier is usually a case sensitive URL using the https scheme that contains
  1435. scheme, host, and optionally, port number and path components and no query or
  1436. fragment components. The value for this setting should be provided by your OpenID
  1437. Connect Provider.
  1438. // end::oidc-op-issuer-tag[]
  1439. // tag::oidc-op-auth-endpoint-tag[]
  1440. `op.authorization_endpoint` {ess-icon}::
  1441. (<<static-cluster-setting,Static>>)
  1442. The URL for the Authorization Endpoint at the
  1443. OpenID Connect Provider. The value for this setting should be provided by your OpenID
  1444. Connect Provider.
  1445. // end::oidc-op-auth-endpoint-tag[]
  1446. // tag::oidc-token-endpoint-tag[]
  1447. `op.token_endpoint` {ess-icon}::
  1448. (<<static-cluster-setting,Static>>)
  1449. The URL for the Token Endpoint at the OpenID Connect Provider.
  1450. The value for this setting should be provided by your OpenID Connect Provider.
  1451. // end::oidc-token-endpoint-tag[]
  1452. // tag::oidc-userinfo-endpoint-tag[]
  1453. `op.userinfo_endpoint` {ess-icon}::
  1454. (<<static-cluster-setting,Static>>)
  1455. The URL for the User Info Endpoint at the OpenID Connect Provider.
  1456. The value for this setting should be provided by your OpenID Connect Provider.
  1457. // end::oidc-userinfo-endpoint-tag[]
  1458. // tag::oidc-endsession-endpoint-tag[]
  1459. `op.endsession_endpoint` {ess-icon}::
  1460. (<<static-cluster-setting,Static>>)
  1461. The URL for the End Session Endpoint at the OpenID Connect
  1462. Provider. The value for this setting should be provided by your OpenID Connect Provider.
  1463. // end::oidc-endsession-endpoint-tag[]
  1464. // tag::oidc-op-jwkset-path-tag[]
  1465. `op.jwkset_path` {ess-icon}::
  1466. (<<static-cluster-setting,Static>>)
  1467. The file name or URL to a JSON Web Key Set (JWKS) with the public key material used to verify
  1468. tokens and claims responses signed by the OpenID Connect Provider. A value is considered a file name
  1469. if it does not begin with `https` or `http`. The file name
  1470. is resolved relative to the {es} configuration directory. Changes to the file are polled
  1471. at a frequency determined by the global {es} `resource.reload.interval.high`
  1472. setting, which defaults to 5 seconds.
  1473. +
  1474. If a URL is provided, then it must begin with `https://` or `http://`.
  1475. {es} automatically caches the retrieved JWK and will attempt to refresh the JWK upon signature verification
  1476. failure, as this might indicate that the OpenID Connect Provider has
  1477. rotated the signing keys.
  1478. // end::oidc-op-jwkset-path-tag[]
  1479. `authorization_realms`::
  1480. (<<static-cluster-setting,Static>>)
  1481. The names of the realms that should be consulted for delegated authorization.
  1482. If this setting is used, then the OpenID Connect realm does not perform role
  1483. mapping and instead loads the user from the listed realms.
  1484. See <<authorization_realms>>.
  1485. // tag::rp-client-id-tag[]
  1486. `rp.client_id` {ess-icon}::
  1487. (<<static-cluster-setting,Static>>)
  1488. The OAuth 2.0 Client Identifier that was assigned to {es} during registration
  1489. at the OpenID Connect Provider.
  1490. // end::rp-client-id-tag[]
  1491. `rp.client_secret`::
  1492. (<<secure-settings,Secure>>)
  1493. The OAuth 2.0 Client Secret that was assigned to {es} during registration
  1494. at the OpenID Connect Provider.
  1495. // tag::rp-client-auth-method-tag[]
  1496. `rp.client_auth_method` {ess-icon}::
  1497. (<<static-cluster-setting, Static>>)
  1498. The client authentication method used by {es} to authenticate
  1499. to the OpenID Connect Provider. Can be `client_secret_basic`, `client_secret_post`,
  1500. or `client_secret_jwt`. Defaults to `client_secret_basic`.
  1501. // end::rp-client-auth-method-tag[]
  1502. // tag::rp-client-auth-jwt-signature-algorithm[]
  1503. `rp.client_auth_jwt_signature_algorithm` {ess-icon}::
  1504. (<<static-cluster-setting, Static>>)
  1505. The signature algorithm that {es} uses to sign the JWT with which it authenticates
  1506. as a client to the OpenID Connect Provider when `client_secret_jwt` is selected for
  1507. `rp.client_auth_method`. Can be either `HS256`, `HS384`, or `HS512`. Defaults to
  1508. `HS384`.
  1509. // end::rp-client-auth-jwt-signature-algorithm[]
  1510. // tag::rp-redirect-uri-tag[]
  1511. `rp.redirect_uri` {ess-icon}::
  1512. (<<static-cluster-setting,Static>>)
  1513. The Redirect URI within {kib}. If you want to use the authorization code flow, this is the
  1514. `api/security/oidc/callback` endpoint of your {kib} server. If you want to use the implicit flow, it is the `api/security/oidc/implicit` endpoint.
  1515. For example, `https://kibana.example.com/api/security/oidc/callback`.
  1516. // end::rp-redirect-uri-tag[]
  1517. // tag::rp-response-type-tag[]
  1518. `rp.response_type` {ess-icon}::
  1519. (<<static-cluster-setting,Static>>)
  1520. OAuth 2.0 Response Type value that determines the authorization
  1521. processing flow to be used. Can be `code` for authorization code grant flow,
  1522. or one of `id_token`, `id_token token` for the implicit flow.
  1523. // end::rp-response-type-tag[]
  1524. // tag::rp-signature-algorithm-tag[]
  1525. `rp.signature_algorithm` {ess-icon}::
  1526. (<<static-cluster-setting,Static>>)
  1527. The signature algorithm that will be used by {es} in order to verify the
  1528. signature of the id tokens it will receive from the OpenID Connect Provider.
  1529. Allowed values are `HS256`, `HS384`, `HS512`, `ES256`, `ES384`, `ES512`,
  1530. `RS256`, `RS384`, `RS512`, `PS256`, `PS384`, `PS512`.
  1531. Defaults to `RS256`.
  1532. // end::rp-signature-algorithm-tag[]
  1533. // tag::rp-requested-scopes-tag[]
  1534. `rp.requested_scopes` {ess-icon}::
  1535. (<<static-cluster-setting,Static>>)
  1536. The scope values that will be requested by the OpenID Connect Provider as
  1537. part of the Authentication Request. Optional, defaults to `openid`
  1538. // end::rp-requested-scopes-tag[]
  1539. // tag::rp-post-logout-redirect-url-tag[]
  1540. `rp.post_logout_redirect_uri` {ess-icon}::
  1541. (<<static-cluster-setting,Static>>)
  1542. The Redirect URI (usually within {kib}) that the OpenID Connect Provider
  1543. should redirect the browser to after a successful Single Logout.
  1544. // end::rp-post-logout-redirect-url-tag[]
  1545. // tag::oidc-claims-principal-tag[]
  1546. `claims.principal`::
  1547. (<<static-cluster-setting,Static>>)
  1548. The name of the OpenID Connect claim that contains the user's principal (username).
  1549. // end::oidc-claims-principal-tag[]
  1550. // tag::oidc-claims-groups-tag[]
  1551. `claims.groups` {ess-icon}::
  1552. (<<static-cluster-setting,Static>>)
  1553. The name of the OpenID Connect claim that contains the user's groups.
  1554. // end::oidc-claims-groups-tag[]
  1555. // tag::oidc-claims-mail-tag[]
  1556. `claims.name` {ess-icon}::
  1557. (<<static-cluster-setting,Static>>)
  1558. The name of the OpenID Connect claim that contains the user's full name.
  1559. // end::oidc-claims-mail-tag[]
  1560. // tag::oidc-claims-mail-tag[]
  1561. `claims.mail` {ess-icon}::
  1562. (<<static-cluster-setting,Static>>)
  1563. The name of the OpenID Connect claim that contains the user's email address.
  1564. // end::oidc-claims-mail-tag[]
  1565. // tag::oidc-claims-dn-tag[]
  1566. `claims.dn` {ess-icon}::
  1567. (<<static-cluster-setting,Static>>)
  1568. The name of the OpenID Connect claim that contains the user's X.509
  1569. _Distinguished Name_.
  1570. // end::oidc-claims-dn-tag[]
  1571. // tag::oidc-claim-pattern-principal-tag[]
  1572. `claim_patterns.principal` {ess-icon}::
  1573. (<<static-cluster-setting,Static>>)
  1574. A Java regular expression that is matched against the OpenID Connect claim specified
  1575. by `claims.principal` before it is applied to the user's _principal_ property.
  1576. The attribute value must match the pattern and the value of the first
  1577. _capturing group_ is used as the principal. For example, `^([^@]+)@example\\.com$`
  1578. matches email addresses from the "example.com" domain and uses the local-part as
  1579. the principal.
  1580. // end::oidc-claim-pattern-principal-tag[]
  1581. // tag::oidc-claim-pattern-groups-tag[]
  1582. `claim_patterns.groups` {ess-icon}::
  1583. (<<static-cluster-setting,Static>>)
  1584. As per `claim_patterns.principal`, but for the _group_ property.
  1585. // end::oidc-claim-pattern-groups-tag[]
  1586. // tag::oidc-claim-pattern-name-tag[]
  1587. `claim_patterns.name` {ess-icon}::
  1588. (<<static-cluster-setting,Static>>)
  1589. As per `claim_patterns.principal`, but for the _name_ property.
  1590. // end::oidc-claim-pattern-name-tag[]
  1591. // tag::oidc-claim-pattern-mail-tag[]
  1592. `claim_patterns.mail` {ess-icon}::
  1593. (<<static-cluster-setting,Static>>)
  1594. As per `claim_patterns.principal`, but for the _mail_ property.
  1595. // end::oidc-claim-pattern-mail-tag[]
  1596. // tag::oidc-claim-pattern-dn-tag[]
  1597. `claim_patterns.dn` {ess-icon}::
  1598. (<<static-cluster-setting,Static>>)
  1599. As per `claim_patterns.principal`, but for the _dn_ property.
  1600. // end::oidc-claim-pattern-dn-tag[]
  1601. // tag::oidc-allowed-clock-skew-tag[]
  1602. `allowed_clock_skew` {ess-icon}::
  1603. (<<static-cluster-setting,Static>>)
  1604. The maximum allowed clock skew to be taken into consideration when validating
  1605. id tokens with regards to their creation and expiration times.
  1606. Defaults to `60s`.
  1607. // end::oidc-allowed-clock-skew-tag[]
  1608. // tag::oidc-populate-user-metadata-tag[]
  1609. `populate_user_metadata` {ess-icon}::
  1610. (<<static-cluster-setting,Static>>)
  1611. Specifies whether to populate the {es} user's metadata with the values that are
  1612. provided by the OpenID Connect claims. Defaults to `true`.
  1613. // end::oidc-populate-user-metadata-tag[]
  1614. `http.proxy.host`::
  1615. (<<static-cluster-setting,Static>>)
  1616. Specifies the address of the proxy server that will be used by the internal
  1617. http client for all back-channel communication to the OpenID Connect Provider
  1618. endpoints. This includes requests to the Token Endpoint, the Userinfo Endpoint
  1619. and requests to fetch the JSON Web Key Set from the OP if `op.jwkset_path` is
  1620. set as a URL.
  1621. `http.proxy.scheme`::
  1622. (<<static-cluster-setting,Static>>)
  1623. Specifies the protocol to use to connect to the proxy server that will be
  1624. used by the http client for all back-channel communication to the OpenID
  1625. Connect Provider endpoints. Defaults to `http`. Allowed values are
  1626. `http` or `https`.
  1627. `http.proxy.port`::
  1628. (<<static-cluster-setting,Static>>)
  1629. Specifies the port of the proxy server that will be used by the http
  1630. client for all backchannel communication to the OpenID Connect Provider
  1631. endpoints. Defaults to `80`.
  1632. // tag::oidc-http-connect-timeout-tag[]
  1633. `http.connect_timeout` {ess-icon}::
  1634. (<<static-cluster-setting,Static>>)
  1635. Controls the behavior of the http client used for back-channel communication to
  1636. the OpenID Connect Provider endpoints. Specifies the timeout until a connection
  1637. is established. A value of zero means the timeout is not used. Defaults to `5s`.
  1638. // end::oidc-http-connect-timeout-tag[]
  1639. // tag::oidc-http-read-timeout-tag[]
  1640. `http.connection_read_timeout` {ess-icon}::
  1641. (<<static-cluster-setting,Static>>)
  1642. Controls the behavior of the http client used for back-channel communication to
  1643. the OpenID Connect Provider endpoints. Specifies the timeout used when
  1644. requesting a connection from the connection manager. Defaults to `5s`
  1645. // end::oidc-http-read-timeout-tag[]
  1646. // tag::oidc-http-socket-timeout[]
  1647. `http.socket_timeout` {ess-icon}::
  1648. (<<static-cluster-setting,Static>>)
  1649. Controls the behavior of the http client used for back-channel communication to
  1650. the OpenID Connect Provider endpoints. Specifies the socket timeout (SO_TIMEOUT)
  1651. in milliseconds, which is the timeout for waiting for data or, put differently,
  1652. a maximum period inactivity between two consecutive data packets). Defaults to
  1653. `5s`.
  1654. // end::oidc-http-socket-timeout[]
  1655. // tag::oidc-http-max-connections-tag[]
  1656. `http.max_connections` {ess-icon}::
  1657. (<<static-cluster-setting,Static>>)
  1658. Controls the behavior of the http client used for back-channel communication to
  1659. the OpenID Connect Provider endpoints. Specifies the maximum number of
  1660. connections allowed across all endpoints.
  1661. Defaults to `200`.
  1662. // end::oidc-http-max-connections-tag[]
  1663. // tag::oidc-http-max-endpoint-connections-tag[]
  1664. `http.max_endpoint_connections` {ess-icon}::
  1665. (<<static-cluster-setting,Static>>)
  1666. Controls the behavior of the http client used for back-channel communication to
  1667. the OpenID Connect Provider endpoints. Specifies the maximum number of
  1668. connections allowed per endpoint.
  1669. Defaults to `200`.
  1670. // end::oidc-http-max-endpoint-connections-tag[]
  1671. // tag::oidc-http-tcp-keepalive-tag[]
  1672. `http.tcp.keep_alive` {ess-icon}::
  1673. (<<static-cluster-setting,Static>>)
  1674. Whether to enable TCP keepalives on HTTP connections used for back-channel communication
  1675. to the OpenID Connect Provider endpoints. Defaults to `true`.
  1676. // end::oidc-http-tcp-keepalive-tag[]
  1677. // tag::oidc-http-connection-pool-ttl-tag[]
  1678. `http.connection_pool_ttl` {ess-icon}::
  1679. (<<static-cluster-setting,Static>>)
  1680. Controls the behavior of the http client used for back-channel communication to
  1681. the OpenID Connect Provider endpoints. Specifies the time-to-live of connections
  1682. in the connection pool (default to 3 minutes). A connection is closed if it is
  1683. idle for more than the specified timeout.
  1684. The server can also set the `Keep-Alive` HTTP response header. The effective
  1685. time-to-live value is the smaller value between this setting and the `Keep-Alive`
  1686. response header. Configure this setting to `-1` to let the server dictate the value.
  1687. If the header is not set by the server and the setting has value of `-1`,
  1688. the time-to-live is infinite and connections never expire.
  1689. // end::oidc-http-connection-pool-ttl-tag[]
  1690. [discrete]
  1691. [[ref-oidc-ssl-settings]]
  1692. ===== OpenID Connect realm SSL settings
  1693. // tag::oidc-ssl-description-tag[]
  1694. The following settings can be used to configure SSL for all outgoing http connections
  1695. to the OpenID Connect Provider endpoints.
  1696. NOTE: These settings are _only_ used for the back-channel communication between
  1697. {es} and the OpenID Connect Provider
  1698. // end::oidc-ssl-description-tag[]
  1699. // tag::oidc-ssl-key-tag[]
  1700. `ssl.key` {ess-icon}::
  1701. (<<static-cluster-setting,Static>>)
  1702. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-pem]
  1703. // end::oidc-ssl-key-tag[]
  1704. // tag::oidc-ssl-key-passphrase-tag[]
  1705. `ssl.key_passphrase` {ess-icon}::
  1706. (<<static-cluster-setting,Static>>)
  1707. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-passphrase]
  1708. // end::oidc-ssl-key-passphrase-tag[]
  1709. `ssl.secure_key_passphrase`::
  1710. (<<secure-settings,Secure>>)
  1711. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-secure-key-passphrase]
  1712. +
  1713. You cannot use this setting and `ssl.key_passphrase` at the same time.
  1714. // tag::oidc-ssl-certificate-tag[]
  1715. `ssl.certificate` {ess-icon}::
  1716. (<<static-cluster-setting,Static>>)
  1717. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate]
  1718. // end::oidc-ssl-certificate-tag[]
  1719. // tag::oidc-ssl-certificate-authorities-tag[]
  1720. `ssl.certificate_authorities` {ess-icon}::
  1721. (<<static-cluster-setting,Static>>)
  1722. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate-authorities]
  1723. // end::oidc-ssl-certificate-authorities-tag[]
  1724. // tag::oidc-ssl-keystore-path-tag[]
  1725. `ssl.keystore.path` {ess-icon}::
  1726. (<<static-cluster-setting,Static>>)
  1727. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-path]
  1728. // end::oidc-ssl-keystore-path-tag[]
  1729. // tag::oidc-ssl-keystore-type-tag[]
  1730. `ssl.keystore.type` {ess-icon}::
  1731. (<<static-cluster-setting,Static>>)
  1732. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-type-pkcs12]
  1733. // end::oidc-ssl-keystore-type-tag[]
  1734. // tag::oidc-ssl-keystore-password-tag[]
  1735. `ssl.keystore.password` {ess-icon}::
  1736. (<<static-cluster-setting,Static>>)
  1737. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-password]
  1738. // end::oidc-ssl-keystore-password-tag[]
  1739. `ssl.keystore.secure_password`::
  1740. (<<secure-settings,Secure>>)
  1741. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-password]
  1742. +
  1743. You cannot use this setting and `ssl.keystore.password` at the same time.
  1744. `ssl.keystore.key_password`::
  1745. (<<static-cluster-setting,Static>>)
  1746. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-key-password]
  1747. +
  1748. You cannot use this setting and `ssl.keystore.secure_key_password` at the same
  1749. time.
  1750. `ssl.keystore.secure_key_password`::
  1751. (<<secure-settings,Secure>>)
  1752. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-key-password]
  1753. +
  1754. You cannot use this setting and `ssl.keystore.key_password` at the same time.
  1755. // tag::oidc-ssl-truststore-path-tag[]
  1756. `ssl.truststore.path` {ess-icon}::
  1757. (<<static-cluster-setting,Static>>)
  1758. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-path]
  1759. // end::oidc-ssl-truststore-path-tag[]
  1760. // tag::oidc-ssl-truststore-type-tag[]
  1761. `ssl.truststore.type` {ess-icon}::
  1762. (<<static-cluster-setting,Static>>)
  1763. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-type]
  1764. // end::oidc-ssl-truststore-type-tag[]
  1765. // tag::oidc-ssl-truststore-password-tag[]
  1766. `ssl.truststore.password` {ess-icon}::
  1767. (<<static-cluster-setting,Static>>)
  1768. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-password]
  1769. // end::oidc-ssl-truststore-password-tag[]
  1770. `ssl.truststore.secure_password`::
  1771. (<<secure-settings,Secure>>)
  1772. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-secure-password]
  1773. +
  1774. You cannot use this setting and `ssl.truststore.password` at the same time.
  1775. // tag::oidc-ssl-verification-mode-tag[]
  1776. `ssl.verification_mode` {ess-icon}::
  1777. (<<static-cluster-setting,Static>>)
  1778. Controls the verification of certificates.
  1779. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-verification-mode-values]
  1780. // end::oidc-ssl-verification-mode-tag[]
  1781. // tag::oidc-ssl-supported-protocols-tag[]
  1782. `ssl.supported_protocols` {ess-icon}::
  1783. (<<static-cluster-setting,Static>>)
  1784. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-supported-protocols]
  1785. // end::oidc-ssl-supported-protocols-tag[]
  1786. // tag::oidc-ssl-cipher-suites-tag[]
  1787. `ssl.cipher_suites` {ess-icon}::
  1788. (<<static-cluster-setting,Static>>)
  1789. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-cipher-suites-values]
  1790. // end::oidc-ssl-cipher-suites-tag[]
  1791. [[ref-jwt-settings]]
  1792. [discrete]
  1793. ===== JWT realm settings
  1794. // tag::jwt-description-tag[]
  1795. In addition to the <<ref-realm-settings,settings that are valid for all realms>>, you
  1796. can specify the following settings.
  1797. // end::jwt-description-tag[]
  1798. // tag::jwt-token-type-tag[]
  1799. `token_type` {ess-icon}::
  1800. (<<static-cluster-setting,Static>>)
  1801. The token type, `id_token` or `access_token`, that the JWT realm uses to verify
  1802. incoming JWTs. Defaults to `id_token`.
  1803. // end::jwt-token-type-tag[]
  1804. // tag::jwt-allowed-audiences-tag[]
  1805. `allowed_audiences` {ess-icon}::
  1806. (<<static-cluster-setting,Static>>)
  1807. A list of allowed JWT audiences that {es} should verify. {es} will only consume
  1808. JWTs that were intended for any of these audiences, as denoted by the `aud`
  1809. claim in the JWT).
  1810. The audiences are compared with exact string matches and do not support wildcards or regex.
  1811. Examples of `aud` claim are `https://example.com/client1`
  1812. and `other_service,elasticsearch`. When `token_type` is `access_token`, the audiences can
  1813. be optionally denoted by a different claim in the JWT if `aud` does not exist.
  1814. See also <<security-settings-jwt-fallback-claims-aud,`fallback_claims.aud`>>.
  1815. // end::jwt-allowed-audiences-tag[]
  1816. // tag::jwt-allowed-clock-skew-tag[]
  1817. `allowed_clock_skew` {ess-icon}::
  1818. (<<static-cluster-setting,Static>>)
  1819. The maximum allowed clock skew to be taken into consideration when validating
  1820. JWTs with regards to their creation, not before, and expiration times.
  1821. // end::jwt-allowed-clock-skew-tag[]
  1822. // tag::jwt-allowed-issuer-tag[]
  1823. `allowed_issuer` {ess-icon}::
  1824. (<<static-cluster-setting,Static>>)
  1825. A verifiable Identifier for your JWT Issuer. An Issuer
  1826. Identifier is usually a case sensitive URL using the https scheme that contains
  1827. scheme, host, and optionally, port number and path components and no query or
  1828. fragment components. However, it can be any string. The value for this setting
  1829. should be provided by your JWT Issuer.
  1830. The issuer is compared with exact string matches and do not support wildcards or regex.
  1831. Examples of `iss` claim are `https://example.com:8443/jwt` and `issuer123`.
  1832. // end::jwt-allowed-issuer-tag[]
  1833. // tag::jwt-allowed-subjects-tag[]
  1834. `allowed_subjects` {ess-icon}::
  1835. (<<static-cluster-setting,Static>>)
  1836. A list of allowed JWT subjects that {es} should verify. {es} will only consume
  1837. JWTs that were issued for any of these subjects, as denoted by the `sub`
  1838. claim in the JWT.
  1839. The subjects are compared with exact string matches and do not support wildcards or regex.
  1840. Examples of `sub` claim are `https://example.com/user1`
  1841. and `user_1,user2`.
  1842. When `token_type` is `access_token`, this setting is mandatory and the subject can be
  1843. optionally denoted by a different claim in the JWT if `sub` does not exist.
  1844. See also <<security-settings-jwt-fallback-claims-sub,`fallback_claims.sub`>>.
  1845. // end::jwt-allowed-subjects-tag[]
  1846. // tag::jwt-fallback-claims-sub-tag[]
  1847. [[security-settings-jwt-fallback-claims-sub]]
  1848. `fallback_claims.sub` {ess-icon}::
  1849. (<<static-cluster-setting,Static>>)
  1850. The alternative claim to look for the subject information if the `sub` claim
  1851. does not exist. It is configurable only when the `token_type` is `access_token`.
  1852. The fallback is applied everywhere the `sub` claim is used.
  1853. // end::jwt-fallback-claims-sub-tag[]
  1854. // tag::jwt-fallback-claims-aud-tag[]
  1855. [[security-settings-jwt-fallback-claims-aud]]
  1856. `fallback_claims.aud` {ess-icon}::
  1857. (<<static-cluster-setting,Static>>)
  1858. The alternative claim to look for the audiences information if the `aud` claim
  1859. does not exist. It is configurable only when the `token_type` is `access_token`.
  1860. The fallback is applied everywhere the `aud` claim is used.
  1861. // end::jwt-fallback-claims-aud-tag[]
  1862. // tag::jwt-required-claims-tag[]
  1863. `required_claims` {ess-icon}::
  1864. (<<static-cluster-setting,Static>>)
  1865. Additional claims and associated values that {es} should verify.
  1866. This is a group setting that takes key/value pairs, where the key is a string
  1867. and the value must be either a string or an array of strings.
  1868. The values are compared with exact string matches and do not support wildcards or regex.
  1869. For example:
  1870. [source, yaml]
  1871. ------------------------------------------------------------
  1872. xpack.security.authc.realms.jwt.jwt1:
  1873. required_claims:
  1874. token_use: "id"
  1875. versions: ["1.0", "2.0"]
  1876. ------------------------------------------------------------
  1877. // end::jwt-required-claims-tag[]
  1878. // tag::jwt-allowed-signature-algorithms-tag[]
  1879. `allowed_signature_algorithms` {ess-icon}::
  1880. (<<static-cluster-setting,Static>>)
  1881. A list of signature algorithms that will be used by {es} in order to verify the
  1882. signature of the JWT it will receive from the JWT Issuer.
  1883. Defaults to `RS256`. Examples are `HS512,RS512,ES512` and `ES384`.
  1884. Allowed values are `HS256`, `HS384`, `HS512`, `ES256`, `ES384`, `ES512`,
  1885. `RS256`, `RS384`, `RS512`, `PS256`, `PS384`, `PS512`.
  1886. // end::jwt-allowed-signature-algorithms-tag[]
  1887. `authorization_realms`::
  1888. (<<static-cluster-setting,Static>>)
  1889. The names of the realms that should be consulted for delegated authorization.
  1890. If this setting is used, then the JWT realm does not perform role
  1891. mapping and instead loads the user from the listed realms.
  1892. See <<authorization_realms>>.
  1893. // tag::jwt-claims-dn-tag[]
  1894. `claims.dn` {ess-icon}::
  1895. (<<static-cluster-setting,Static>>)
  1896. The name of the JWT claim that contains the user's Distinguished Name (DN),
  1897. which uniquely identifies a user or group.
  1898. // end::jwt-claims-dn-tag[]
  1899. // tag::jwt-claims-pattern-dn-tag[]
  1900. `claim_patterns.dn` {ess-icon}::
  1901. (<<static-cluster-setting,Static>>)
  1902. Accepts the same Java regular expression as
  1903. <<jwt-claim-pattern-principal,`claim_patterns.principal`>>, but for the `dn`
  1904. property.
  1905. // end::jwt-claims-pattern-dn-tag[]
  1906. // tag::jwt-claims-groups-tag[]
  1907. `claims.groups` {ess-icon}::
  1908. (<<static-cluster-setting,Static>>)
  1909. The name of the JWT claim that contains the user's groups, such as `groups` and
  1910. `roles`.
  1911. // end::jwt-claims-groups-tag[]
  1912. // tag::jwt-claim-pattern-groups-tag[]
  1913. `claim_patterns.group` {ess-icon}::
  1914. (<<static-cluster-setting,Static>>)
  1915. Accepts the same Java regular expression as
  1916. <<jwt-claim-pattern-principal,`claim_patterns.principal`>>, but for the `group`
  1917. property.
  1918. // end::jwt-claim-pattern-groups-tag[]
  1919. // tag::jwt-claims-mail-tag[]
  1920. `claims.mail` {ess-icon}::
  1921. (<<static-cluster-setting,Static>>)
  1922. The name of the JWT claim that contains the user's e-mail address.
  1923. // end::jwt-claims-mail-tag[]
  1924. // tag::jwt-claims-pattern-mail-tag[]
  1925. `claim_patterns.mail` {ess-icon}::
  1926. (<<static-cluster-setting,Static>>)
  1927. Accepts the same Java regular expression as
  1928. <<jwt-claim-pattern-principal,`claim_patterns.principal`>>, but for the `mail`
  1929. property.
  1930. // end::jwt-claims-pattern-mail-tag[]
  1931. // tag::jwt-claims-name-tag[]
  1932. `claims.name` {ess-icon}::
  1933. (<<static-cluster-setting,Static>>)
  1934. The name of the JWT claim that contains the user's username.
  1935. // end::jwt-claims-name-tag[]
  1936. // tag::jwt-claims-pattern-name-tag[]
  1937. `claim_patterns.name` {ess-icon}::
  1938. (<<static-cluster-setting,Static>>)
  1939. Accepts the same Java regular expression as
  1940. <<jwt-claim-pattern-principal,`claim_patterns.principal`>>, but for the `name`
  1941. property.
  1942. // end::jwt-claims-pattern-name-tag[]
  1943. // tag::jwt-claims-principal-tag[]
  1944. `claims.principal`::
  1945. (<<static-cluster-setting,Static>>)
  1946. The name of the JWT claim that contains the user's principal (username), such as
  1947. `sub`, `name`, `email`, and `dn`.
  1948. // end::jwt-claims-principal-tag[]
  1949. [[jwt-claim-pattern-principal]]
  1950. // tag::jwt-claim-pattern-principal-tag[]
  1951. `claim_patterns.principal` {ess-icon}::
  1952. (<<static-cluster-setting,Static>>)
  1953. An optional Java regular expression that is matched against the JWT claim specified
  1954. by `claims.principal` before it is applied to the user's `principal` property.
  1955. The value must match the pattern and the value of the first
  1956. _capturing group_ is used as the principal. For example, `^([^@]+)@example\\.com$`
  1957. matches email addresses from the `example.com` domain and uses the local-part as
  1958. the principal. Another example is `sub` which may not need a pattern setting.
  1959. // end::jwt-claim-pattern-principal-tag[]
  1960. // tag::jwt-client-authentication-type-tag[]
  1961. `client_authentication.type` {ess-icon}::
  1962. (<<static-cluster-setting,Static>>)
  1963. Specifies whether to use `shared_secret` or `none` to authenticate
  1964. incoming client requests. If this value is `shared_secret`, the client is
  1965. authenticated using an HTTP request header that must match a pre-configured
  1966. secret value. The client must provide this shared secret with every request in
  1967. the `ES-Client-Authentication` header. If this value is `none`, then the
  1968. request header `ES-Client-Authentication` is ignored. Defaults to
  1969. `shared_secret`.
  1970. +
  1971. Enabling client authentication is recommended. If JWT bearer
  1972. tokens are shared with other clients or services, client authentication
  1973. restricts which ones are allowed to submit those JWTs to {es}.
  1974. // end::jwt-client-authentication-type-tag[]
  1975. // tag::jwt-client-authentication-shared-secret-tag[]
  1976. `client_authentication.shared_secret` {ess-icon}::
  1977. (<<secure-settings,Secure>>, <<reloadable-secure-settings,reloadable>>)
  1978. Secret value string for client authentication.
  1979. Required if `client_authentication.type` is `shared_secret`.
  1980. // end::jwt-client-authentication-shared-secret-tag[]
  1981. // tag::jwt-client-authentication-rotation-grace-period-tag[]
  1982. `client_authentication.rotation_grace_period`::
  1983. (<<static-cluster-setting,Static>>)
  1984. Sets the grace period for how long after rotating the `client_authentication.shared_secret`
  1985. is valid. `client_authentication.shared_secret` can be rotated by updating the
  1986. keystore then calling the <<cluster-nodes-reload-secure-settings, reload API>>.
  1987. Defaults to `1m`.
  1988. // end::jwt-client-authentication-rotation-grace-period-tag[]
  1989. // tag::jwt-http-connect-timeout-tag[]
  1990. `http.connect_timeout` {ess-icon}::
  1991. (<<static-cluster-setting,Static>>)
  1992. Sets the timeout for the HTTP client that is used for fetching the JSON Web Key
  1993. Set from a remote URL. A value of zero means the timeout is not used. Defaults
  1994. to `5s`.
  1995. // end::jwt-http-connect-timeout-tag[]
  1996. // tag::jwt-http-read-timeout-tag[]
  1997. `http.connection_read_timeout` {ess-icon}::
  1998. (<<static-cluster-setting,Static>>)
  1999. Specifies the HTTP timeout used when requesting a connection from the connection
  2000. manager. Defaults to `5s`.
  2001. // end::jwt-http-read-timeout-tag[]
  2002. // tag::jwt-http-socket-timeout[]
  2003. `http.socket_timeout` {ess-icon}::
  2004. (<<static-cluster-setting,Static>>)
  2005. Specifies the maximum socket timeout (SO_TIMEOUT) for the HTTP client to wait
  2006. for inactivity between two consecutive data packets. Defaults to `5s`.
  2007. // end::jwt-http-socket-timeout[]
  2008. // tag::jwt-http-max-connections-tag[]
  2009. `http.max_connections` {ess-icon}::
  2010. (<<static-cluster-setting,Static>>)
  2011. Specifies the maximum number of connections allowed across all endpoints.
  2012. // end::jwt-http-max-connections-tag[]
  2013. // tag::jwt-http-max-endpoint-connections-tag[]
  2014. `http.max_endpoint_connections` {ess-icon}::
  2015. (<<static-cluster-setting,Static>>)
  2016. Specifies the maximum number of connections allowed per endpoint.
  2017. // end::jwt-http-max-endpoint-connections-tag[]
  2018. `jwt.cache.size`::
  2019. (<<static-cluster-setting,Static>>)
  2020. Specifies the maximum number of JWT cache entries. If clients use a different
  2021. JWT for every request, set to `0` to disable the JWT cache. Defaults to `100000`.
  2022. `jwt.cache.ttl`::
  2023. (<<static-cluster-setting,Static>>)
  2024. Specifies the time-to-live for the period of time to cache JWT entries.
  2025. JWTs can only be cached if client authentication is successful (or disabled).
  2026. Uses the standard {es} <<time-units,time units>>. If clients use a different JWT
  2027. for every request, set to `0` to disable the JWT cache. Defaults to `20m`.
  2028. // tag::jwt-pkc-jwkset-path-tag[]
  2029. `pkc_jwkset_path` {ess-icon}::
  2030. (<<static-cluster-setting,Static>>)
  2031. The file name or URL to a JSON Web Key Set (JWKS) with the public key material that
  2032. the JWT Realm uses for verifying token signatures. A value is considered a file name
  2033. if it does not begin with `https`. The file name
  2034. is resolved relative to the {es} configuration directory. If a URL is provided, then
  2035. it must begin with `https://` (`http://` is not supported).
  2036. {es} automatically caches the JWK set and will attempt to refresh the
  2037. JWK set upon signature verification failure, as this might indicate that the JWT Provider has
  2038. rotated the signing keys.
  2039. // end::jwt-pkc-jwkset-path-tag[]
  2040. // tag::jwt-hmac-jwkset-tag[]
  2041. `hmac_jwkset` {ess-icon}::
  2042. (<<secure-settings,Secure>>)
  2043. Contents of a JSON Web Key Set (JWKS), including the secret key that the JWT
  2044. realm uses to verify token signatures. This format supports multiple keys and
  2045. optional attributes, and is preferred over the `hmac_key` setting. Cannot be
  2046. used in conjunction with the `hmac_key` setting. Refer to
  2047. <<jwt-auth-realm,Configure {es} to use a JWT realm>>.
  2048. // end::jwt-hmac-jwkset-tag[]
  2049. // tag::jwt-hmac-key-tag[]
  2050. `hmac_key` {ess-icon}::
  2051. (<<secure-settings,Secure>>)
  2052. Contents of a single JSON Web Key (JWK), including the secret key that the JWT
  2053. realm uses to verify token signatures. This format only supports a single key
  2054. without attributes, and cannot be used with the `hmac_jwkset` setting. This
  2055. format is compatible with OIDC. The HMAC key must be a UNICODE string, where
  2056. the key bytes are the UTF-8 encoding of the UNICODE string.
  2057. The `hmac_jwkset` setting is preferred. Refer to
  2058. <<jwt-auth-realm,Configure {es} to use a JWT realm>>.
  2059. // end::jwt-hmac-key-tag[]
  2060. // tag::jwt-populate-user-metadata-tag[]
  2061. `populate_user_metadata` {ess-icon}::
  2062. (<<static-cluster-setting,Static>>)
  2063. Specifies whether to populate the {es} user's metadata with the values that are
  2064. provided by the JWT claims. Defaults to `true`.
  2065. // end::jwt-populate-user-metadata-tag[]
  2066. [discrete]
  2067. [[ref-jwt-ssl-settings]]
  2068. ===== JWT realm SSL settings
  2069. // tag::jwt-ssl-description-tag[]
  2070. The following settings can be used to configure SSL for fetching the JSON Web
  2071. Key Set from a remote URL.
  2072. NOTE: These settings are _only_ used for the back-channel communication between
  2073. {es} and the JWT Issuer.
  2074. // end::jwt-ssl-description-tag[]
  2075. // tag::jwt-ssl-key-tag[]
  2076. `ssl.key` {ess-icon}::
  2077. (<<static-cluster-setting,Static>>)
  2078. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-pem]
  2079. // end::jwt-ssl-key-tag[]
  2080. // tag::jwt-ssl-key-passphrase-tag[]
  2081. `ssl.key_passphrase` {ess-icon}::
  2082. (<<static-cluster-setting,Static>>)
  2083. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-key-passphrase]
  2084. // end::jwt-ssl-key-passphrase-tag[]
  2085. `ssl.secure_key_passphrase`::
  2086. (<<secure-settings,Secure>>)
  2087. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-secure-key-passphrase]
  2088. +
  2089. You cannot use this setting and `ssl.key_passphrase` at the same time.
  2090. // tag::jwt-ssl-certificate-tag[]
  2091. `ssl.certificate` {ess-icon}::
  2092. (<<static-cluster-setting,Static>>)
  2093. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate]
  2094. // end::jwt-ssl-certificate-tag[]
  2095. // tag::jwt-ssl-certificate-authorities-tag[]
  2096. `ssl.certificate_authorities` {ess-icon}::
  2097. (<<static-cluster-setting,Static>>)
  2098. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-certificate-authorities]
  2099. // end::jwt-ssl-certificate-authorities-tag[]
  2100. // tag::jwt-ssl-keystore-path-tag[]
  2101. `ssl.keystore.path` {ess-icon}::
  2102. (<<static-cluster-setting,Static>>)
  2103. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-path]
  2104. // end::jwt-ssl-keystore-path-tag[]
  2105. // tag::jwt-ssl-keystore-type-tag[]
  2106. `ssl.keystore.type` {ess-icon}::
  2107. (<<static-cluster-setting,Static>>)
  2108. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-type-pkcs12]
  2109. // end::jwt-ssl-keystore-type-tag[]
  2110. // tag::jwt-ssl-keystore-password-tag[]
  2111. `ssl.keystore.password` {ess-icon}::
  2112. (<<static-cluster-setting,Static>>)
  2113. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-password]
  2114. // end::jwt-ssl-keystore-password-tag[]
  2115. `ssl.keystore.secure_password`::
  2116. (<<secure-settings,Secure>>)
  2117. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-password]
  2118. +
  2119. You cannot use this setting and `ssl.keystore.password` at the same time.
  2120. `ssl.keystore.key_password`::
  2121. (<<static-cluster-setting,Static>>)
  2122. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-key-password]
  2123. +
  2124. You cannot use this setting and `ssl.keystore.secure_key_password` at the same
  2125. time.
  2126. `ssl.keystore.secure_key_password`::
  2127. (<<secure-settings,Secure>>)
  2128. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-keystore-secure-key-password]
  2129. +
  2130. You cannot use this setting and `ssl.keystore.key_password` at the same time.
  2131. // tag::jwt-ssl-truststore-path-tag[]
  2132. `ssl.truststore.path` {ess-icon}::
  2133. (<<static-cluster-setting,Static>>)
  2134. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-path]
  2135. // end::jwt-ssl-truststore-path-tag[]
  2136. // tag::jwt-ssl-truststore-type-tag[]
  2137. `ssl.truststore.type` {ess-icon}::
  2138. (<<static-cluster-setting,Static>>)
  2139. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-type]
  2140. // end::jwt-ssl-truststore-type-tag[]
  2141. // tag::jwt-ssl-truststore-password-tag[]
  2142. `ssl.truststore.password` {ess-icon}::
  2143. (<<static-cluster-setting,Static>>)
  2144. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-password]
  2145. // end::jwt-ssl-truststore-password-tag[]
  2146. `ssl.truststore.secure_password`::
  2147. (<<secure-settings,Secure>>)
  2148. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-truststore-secure-password]
  2149. +
  2150. You cannot use this setting and `ssl.truststore.password` at the same time.
  2151. // tag::jwt-ssl-verification-mode-tag[]
  2152. `ssl.verification_mode` {ess-icon}::
  2153. (<<static-cluster-setting,Static>>)
  2154. Controls the verification of certificates.
  2155. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-verification-mode-values]
  2156. // end::jwt-ssl-verification-mode-tag[]
  2157. // tag::jwt-ssl-supported-protocols-tag[]
  2158. `ssl.supported_protocols` {ess-icon}::
  2159. (<<static-cluster-setting,Static>>)
  2160. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-supported-protocols]
  2161. // end::jwt-ssl-supported-protocols-tag[]
  2162. // tag::jwt-ssl-cipher-suites-tag[]
  2163. `ssl.cipher_suites` {ess-icon}::
  2164. (<<static-cluster-setting,Static>>)
  2165. include::{es-ref-dir}/settings/common-defs.asciidoc[tag=ssl-cipher-suites-values]
  2166. // end::jwt-ssl-cipher-suites-tag[]
  2167. [discrete]
  2168. [[load-balancing]]
  2169. ===== Load balancing and failover
  2170. The <<static-cluster-setting,static>> `load_balance.type` setting can have the
  2171. following values:
  2172. * `failover`: The URLs specified are used in the order that they are specified.
  2173. The first server that can be connected to will be used for all subsequent
  2174. connections. If a connection to that server fails then the next server that a
  2175. connection can be established to will be used for subsequent connections.
  2176. * `dns_failover`: In this mode of operation, only a single URL may be specified.
  2177. This URL must contain a DNS name. The system will be queried for all IP
  2178. addresses that correspond to this DNS name. Connections to the Active Directory
  2179. or LDAP server will always be tried in the order in which they were retrieved.
  2180. This differs from `failover` in that there is no reordering of the list and if a
  2181. server has failed at the beginning of the list, it will still be tried for each
  2182. subsequent connection.
  2183. * `round_robin`: Connections will continuously iterate through the list of
  2184. provided URLs. If a server is unavailable, iterating through the list of URLs
  2185. will continue until a successful connection is made.
  2186. * `dns_round_robin`: In this mode of operation, only a single URL may be
  2187. specified. This URL must contain a DNS name. The system will be queried for all
  2188. IP addresses that correspond to this DNS name. Connections will continuously
  2189. iterate through the list of addresses. If a server is unavailable, iterating
  2190. through the list of URLs will continue until a successful connection is made.
  2191. [discrete]
  2192. [[ssl-tls-settings]]
  2193. ==== General TLS settings
  2194. `xpack.security.ssl.diagnose.trust`::
  2195. (<<static-cluster-setting,Static>>)
  2196. Controls whether to output diagnostic messages for SSL/TLS trust failures.
  2197. If this is `true` (the default), a message will be printed to the Elasticsearch
  2198. log whenever an SSL connection (incoming or outgoing) is rejected due to a failure
  2199. to establish trust.
  2200. This diagnostic message contains information that can be used to determine the
  2201. cause of the failure and assist with resolving the problem.
  2202. Set to `false` to disable these messages.
  2203. [discrete]
  2204. [[tls-ssl-key-settings]]
  2205. ===== TLS/SSL key and trusted certificate settings
  2206. The following settings are used to specify a private key, certificate, and the
  2207. trusted certificates that should be used when communicating over an SSL/TLS
  2208. connection. If no trusted certificates are configured, the default certificates
  2209. that are trusted by the JVM will be trusted along with the certificate(s)
  2210. associated with a key in the same context. The key and certificate must be in
  2211. place for connections that require client authentication or when acting as a
  2212. SSL enabled server.
  2213. [[pkcs12-truststore-note]]
  2214. [NOTE]
  2215. Storing trusted certificates in a PKCS#12 file, although supported, is
  2216. uncommon in practice. The <<certutil,`elasticsearch-certutil` tool>>,
  2217. as well as Java's `keytool`, are designed to generate PKCS#12 files that
  2218. can be used both as a keystore and as a truststore, but this may not be the
  2219. case for container files that are created using other tools. Usually,
  2220. PKCS#12 files only contain secret and private entries. To confirm that
  2221. a PKCS#12 container includes trusted certificate ("anchor") entries look for
  2222. `2.16.840.1.113894.746875.1.1: <Unsupported tag 6>` in the
  2223. `openssl pkcs12 -info` output, or `trustedCertEntry` in the
  2224. `keytool -list` output.
  2225. [[http-tls-ssl-settings]]
  2226. :ssl-prefix: xpack.security.http
  2227. :component: HTTP
  2228. :client-auth-default: none
  2229. :verifies!:
  2230. :server:
  2231. :ssl-context: security-http
  2232. :ssl-layer: HTTP networking layer, which {es} uses to communicate with other clients
  2233. include::ssl-settings.asciidoc[]
  2234. [[transport-tls-ssl-settings]]
  2235. :ssl-prefix: xpack.security.transport
  2236. :component: Transport
  2237. :client-auth-default!:
  2238. :verifies:
  2239. :server:
  2240. :ssl-context: security-transport
  2241. :ssl-layer: transport networking layer, which nodes use to communicate with each other
  2242. include::ssl-settings.asciidoc[]
  2243. [[remote-cluster-server-tls-ssl-settings]]
  2244. :ssl-prefix: xpack.security.remote_cluster_server
  2245. :component: Remote cluster server (API key based model)
  2246. :enabled-by-default:
  2247. :client-auth-default: none
  2248. :verifies!:
  2249. :server:
  2250. :secure-pass:
  2251. :ssl-context: security-remote-cluster-server
  2252. :ssl-layer: remote cluster server networking layer, which {es} uses to communicate with remote cluster clients
  2253. include::ssl-settings.asciidoc[]
  2254. [[remote-cluster-client-tls-ssl-settings]]
  2255. :ssl-prefix: xpack.security.remote_cluster_client
  2256. :component: Remote cluster client (API key based model)
  2257. :enabled-by-default:
  2258. :client-auth-default: none
  2259. :verifies:
  2260. :server!:
  2261. :secure-pass:
  2262. :ssl-context: security-remote-cluster-client
  2263. :ssl-layer: remote cluster client networking layer, which {es} uses to communicate with remote cluster servers
  2264. include::ssl-settings.asciidoc[]
  2265. [[ssl-tls-profile-settings]]
  2266. [discrete]
  2267. ===== Transport profile TLS/SSL settings
  2268. The same settings that are available for the <<transport-tls-ssl-settings, default transport>>
  2269. are also available for each transport profile. By default, the settings for a
  2270. transport profile will be the same as the default transport unless they
  2271. are specified.
  2272. As an example, lets look at the key setting. For the default transport
  2273. this is `xpack.security.transport.ssl.key`. In order to use this setting in a
  2274. transport profile, use the prefix `transport.profiles.$PROFILE.xpack.security.` and
  2275. append the portion of the setting after `xpack.security.transport.`. For the key
  2276. setting, this would be `transport.profiles.$PROFILE.xpack.security.ssl.key`.
  2277. [discrete]
  2278. [[ip-filtering-settings]]
  2279. === IP filtering settings
  2280. You can configure the following settings for <<ip-filtering,IP filtering>>.
  2281. `xpack.security.transport.filter.allow`::
  2282. (<<dynamic-cluster-setting,Dynamic>>)
  2283. List of IP addresses to allow.
  2284. `xpack.security.transport.filter.deny`::
  2285. (<<dynamic-cluster-setting,Dynamic>>)
  2286. List of IP addresses to deny.
  2287. `xpack.security.http.filter.allow`::
  2288. (<<dynamic-cluster-setting,Dynamic>>)
  2289. List of IP addresses to allow just for HTTP.
  2290. `xpack.security.http.filter.deny`::
  2291. (<<dynamic-cluster-setting,Dynamic>>)
  2292. List of IP addresses to deny just for HTTP.
  2293. `transport.profiles.$PROFILE.xpack.security.filter.allow`::
  2294. (<<dynamic-cluster-setting,Dynamic>>)
  2295. List of IP addresses to allow for this profile.
  2296. `transport.profiles.$PROFILE.xpack.security.filter.deny`::
  2297. (<<dynamic-cluster-setting,Dynamic>>)
  2298. List of IP addresses to deny for this profile.
  2299. `xpack.security.remote_cluster.filter.allow`::
  2300. (<<dynamic-cluster-setting,Dynamic>>)
  2301. List of IP addresses to allow just for the
  2302. <<remote-clusters-api-key,remote cluster server configured with the API key based model>>.
  2303. `xpack.security.remote_cluster.filter.deny`::
  2304. (<<dynamic-cluster-setting,Dynamic>>)
  2305. List of IP addresses to deny just for the remote cluster server configured with
  2306. the <<remote-clusters-api-key,API key based model>>.
  2307. include::security-hash-settings.asciidoc[]