[PATCH 3/6] cet: Correctly run dlopen tests with SHSTK enabled in hwcaps

Florian Weimer fweimer@redhat.com
Mon Nov 23 14:30:58 GMT 2026


* Arjun Shankar:

> The tst-cet-legacy-{4,5,6}* tests exercise dlopen with CET.  However,
> since 55d63e731253de82e96ed4ddca2e294076cd0bc5, CET is not set active
> unless enabled in hwcaps.  Some of the tests were silently running and
> passing in non-SHSTK mode.
>
> 1. Enable SHSTK in hwcaps for these tests so that they are executed in
>    the correct mode.  Although tst-cet-legacy-4c runs in SHSTK 'off'
>    mode, the hwcaps tunable is still set for consistency and will be
>    overridden by the policy.  The tst-cet-legacy-6-ENV entry was
>    spurious (the test is only run in its 'a' or 'b' variants), so drop
>    it.
>
> 2. For tst-cet-legacy-4a and tst-cet-legacy-4b, check that the test
>    has SHSTK enabled before dlopen, otherwise mark it UNSUPPORTED.
>
> 3. Adjust tst-cet-legacy-4 to assert dlopen result and SHSTK status for
>    all derived tests.

There's a potential that this causes incssp crashes in unwinders.  I
think that's why this needs its own tunable setting.

Thanks,
Florian



More information about the Libc-alpha mailing list