Support for FIPS compliance mode#14912
Support for FIPS compliance mode#14912beanuwave wants to merge 26 commits intoopensearch-project:mainfrom
Conversation
|
❌ Gradle check result for 6016d5d: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
8e8ed47 to
6016d5d
Compare
|
❌ Gradle check result for 8e8ed47: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
❌ Gradle check result for 6016d5d: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
.../identity-shiro/src/main/java/org/opensearch/identity/shiro/realm/BCryptPasswordMatcher.java
Show resolved
Hide resolved
|
Could use some help maybe from @cwperks or @peternied reviewing this, please. |
buildSrc/src/main/java/org/opensearch/gradle/testclusters/OpenSearchNode.java
Outdated
Show resolved
Hide resolved
|
❌ Gradle check result for 1da3c64: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
Signed-off-by: Igonin <iigonin@sternad.de> Co-authored-by: Benny Goerzig <benny.goerzig@sap.com> Co-authored-by: Karsten Schnitter <k.schnitter@sap.com> Co-authored-by: Kai Sternad <k.sternad@sternad.de> # Conflicts: # release-notes/opensearch.release-notes-3.0.0-alpha1.md
Signed-off-by: Igonin <iigonin@sternad.de> Co-authored-by: Benny Goerzig <benny.goerzig@sap.com> Co-authored-by: Karsten Schnitter <k.schnitter@sap.com> Co-authored-by: Kai Sternad <k.sternad@sternad.de>
Signed-off-by: Igonin <iigonin@sternad.de> Co-authored-by: Benny Goerzig <benny.goerzig@sap.com> Co-authored-by: Karsten Schnitter <k.schnitter@sap.com> Co-authored-by: Kai Sternad <k.sternad@sternad.de>
|
❌ Gradle check result for 9a88327: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
Hi @beanuwave , |
|
❌ Gradle check result for 9a88327: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
I want to echo @prakashsatpathy #14912 (comment) above. What are the challenges and how can those of us interested in this help? |
Thanks for offereing your support @aaronmcohen. This PR has been abandoned in favor of a sequence of smaller, more manageable PRs. For the time being it remains open just as a refererence. We are in the final stages of another PR that fixes various FIPS related tests. After that, one more PR which is already developed and part of this original PR will follow. Then OS core should be FIPS compliant. |
|
@kaimst I updated the description and converted this to draft to hopefully avoid confusion in the future. Let me or any other maintainer know if/when it should be closed. |
@reta @terryquigleysas We've now had a few minor distributions where all BC jars have swapped to using BCFIPS versions of the jars. Due to the optionality built in, the lib/ folder does not contain BCFIPS jars in the vanilla distribution, but does include the BCFIPS jars when building with I'd like to revisit this because its causing problems when the jars are included in the Can we include the BCFIPS jars in the |
Yes, I think there is a good case for shipping these in the lib dir now as the chance of introducing a breaking change has lessened, if not gone away altogether. For example, it is only the FIPS variants of the BC libs that are on the standard distribution now ./plugins/opensearch-security/bcpkix-fips-2.1.9.jar @beanuwave is also now seeing the jar hell that ensues as he brings them into the libs dir for the work he is doing, and then uses any of the plugins listed above. Having them only in the lib dir should also reduce the size of the distros a bit and would be preferable to the work involved in making a FIPS-only distro or asking customers to make manual changes. |
IIRC the major concern was that any third-party plugin relying on non-FIPS BC libs would cause a breaking change. @cwperks @reta @terryquigleysas |
Speaking for the plugins in the default distribution, it was possible to swap the BC jars to BCFIPS jars so 3P plugins would also have the option to make a similar swap if they are affected. I know its a pain to write code that has to check if a class is available at runtime and then use reflection to instantiate/call methods etc so advantage of having it in the lib is to have it globally available. |
|
Every split-up PR that originated from this one has been merged, so keeping this PR in draft has served its purpose. However, that doesn’t mean we’re finished - the FIPS work is still ongoing, just in other areas. Shoutout to everyone who has participated so far and helped keep the progress going. Thank you! |
This PR has been abandoned in favor of a sequence of smaller, more manageable PRs. For the time being it remains open just as a refererence. See this comment for details.
Description
This PR makes FIPS mode available through the
OPENSEARCH_CRYPTO_STANDARD=FIPS-140-3environmental parameter instead of thetests.fips.enabledsetting. It provides FIPS 140-3 support by replacing all BC dependencies with BCFIPS dependencies and making FIPS approved-only mode configurable at launch. Running this mode restricts the BCFIPS provider to rely solely on FIPS-certified ciphers.fips.gradlebuild script is removed in order to support a single-build solution.java.securityfile is added to the build to distinguish between FIPS and non-FIPS environments.fips_java.securityfile is altered due to evolving security standards.security.policyfile is altered to grant necessary security permissions.Runtime limitations (known so far) that come with enabling FIPS mode:
Admins can continue to manage their systems without being impacted by this change. However, for those keen on FIPS compliance, the most common obstacle will likely be the requirement to set a stronger password for the internal keystore and also convert key and truststores to *.bcfks format.
ssl.verification_mode=NONEsetting is not permitted.Reasons for refactoring
PemUtils, which is used by the Reindex API in cases of migrating data from a remote cluster that is TLS protected:Related Issues
opensearch-project/security#3420
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.