Expand description
Guest signal controls an in-guest runtime refused before Detcore saw the call, reported once per run.
On the in-guest backends the runtime answers a guest’s handler-installing
rt_sigaction, and an alternate signal stack, with EPERM itself
(reverie-inguest protect_runtime_control): a guest handler would run
outside the Tool’s view. Until A5 step 3c makes guest handlers supported,
each refusal is announced once per run, by name, so that a run whose guest
carries on after the EPERM (many do, Rust’s standard library among them)
is not silently different from Linux.
The runtime records each refusal; the runtime crate that hosts Detcore
installs the function that takes them (install); Detcore takes them at
each syscall entry (report) and tells the coordinator, which prints one
WARN per refused signal and one for the alternate stack, per run. No other
backend installs a source, so nothing is reported there.
A refusal is reported at the process’s next syscall Detcore sees, which is its exit call at the latest when it exits normally. A process that dies before then reports nothing: one killed from outside, and one that faults in the signal it asked to handle (SIGSEGV’s default action is delivered by the runtime while it traps instructions and by the kernel otherwise; the kernel ends a process on SIGBUS, SIGFPE or SIGILL), because neither path reaches Detcore; a thread’s exit hook does not run on those deaths either, so it is not used.
The texts of Detcore’s own refusals of the in-guest runtime’s reserved
signals (Config::in_guest_reserved_signals: a send to another process,
or an arming) live here too. Detcore decides those itself, at the call,
and prints each through its guest WARN path (crate::guest_log).
Functions§
- install
- Installs
source, which takes the signal controls the runtime refused since it was last called. The runtime crate calls this once per process image; a forked child inherits it. Returns false if one was installed already.
Type Aliases§
- Refused
Signal Controls - What a runtime refused since it was last asked: the signals whose new
action it refused, bit
n - 1for signaln, and whether it refused an alternate signal stack.