Summary: | dev-libs/openssl: USE=fips should not strip the fips.so module file | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Brandon Holbrook <gentoo> |
Component: | Current packages | Assignee: | Gentoo's Team for Core System packages <base-system> |
Status: | RESOLVED FIXED | ||
Severity: | normal | Keywords: | PATCH |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
See Also: | https://bugs.gentoo.org/show_bug.cgi?id=820173 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Brandon Holbrook
2023-03-09 23:55:25 UTC
Seems that I stopped writing the initial description mid-sentence :)
> However, by default the ebuild process identifies that file to be `strip`-ed, which
...which causes the file that gets installed to no longer match the expected MAC/checksum, which causes the FIPS provider to refuse to load at runtime.
README-FIPS.md mentions running "openssl fipsinstall" to (re)generate fipsmodule.cnf after installation. Instead of disabling stripping, we could possibly regenerate /etc/ssl/fipsmodule.cnf in pkg_preinst. Also, we should probably disable the FIPS module for non-native ABIs, or generate separate fipsmodule.cnf files for each ABI. The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=76f8af3f0ac6bd939ca6c837d0bba99098ac6ce0 commit 76f8af3f0ac6bd939ca6c837d0bba99098ac6ce0 Author: Mike Gilbert <floppym@gentoo.org> AuthorDate: 2023-03-11 05:50:36 +0000 Commit: Mike Gilbert <floppym@gentoo.org> CommitDate: 2023-03-11 16:51:01 +0000 dev-libs/openssl: generate fipsmodule.cnf in pkg_preinst This file contains an hash of the fips.so module, which may change after src_install due to automatic stripping by the package manager. README-FIPS.md says this file should be generated on each machine separately anyway. This will fail when cross-compiling since we call openssl from ${D}, but I don't see a better way to handle it. Only the primary ABI is handled currently: by the time we get to pkg_preinst, the tools from the secondary ABIs have been clobbered. Closes: https://bugs.gentoo.org/900625 Signed-off-by: Mike Gilbert <floppym@gentoo.org> .../{openssl-3.0.8.ebuild => openssl-3.0.8-r1.ebuild} | 13 +++++++++++++ 1 file changed, 13 insertions(+) Confirmed, the fips module in this new build loads just fine. Thanks! |