Skip to content

Commit

Permalink
doc
Browse files Browse the repository at this point in the history
  • Loading branch information
jakelandis committed Dec 20, 2023
1 parent a462217 commit 0c40e5e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions docs/reference/settings/security-settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,11 @@ the sensitive nature of the information.
(<<static-cluster-setting,Static>>)
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`.

`xpack.security.fips_mode.required_providers`::
(<<static-cluster-setting,Static>>)
Optionally enforce specific Java JCE/JSSE security providers. For example set this to `["BCFIPS"]` to require the Bouncy Castle FIPS
security provider. Only applicable when `xpack.security.fips_mode.enabled` is set to `true`.

[discrete]
[[password-hashing-settings]]
==== Password hashing settings
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1573,15 +1573,15 @@ static void validateForFips(Settings settings) {
}

final List<String> requiredProviders = XPackSettings.FIPS_REQUIRED_PROVIDERS.get(settings);
logger.info("JVM Security Providers " + foundProviders);
logger.info("JVM Security Providers: " + foundProviders);
if (requiredProviders != null && requiredProviders.isEmpty() == false) {
List<String> unsatisfiedProviders = requiredProviders.stream()
.map(s -> s.toLowerCase(Locale.ROOT))
.filter(element -> foundProviders.contains(element) == false)
.toList();

if (unsatisfiedProviders.isEmpty() == false) {
String errorMessage = "Could not find required FIPS security provider " + unsatisfiedProviders;
String errorMessage = "Could not find required FIPS security provider: " + unsatisfiedProviders;
logger.error(errorMessage);
validationErrors.add(errorMessage);
}
Expand Down

0 comments on commit 0c40e5e

Please sign in to comment.