Skip to content

Conversation

@dpgao
Copy link
Contributor

@dpgao dpgao commented Jan 26, 2025

Introduces compile-time flag CHERI_LIB_C18N_NO_OTYPE to disable usage of otype sealing. This flag is set by default for RISC-V but not for Morello.

dpgao added 9 commits February 2, 2025 20:42
This avoids using otypes to protect the TCB data structure in the
PLTGOTs of libraries.
When creating a new thread, the stack table for that thread is allocated
and passed to libthr (via a struct) to be given to the new thread.
Previously, the stack table is sealed when passed to libthr and unsealed
(and installed) when the new thread starts. This commit allows the
sealing to be optionally disabled with CHERI_LIB_C18N_NO_OTYPE.
Stack unwinding (in both setjmp/longjmp and C++ exceptions) requires
handing a capability to the trusted stack to user code. This capability
has previously been sealed with an otype. This commit adds the option to
use subset sealing instead.
This was intended to seal function pointers where the otype corresponds
to the signature of the function. The relevant compiler changes have not
been implemented though.
/lib/c18n/* are also ported and built for CHERI-RISC-V.
@gvnn3 gvnn3 requested a review from bsdjhb February 5, 2025 13:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants