File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -28,10 +28,20 @@ _enable_fips_if_required() {
2828 if [[ -n " ${UBUNTU_PRO_TOKEN} " && ${KERNEL_VERSION} =~ " fips" ]]; then
2929 echo " Ubuntu Pro token and FIPS kernel detected"
3030 apt-get -qq install --no-install-recommends ubuntu-advantage-tools > /dev/null
31+
32+ # This workaround is needed in Ubuntu 24.04 as OpenSSL attempts to leverage the FIPS provider
33+ # when the underlying kernel is FIPS enabled.
34+ export OPENSSL_FORCE_FIPS_MODE=0
35+
3136 echo " Attaching Ubuntu Pro token..."
3237 pro attach --no-auto-enable " ${UBUNTU_PRO_TOKEN} "
3338 echo " Enabling FIPS apt repo access..."
3439 pro enable --access-only --assume-yes fips-updates
40+ echo " Installing the OpenSSL FIPS modules"
41+ apt-get -qq install --no-install-recommends ubuntu-fips-userspace > /dev/null
42+
43+ # With the OpenSSL FIPS module installed, OpenSSL can now work with the default settings,
44+ unset OPENSSL_FORCE_FIPS_MODE
3545 fi
3646}
3747
You can’t perform that action at this time.
0 commit comments