There are 2 problems: 1. libffi itself isn't CET enabled. 2. libffi trampoline isn't CET enabled. This is a bigger problem since loader allocates legacy bitmap for libffi.so since it isn't CET enabled. But legacy bitmap doesn't cover trampoline generated by libffi. The fix for libffi master branch is at https://github.com/libffi/libffi/pull/540 Backport to libffi 3.1 is also available.
After libffi is fixed with larger trampoline with ENDBR, all packages which use libffi must be recompiled with larger ffi_closure.
Hi HJ, Where can I read more about CET? If there a Fedora mandate to move to CET-enabled builds? Or is that only supported for certain processors? There's a pending ABI-breaking libffi update for Fedora, but if I have to break it again, I might as well make a new release with this and do it all at once.
(In reply to Anthony Green from comment #2) > Hi HJ, > > Where can I read more about CET? If there a Fedora mandate to move to Intel Control-flow Enforcement Technology (CET): https://software.intel.com/en-us/articles/intel-sdm contains shadow stack (SHSTK) and indirect branch tracking (IBT). When CET is enabled, ELF object files must be marked with .note.gnu.property section. Also when IBT is enabled, all indirect branch targets must start with ENDBR instruction which is a NOP on non-CET processor. Fedora will be the first CET enabled OS: https://bugzilla.redhat.com/show_bug.cgi?id=1538725 > CET-enabled builds? Or is that only supported for certain processors? CET support is backward compatible. > There's a pending ABI-breaking libffi update for Fedora, but if I have to > break it again, I might as well make a new release with this and do it all > at once. Yes, we need to bump to libffi.so.8 since FFI_TRAMPOLINE_SIZE is increased unconditionally.
compat-libffi31 will be needed.
This patch caused a regression with building/testing with gcc -m32 and g++ -m32. Could you please have a look?
https://travis-ci.org/libffi/libffi/builds/653722453?utm_medium=notification&utm_source=github_status
This package has changed maintainer in the Fedora. Reassigning to the new maintainer of this component.
This bug appears to have been reported against 'rawhide' during the Fedora 33 development cycle. Changing version to 33.
I implemented trampoline table with compatible closure for libffi 3.1 on hjl/cet/2014-05-11 branch: https://github.com/hjl-tools/libffi/tree/hjl/cet/2014-05-11 It passed tests on Tiger Lake.
I update hjl/cet/2014-05-11 branch to enable 32-bit trampoline table.
This message is a reminder that Fedora 33 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora 33 on 2021-11-30. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '33'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 33 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 33 changed to end-of-life (EOL) status on 2021-11-30. Fedora 33 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.